I have a Redis cluster with 6 masters + 6 slaves. I use a Java client with Lettuce and SerializationUtils from Apache Commons Lang for transcoding keys and values. I inserted keys with the client and works well. But rebalance/reshard clusters (using redis-cli --cluster) won't work. When I switch to UTF-8 as codec, everything works well.

Please correct me if I should create the issue on Redis instead of here.

When I run reblance, it will shows CROSSSLOT Keys in request don’t hash to the same slot

Here are steps to reproduce: * Create a redis cluster * Run the code attached in the zip. https://github.com/lettuce-io/lettuce-core/files/3167882/codec.zip * redis-cli --cluster reshard localhost

Note: The SerializeUtils would put "\xac\xed\x00" as the prefix, this could be the root cause. The stored data uses byte values below the ASCII range will cause the bug.

Maybe a duplicate of https://github.com/antirez/redis/issues/6072 ?

Comment From: itamarhaber

/cc @artix75

Comment From: dbenders

fixed in PR #6304