Index

Free, with Google

Keep going, free.

A free account opens lessons 2 and 3 of every track, 33 more lessons, and keeps your progress and review cards on every device.

Start free with Google

A chalk plan

Open everything on chalk.

Every lesson, board, video, lab and paper, and the full review decks. Yearly is $39/year.

See plansStart free instead

Module 02 · System Design · When the stalls must agree · about 26 min to read

Watch: CAP: the cut phone line
▶ VideoPlay it as a journeyTutor comes with a plan

The cut phone line (CAP, done properly)

The Cut Phone Line
The Cut Phone Line · Open board

The law under The copy clerks (database replication) and Splitting the ledger (sharding). Both left you holding copies that can disagree. This is the rule about what you may do when they do.

Before you start. The copy clerks gave you a second book that copies from the first and can fall behind by seconds. Splitting the ledger spread the stall’s records over more than one branch. That is the whole prerequisite: two places holding writing meant to say the same thing, and a wire between them.

Lesson 7 of 115 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.

See plansAlready a member? Sign in

Or start free: a free account opens lessons 2 and 3 of every track.

In this lesson

  • January 1996: a search engine that answered with whatever came back
  • July 19, 2000: Brewer’s three words, and the one you do not get to pick
  • The cut phone line: the two moves a lone clerk has
  • She does not see a cut line. She hears silence.
  • The five-second timeout that took down a shop with nothing wrong with it
  • “CA” is not an option, it is a decision you have not made yet

Terms it explains: partition, available, Consistency, CAP, AP, CP, timeout, linearizability, availability, Partition tolerance, drop arbitrarily many messages, 81 times, open, half-open, EL, EC, PA, PC, not linearizable, No message distinguishes them, 81×, backoff with jitter, retry budget, circuit breaker, consistency (linearizable), eventual consistency, PACELC, tunable consistency.

Lab

The line between the branches is cut. What does the far clerk say to the customer in front of them?

Pick Answer anyway, press Play next moment through all fourteen, and watch The bill so far count conflicting entries.

Open The cut phone line

Two cities changed the same order a moment apart. Which change survives, and what did it cost to be sure?

Pick Answer now, latest stamp wins, drag The west kitchen's clock to right on time, and watch Wrong change kept.

Open Two kitchens, two cities

Related papers

Review System Design