Skip to content

why dispatch() can lead to performance degradation #2952

Closed Answered by Sinbol
Sinbol asked this question in Q&A
Discussion options

You must be logged in to vote

I'm sorry for the delayed response. First thank you for your answer. And recently I have spent some more time researching the issue, and it seems that I have found the answer. The problem lies in the add() method. It seems that the parameter passed to add() cannot be treated as a key, so the correct node is not calculated before sending the command. As a result, the request triggers a move response in some nodes, and Lettuce retrieves the correct execution node from the move information. Obviously, this leads to a performance degradation. I have confirmed this issue by capturing packets. addKey() should be used here to solve the problem. Thank you for your attention again!

Replies: 1 comment 3 replies

Comment options

You must be logged in to vote
3 replies
@tishun
Comment options

@Sinbol
Comment options

Answer selected by Sinbol
@tishun
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants