Commit 96005da
committed
JVMCBC-1696 Should not make bucketful KV connections to nodes that aren't hosting the bucket
Motivation
----------
During the migration to the new cluster topology classes,
there was a regression that caused `core.reconfigureBuckets`
to create bucket-scoped KV endpoints for nodes that
aren't hosting the bucket.
During rebalance, this causes noise in the logs due to fruitless
connection attempts, and more importantly causes `Cluster.diagnostics()`
to report the cluster is in a degraded state because the doomed
endpoints are not connected.
Modifications
-------------
When reconfiguring a bucket, transform the nodes by removing
the KV service from any node that is not hosting the bucket.
This echoes the behavior of the old BucketConfig class.
Note that we need to process the whole node list from the
"global" part of the topology so we can remove existing
KV endpoints that are no longer required by the updated topology.
Change-Id: I8eaf79d39033d4a24cfdd5b1eb18864d296b931e
Reviewed-on: https://review.couchbase.org/c/couchbase-jvm-clients/+/235828
Tested-by: Build Bot <build@couchbase.com>
Reviewed-by: Michael Reiche <michael.reiche@couchbase.com>1 parent d3d0e30 commit 96005da
File tree
2 files changed
+26
-10
lines changed- core-io/src/main/java/com/couchbase/client/core
- topology
2 files changed
+26
-10
lines changedLines changed: 26 additions & 6 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
96 | 96 | | |
97 | 97 | | |
98 | 98 | | |
| 99 | + | |
99 | 100 | | |
100 | 101 | | |
101 | 102 | | |
| |||
104 | 105 | | |
105 | 106 | | |
106 | 107 | | |
107 | | - | |
108 | 108 | | |
| 109 | + | |
109 | 110 | | |
110 | 111 | | |
111 | 112 | | |
| |||
135 | 136 | | |
136 | 137 | | |
137 | 138 | | |
| 139 | + | |
| 140 | + | |
138 | 141 | | |
139 | 142 | | |
140 | 143 | | |
| |||
823 | 826 | | |
824 | 827 | | |
825 | 828 | | |
| 829 | + | |
| 830 | + | |
| 831 | + | |
| 832 | + | |
| 833 | + | |
| 834 | + | |
| 835 | + | |
| 836 | + | |
| 837 | + | |
| 838 | + | |
| 839 | + | |
| 840 | + | |
| 841 | + | |
| 842 | + | |
| 843 | + | |
| 844 | + | |
| 845 | + | |
826 | 846 | | |
827 | 847 | | |
828 | | - | |
829 | | - | |
830 | | - | |
831 | | - | |
832 | 848 | | |
833 | 849 | | |
834 | 850 | | |
835 | 851 | | |
836 | 852 | | |
837 | | - | |
| 853 | + | |
| 854 | + | |
| 855 | + | |
| 856 | + | |
| 857 | + | |
838 | 858 | | |
839 | 859 | | |
840 | 860 | | |
| |||
Lines changed: 0 additions & 4 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
17 | 17 | | |
18 | 18 | | |
19 | 19 | | |
20 | | - | |
21 | 20 | | |
22 | 21 | | |
23 | 22 | | |
| |||
50 | 49 | | |
51 | 50 | | |
52 | 51 | | |
53 | | - | |
54 | | - | |
55 | | - | |
56 | 52 | | |
57 | 53 | | |
58 | 54 | | |
| |||
0 commit comments