Problem Statement
In MVCC engines, how are readers and writers decoupled?
Explanation
Multi-Version Concurrency Control keeps old versions to serve snapshots. Readers avoid waiting and do not take long read locks. Writers update a new version and mark old versions for cleanup.
This design improves read concurrency but needs vacuuming or GC to reclaim old versions.
Code Solution
SolutionRead Only
-- Snapshot at statement start SET TRANSACTION ISOLATION LEVEL REPEATABLE READ;
Practice Sets
This question appears in the following practice sets:
