Replication & ConsistencyConsistency ModelsMedium⏱️ ~3 min

Linearizability vs Sequential vs Serializability: Understanding Strong Consistency Models

Linearizability, sequential consistency, and serializability represent the strongest consistency models but differ in critical ways. Linearizability (also called strong consistency) requires that every operation appears to take effect atomically at a single point in time between its invocation and response, ordered by real time. If client A completes a write at time T1 and client B starts a read at time T2 > T1, linearizability guarantees that B's read sees A's write or a later value. This real time ordering constraint makes linearizability the gold standard for implementing invariants like uniqueness constraints, preventing double spending, or ensuring authorization changes take effect immediately. Implementation requires routing writes through a single leader or obtaining majority quorum acknowledgments, costing at least 1 to 2 network round trips. Sequential consistency is weaker than linearizability because it only requires that all processes see operations in the same total order, without respecting real time constraints. Operations from different clients may appear reordered relative to wall clock time, as long as every client observes the same interleaving. This allows more flexibility in implementation and can reduce coordination overhead. Serializability operates at the transaction level rather than individual operations, guaranteeing that concurrent transactions produce a result equivalent to some serial execution order, but without specifying which serial order or whether it respects real time. Strict serializability combines serializability with linearizability, adding the real time ordering guarantee to transactions. Google Spanner provides strict serializability across regions, enabling F1 (Google Ads system) to enforce complex financial constraints at global scale. The distinction matters enormously in practice. Linearizability enables external consistency: if an external observer sees effect B after cause A (say, through an out of band communication channel), the system also reflects that ordering. This property is essential for coordinating distributed systems with external real world events. Sequential consistency cannot provide this guarantee. The cost difference is measurable: linearizable writes in a multi region deployment add full Wide Area Network (WAN) round trip times (100 to 200 milliseconds between US and Europe) plus commit wait periods. Systems that can tolerate sequential consistency or causal consistency can avoid these cross region synchronous round trips, reducing write latencies to single digit milliseconds within a region.
💡 Key Takeaways
Linearizability requires operations to appear atomic at a single point in real time between invocation and response, enabling external consistency for coordinating with real world events
Sequential consistency only guarantees all processes see the same total order of operations without real time constraints, allowing more implementation flexibility
Serializability operates on transactions rather than individual operations, guaranteeing equivalence to some serial execution without specifying which serial order
Strict serializability combines serializability with linearizability's real time ordering; Google Spanner implements this globally for F1 Ads system with commit latencies of 100 to 200+ milliseconds across continents
Linearizability costs at least 1 WAN Round-Trip Time (RTT) to leader plus quorum replication; US to Europe adds 100 to 200 ms versus single digit milliseconds for weaker models within a region
Use linearizability for uniqueness constraints, double spend prevention, authorization updates, and money movement; accept the latency cost only where invariants truly require real time ordering
📌 Examples
Google Spanner uses TrueTime API with clock uncertainty epsilon (typically 7 ms) plus Paxos replication to provide strict serializability; commit wait equals epsilon to ensure linearizability
F1 (Google Ads) runs on Spanner to enforce global invariants like budget constraints and billing accuracy across regions, accepting 100+ ms cross continent write latencies for correctness
Payment systems require linearizability to prevent double charging: if authorization succeeds at T1, any subsequent balance check at T2 > T1 must reflect the deduction
Etcd and Consul implement linearizable reads via leader leases or read index, ensuring configuration changes (like service discovery updates) are immediately visible to all clients after acknowledgment
← Back to Consistency Models Overview