Quorums: R + W > N
In a leaderless store you choose, for each request, how many replicas must answer. Interviewers ask you to pick those numbers, and then ask what can still go wrong.
Five flatmates and the bills
Five flatmates share the bills and nobody is in charge. The house rule: when you pay a bill, tell at least three of the five. To find out whether a bill is paid, ask at least three. Any three told and any three asked must share at least one person, because 3 + 3 = 6 is more than 5. Someone you ask therefore knows the latest payment, and their note has the latest date. Tell two and ask two, and you might ask exactly the two who weren't told.
- the five flatmates → N, the replicas of a key
- tell at least three → W, the replicas that must confirm a write
- ask at least three → R, the replicas a read waits for
- the groups must share someone → R + W > N
- trust the note with the latest date → the newest version wins