hard20 pts · first answer countsdistributed-systemsconcurrency
Why a lock alone is not enough
Worker A takes a Redis lock with a 10-second TTL, then pauses for 15 seconds due to a long GC pause. The lock expires, Worker B takes it and writes to storage. Then A wakes up and also writes. What prevents A from corrupting data?
Discussion 0
Join free to post in the discussion.
Related questions
- Duplicate emails despite a checkBackend Developer
- Optimistic lock update hits 0 rowsBackend Developer
- Retrying after a shared outageBackend Developer
- CAP during a network partitionBackend Developer
- Lost update on a wallet balanceBackend Developer
- One slow route freezes Node.jsBackend Developer
- Workers block each other on a jobs tableBackend Developer
- Deadlocks between two transfersBackend Developer