Replies: 1 comment
-
|
First, |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
I am studying the locking method on Redis, and found this official documents:
https://redis.io/commands/setnx#handling-deadlocks
My understanding is that
SETNXis an atomic operation and ONLY ONE client can do it successful (get1) and the others failed (get0)However in the section
Handling deadlockson this document, it said:My question is that why 3) and 5) can be succeed? I think only C1 or C2 can be succeed but not both.
Please correct my understanding, thank you,.
Beta Was this translation helpful? Give feedback.
All reactions