Cluster: clear the FAIL status for masters without slots.
Masters without slots don't participate to the cluster but just do redirections, no need to take them in FAIL state if they are back reachable.
This commit is contained in:
parent
da9ae01802
commit
8c577113ee
@ -830,9 +830,10 @@ void clearNodeFailureIfNeeded(clusterNode *node) {
|
||||
|
||||
/* For slaves we always clear the FAIL flag if we can contact the
|
||||
* node again. */
|
||||
if (nodeIsSlave(node)) {
|
||||
if (nodeIsSlave(node) || node->numslots == 0) {
|
||||
redisLog(REDIS_NOTICE,
|
||||
"Clear FAIL state for node %.40s: slave is reachable again.",
|
||||
"Clear FAIL state for node %.40s: %s is reachable again.",
|
||||
nodeIsSlave(node) ? "slave" : "master without slots",
|
||||
node->name);
|
||||
node->flags &= ~REDIS_NODE_FAIL;
|
||||
clusterDoBeforeSleep(CLUSTER_TODO_UPDATE_STATE|CLUSTER_TODO_SAVE_CONFIG);
|
||||
|
Loading…
x
Reference in New Issue
Block a user