Closed chulong closed 3 years ago
Change configuration
The endpoints lists are the output of the slots' response from redis itself. Redis doesn't reply with domain names but ip addresses. There's no transformation/resolution added by the client, so I'm not certain if this is a bug, but a feature so to day.
How would we know that the network changed?
Here's where the information about the cluster is loaded from: https://redis.io/commands/cluster-slots
A example output is:
127.0.0.1:30001> cluster slots
1) 1) (integer) 0
2) (integer) 5460
3) 1) "127.0.0.1"
2) (integer) 30001
3) "09dbe9720cda62f7865eabc5fd8857c5d2678366"
4) 1) "127.0.0.1"
2) (integer) 30004
3) "821d8ca00d7ccf931ed3ffc7e3db0599d2271abf"
2) 1) (integer) 5461
2) (integer) 10922
3) 1) "127.0.0.1"
2) (integer) 30002
3) "c9d93d9f2c0c524ff34cc11838c2003d8c29e013"
4) 1) "127.0.0.1"
2) (integer) 30005
3) "faadb3eb99009de4ab72ad6b6ed87634c7ee410f"
3) 1) (integer) 10923
2) (integer) 16383
3) 1) "127.0.0.1"
2) (integer) 30003
3) "044ec91f325b7595e76dbcb18cc688b6a5b434a1"
4) 1) "127.0.0.1"
2) (integer) 30006
3) "58e6e48d41228013e5d9c1c37c5060693925e97e"
This means that redis itself is assuming "ipaddresses" so if the network rearranges itself the client must be recreated too.
Questions
In cluster mode, if domain name proxy is used, local IP is cached. If IP changes, the cluster cannot be accessed
Version
4.0.0
Context
Extra