Durability vs. acknowledgment latency
How much must be confirmed before you say "yes".
Where you meet it: fsync vs. buffered, group commit, sync/semi-sync/async replication, quorum size, ack levels.
What it is
A W-of-N write waits for the W-th fastest response. So write latency is an order statistic of the replicas' latency distribution, not an average. Raising W moves you further into the tail, and the tail is fat (a few very slow responses). This is why synchronous cross-region replication is priced in round-trip time (RTT) and often abandoned. It is also why the dial of synchronous, semi-synchronous and asynchronous replication is a direct price list: durability is bought with acknowledgment latency, and the exchange rate is the shape of the slowest replica's latency distribution. Lower W (asynchronous) cuts latency but sets RPO to the replication lag, which is largest during the very failure you wanted protection from.
From Fault Tolerance & Delivery Semantics › Replication and quorums
Moving down the table, durability goes up and speed goes down. That is no surprise. But note one thing: an in-memory buffer is a hidden durability decision. If a record is acknowledged into an in-memory buffer and the process restarts, the record is lost. This is silent data loss, and no metric shows it. If your producer is told "OK" before the buffer is durable, you have chosen at-most-once delivery (a message may be lost but never repeated) without saying so.
From Data Movement › Buffering
(Rule: each step up the ladder adds about one network round trip and one more flush on another machine.)
From Persistence & Durability › Replication and quorums
Where it appears
In 9 mechanisms. Each says what the mechanism is about, then how this trade-off shows up there, in its own words.
- Physical Substrate & Performance Laws
Why do trade-offs exist at all?
A commit that waits for both regions needs at least one round trip: 200 ms for every write, which is impossible for an interactive product.
Read it inTCP, kernel bypass and the latency tiers
- Data Movement
How do records cross between two systems that have independent rates, independent availability and independent lifetimes, and what are you willing to lose when the assumption underneath the crossing breaks?
But note one thing: an in-memory buffer is a hidden durability decision.
- Storage: Physical Organization
What should sit next to what, given that I must decide at write time and find out at read time?
An in-place update writes the change at least twice: once sequentially to the log, and once to the page.
Read it inMutation strategies: what happens when a value changes
- Persistence & Durability
When a system says "yes, your data is safe", what exactly has it promised, and what did it have to do to keep that promise?
(Rule: each step up the ladder adds about one network round trip and one more flush on another machine.)
Read it inDurability across machines: replication, quorums and erasure codingBattery-backed memory and NVRAM
- Transactions & Concurrency Control
What happens when many users change the same data at the same time, and how do we keep the result correct?
This is the principle "costs are conserved, never removed" turned into a configuration knob with a published exchange rate: you trade a known, bounded amount of durability for latency.
Read it inBegin, commit and abort
- Memory & Resource Management
Who is allowed to hold how much memory, for how long, and what happens to the work when the answer is less than it asked for?
Eviction is therefore a transaction with a dependency chain, not a deletion.
- Distributed Systems Coordination
Who is allowed to decide, and how does everyone else learn the decision without asking?
Finally, the topology chooses your recovery point objective (RPO) before any failure occurs.
Read it inGeo-replication and active-active
- Fault Tolerance & Delivery Semantics
What is the cheapest thing that can be safely done twice?
The guarantee is bought with acknowledgment latency.
Read it inTransactional sinks and two-phase sink commitReplication factor and quorums as a survivability budget
- Streaming
What does it cost to remember, when the input never ends?
So end-to-end latency is at least the checkpoint interval: with a 10-second interval, results appear 10 to 20 seconds late.
Related
Made on the same pages most often.