CAP, PACELC & Consistency Models
CAP, stated carefully
CAP says that when a network partition splits your nodes so they cannot talk, you must choose between consistency and availability. That is the whole theorem, and it is narrower than the popular version.
The popular version — "pick two of three" — is wrong in a way that matters. Partitions are not something you choose; they are something the network does to you. You cannot decide to be CA any more than you can decide it will not rain. The real choice is only what to do when a partition happens:
CP — refuse to serve requests you cannot answer correctly. A node that cannot reach a quorum returns an error rather than a possibly-stale value. Banking ledgers, inventory, anything where a wrong answer is worse than no answer.
AP — keep serving, accept that different partitions may diverge, and reconcile afterwards. Shopping carts, social feeds, DNS. A slightly stale answer beats an error.
partition happens (not optional)
│
├─ CP: refuse to answer → error, stay correct
└─ AP: answer anyway → maybe stale, stay up
"CA" is not a runtime choice.
It only describes a system that never partitions —
i.e. one that isn't distributed.3 components2 connections0:00
Recording…