Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

update cluster slots reply checking logic for Redis 7 #2108

Merged
merged 2 commits into from
Jun 4, 2022

Conversation

wangrzneu
Copy link
Contributor

In general a client implementation should just rely on the fact that certain parameters are at fixed positions as specified (referenced from https://redis.io/commands/cluster-slots/)

@@ -2717,7 +2717,7 @@ func (cmd *ClusterSlotsCmd) readReply(rd *proto.Reader) error {

nodes[j].Addr = net.JoinHostPort(ip, port)

if n == 3 {
if n >= 3 {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If we have 4 replies, then we should also read (and probably discard) the 4th reply as well?

@vmihailenco
Copy link
Collaborator

Thanks for working on this - I will try to add a build for Redis 7.

@vmihailenco vmihailenco merged commit 52af8ba into redis:master Jun 4, 2022
@vmihailenco
Copy link
Collaborator

Thanks

@wangrzneu wangrzneu deleted the redis-7-cluster-slots branch June 4, 2022 12:53
evilaffliction pushed a commit to reactive-go/redis that referenced this pull request Jun 15, 2022
fix: update cluster slots reply checking logic for redis 7
evilaffliction pushed a commit to reactive-go/redis that referenced this pull request Jun 15, 2022
fix: update cluster slots reply checking logic for redis 7
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants