Conceptual
Login

A Row Lock Is the Mechanism, and the Writer Queued Behind It Is the Cost

It rests on the lost-update node, because a lock only makes sense once you have watched the interleaving the engine is being asked to prevent. The isolation menu sits beside it rather than beneath it: a level is a policy, and this is one of the mechanisms a level is implemented with, so neither has to come first. It is the pessimistic answer to that interleaving, and it establishes lock cost as a measurable quantity, which the deadlock node and the optimistic-concurrency node both need in order to be more than a preference.

Questions this Concept answers

  • Why does taking a row lock deliberately at read time make a read-modify-write safe?