diff options
author | antirez <antirez@gmail.com> | 2014-03-11 15:19:00 +0100 |
---|---|---|
committer | antirez <antirez@gmail.com> | 2014-03-13 15:11:53 +0100 |
commit | 133fccb03f2a9b5caff2ae1dd1537c984949392f (patch) | |
tree | e1d8d358bd5b928714b5380ce6c93c1afefe3963 /src/redis.c | |
parent | 429aff4ef4ae6f2947614e1005048af78570b8a8 (diff) | |
download | redis-133fccb03f2a9b5caff2ae1dd1537c984949392f.tar.gz |
Cluster: flag the transaction as dirty for the new redirections.
Diffstat (limited to 'src/redis.c')
-rw-r--r-- | src/redis.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/redis.c b/src/redis.c index 23bf013e3..c24828c07 100644 --- a/src/redis.c +++ b/src/redis.c @@ -2018,12 +2018,14 @@ int processCommand(redisClient *c) { int hashslot; if (server.cluster->state != REDIS_CLUSTER_OK) { + flagTransaction(c); addReplySds(c,sdsnew("-CLUSTERDOWN The cluster is down. Use CLUSTER INFO for more information\r\n")); return REDIS_OK; } else { int error_code; clusterNode *n = getNodeByQuery(c,c->cmd,c->argv,c->argc,&hashslot,&error_code); if (n == NULL) { + flagTransaction(c); if (error_code == REDIS_CLUSTER_REDIR_CROSS_SLOT) { addReplySds(c,sdsnew("-CROSSSLOT Keys in request don't hash to the same slot\r\n")); } else if (error_code == REDIS_CLUSTER_REDIR_UNSTABLE) { |