-
Notifications
You must be signed in to change notification settings - Fork 992
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
RoundRobinSocketAddressSupplier
is not refreshing when RedisURI
changes
#1909
Comments
On a second thought, comparing the URIs might not be the most correct approach since there can be aliases and it might affect other parts of the code. I think it might be better to go on another route and modify the reset conditions to check specifically if anything changed from an URI pov. Any thoughts on this? |
I'm happy for suggestions on how we can improve here. |
@mp911de, I've made the changes I suggested. Mind taking a look when you have time please? |
Managed to test the problematic scenario as well today and confirmed it works fine with the fix |
RoundRobinSocketAddressSupplier
is not refreshing when RedisURI
changes
Bug Report
RoundRobinSocketAddressSupplier is not refreshing nodes IPs if only IPs change while nodeIds remain the same. Because of this the ConnectionWatchdog keeps retrying to connect with an old IP. (seems to be similar to what was reported under #1343 )
Current Behavior
if (!roundRobin.isConsistent(partitions)) { resetRoundRobin(partitions); }
because the equals method from RedisClusterNode only compares the node ids
Expected behavior/code
If the nodes IPs change, we should do the round robin rebuild.
Environment
Possible Solution
Modify the equals method from RedisClusterNode to check the ip/uri as well
Additional context
dynamicRefreshSources was set to false and the DNS resolver used was DirContextDnsResolver
The text was updated successfully, but these errors were encountered: