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

request timeout[QUESTION] #558

Open
yarthur1 opened this issue Apr 11, 2024 · 3 comments
Open

request timeout[QUESTION] #558

yarthur1 opened this issue Apr 11, 2024 · 3 comments

Comments

@yarthur1
Copy link

after cluster scale up,redis-plus-plus client request timeout increase;i use sw::redis::AsyncRedisCluster to get multi key,key nums no change,i want to kow why?
because get key need request more nodes? sw::redis::AsyncRedisCluster request redis server is not cocurrent?

@yarthur1 yarthur1 changed the title [QUESTION] request timeout[QUESTION] Apr 11, 2024
@sewenew
Copy link
Owner

sewenew commented Apr 14, 2024

Can you show me the minimum code that can reproduce the problem? If you use MGET command, these keys should locate on the same slot, even if the cluster scales up. In that case, the client connects and read/write a single node, no matter how large the cluster is.

@yarthur1
Copy link
Author

yarthur1 commented Apr 15, 2024

I use sw::redis::AsyncRedisCluster get function to obtain each key result, key may not in same node;
image

@sewenew
Copy link
Owner

sewenew commented May 8, 2024

So sorry, but somehow, I missed this message.

redis-plus-plus lazily creates connections, if it's the first time that these requests are sent to nodes, it needs to create connections to them. So if you have more nodes in clusters, you get higher latency. However, if all connections have been created, there should be no difference in latency, no matter how large the cluster is.

Regards

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

No branches or pull requests

2 participants