Ensure clients that are blocked on module authentication are not disconnected if cluster is down

Signed-off-by: Jason Kelly <jason.kelly@nokia.com>
This commit is contained in:
Jason Kelly 2024-06-25 08:20:48 -04:00
parent 5eac99c312
commit 4a8ac2f3fc

View file

@ -1254,6 +1254,10 @@ int clusterRedirectBlockedClientIfNeeded(client *c) {
dictEntry *de;
dictIterator *di;
/* If the client is blocked on module authentication, don't unblock it */
if (c->bstate.btype == BLOCKED_MODULE && clientHasModuleAuthInProgress(c))
return 0;
/* If the cluster is down, unblock the client with the right error.
* If the cluster is configured to allow reads on cluster down, we
* still want to emit this error since a write will be required