All Questions
Dealing With Contention hard

Most modern databases resolve deadlocks automatically by:

  1. A Detecting the cycle and selecting a 'Victim' transaction (e.g., the one with the least work done) to Rollback/Kill.
  2. B Stopping the server.
  3. C Sending an email to the admin.
  4. D Unlocking both rows.

One system design question a day, with spaced repetition so the ones you miss come back.

Get the app

Related questions