What did the database promise? (consistency models)
The Copy Clerks · Open board
The leader, the followers and the lag between them. This lesson goes past the board: it asks what a database is allowed to say while the copies disagree, and gives the answers their engineering names.
Before you start. You need the copies from The copy clerks (database replication): one leader that takes writes, followers that copy it a moment later, and the follower that answers with an old value. You need the cut line from The cut phone line (CAP, done properly) too: a break in the network that leaves machines in groups that cannot talk to each other, which engineers call a partition. There, a copy that cannot reach the others must either answer or refuse. Who holds the pen (consensus & Raft) showed how a majority picks one writer. This lesson is about what readers are promised, not who writes.
Lesson 25 of 73 in System Design
The rest of this lesson is part of a plan.
A plan opens every lesson, board, video, lab and paper on chalk. Yearly is $39/year, or $19.50 for your first year with LAUNCH50, ends 1 Nov, 18:30 UTC.
Or start free: a free account opens lessons 2 and 3 of every track.
In this lesson
May 2013: an auditor with a notebook
The shop with three books, and the auditor’s one question
Linearizable: one book, as if the copies did not exist
Sequential: one order for everyone, but not the clock’s order
Read-your-writes: the cheap promise about you
Causal: a reply must never appear before the thing it replies to
Eventual: if the writing stops, the copies agree
What the auditor was really doing
Terms it explains: partition, acknowledged, promise, linearizable, Sequential, read-your-writes, causal, eventual, History 1, History 2, History 3, History 4.