Multi-version concurrency control¶
Category: Distributed systems · Status: stub
One line: Keeping several versions of each record so that readers see a consistent snapshot while writers add new versions, instead of readers and writers locking each other out.
Also called: MVCC, snapshot isolation.
How it connects¶
flowchart LR
n_mvcc["Multi-version concurrency control"]
n_read_write_lock["Read-write lock"]
n_mvcc ---|or| n_read_write_lock
classDef center stroke-width:3px
class n_mvcc center
classDef outside stroke-dasharray: 4 3
class n_read_write_lock outside
- An alternative to: Read-write lock
- See also: Consistency models, Transactional memory
In each language¶
| Elsewhere | PostgreSQL ↗: each statement sees a snapshot, so reading never blocks writing; Clojure's STM ↗ also uses multiversion concurrency control |
Where to read more¶
- In this library: The lost update in a database
- Notes: Multi-Version Concurrency Control (MVCC) ↗
- Reference: Wikipedia: Multiversion concurrency control ↗