Open JanBerktold opened 4 years ago
The proxy should handle MOVED replies if the client is not under a transaction. So this is the behavior:
If the client is under MULTI transaction:
So I just reproduced the C# StackExchange.Redis client acting up and trying to switch into cluster mode after reading the MOVED error inside of the transaction. For starters, what do you think about changing that specific error message?
I'm not fully convinced, that that's the original error that I saw though - Going to be digging deeper for a 2nd repro case there.
@JanBerktold Were you under a MULTI transaction?
@artix75 Yes!
I have noticed that the proxy appears to return MOVED responses, therefore not hiding slot movements properly. Looking at the code, this appears to be confined to transactions currently (https://github.com/artix75/redis-cluster-proxy/blob/unstable/src/proxy.c#L4225) but I may be missing other parts of it.
In our case, this lead to our 'smart' client switching to cluster mode and trying to bypass the proxy. Solutions I can see:
MOVED
format. i.e. replace withcancelled due to cluster topology change