What does CAP mean for a system you actually run?
“Explain CAP without the "pick two" slogan. For a multi-region user-profile store, what happens during a partition under each choice, and how do quorums fit in?”
What this tests
- Partition tolerance as a given; the real choice is behaviour during a partition
- Concrete consequences: refuse writes vs accept divergent writes and reconcile
- Quorums (W + R > N) and what they do and do not guarantee
- PACELC: the latency-vs-consistency tradeoff when there is no partition
Answers by level
Read the beginner answer first and notice what is missing.
Partitions are not optional in a system that uses a network; timeouts are partitions from the caller's view. So the question is only: when the two regions cannot talk, does a region refuse operations it cannot confirm with the other (consistency: some users get errors), or accept them locally (availability: both sides keep serving, their data diverges, and someone must reconcile when the link returns)? Neither is free — one gives users errors, the other gives them stale or conflicting state.
Quorums make this tunable per operation: with N replicas, write to W and read from R; if W + R > N, a read overlaps the latest write, so you get read-your-latest-write without waiting for all replicas. N = 3, W = 2, R = 2 tolerates one replica down. But during a partition where a region only reaches one replica, W = 2 cannot be met, and the system must either fail the write (CP) or lower W to 1 for that region (AP with divergence) — see CAP and Distributed Systems and Distributed Consistency: CAP, Quorums, Consensus.
Green flags · Red flags
- States that partitions (and timeouts) are a given and reframes the choice as partition behaviour
- Describes concrete effects: errors vs divergence and reconciliation
- W + R > N with a worked N/W/R example and its limits
- Brings in PACELC and cross-region latency numbers
- Decides per operation (uniqueness CP, display name AP)
- "Pick two: we chose AP because availability matters more."
- Believes quorum reads give linearizability automatically
- Claims a system is "CA"
- Cannot say what happens to a write on the minority side