- Newest
- Most votes
- Most comments
Your analysis demonstrates a sophisticated understanding of Aurora's quorum-based replication. Let me address your questions about recovery and VCL reconstruction.
The key insight is that Aurora's recovery process is designed to be conservative and deterministic. When reconstructing VCL after a writer failure, Aurora must establish a consistent point that reflects only writes that previously achieved write quorum (4 of 6 acknowledgements).
For your specific scenario with LSN 105:
LSN 105 must be truncated during recovery. Even though it appears structurally complete on node A, it never achieved the required 4/6 write quorum before the writer failed. The recovery process cannot and will not promote it to VCL or repair it to additional nodes.
Here's why: Aurora's recovery algorithm reconstructs VCL by finding the highest LSN that appears on at least a read quorum (3 of 6) of storage nodes for each protection group. However, this is a necessary but not sufficient condition. The quorum intersection property guarantees that any write that previously completed on four nodes will appear on at least one member of every possible three-node read quorum. The converse, however, is not true—finding a record on one node in a read quorum does not prove it previously reached four nodes.
Aurora resolves this ambiguity conservatively: VCL is reconstructed as the highest point where the recovery process can verify, through the pattern of responses across the read quorum, that write quorum was previously achieved. Records that appear on fewer nodes than would be expected from a completed write quorum are treated as part of the "ragged edge" and truncated.
Regarding your question about querying all available storage copies: In practice, Aurora's recovery process contacts all reachable storage nodes, not just exactly three. The 3/6 read quorum represents the minimum availability requirement—recovery can proceed as long as at least three nodes per protection group are reachable. Querying all available nodes provides more information for accurately reconstructing VCL and minimizes unnecessary truncation.
The outcome is not intentionally unspecified. Aurora's design principle is clear: only writes that achieved write quorum and were acknowledged to the client are guaranteed durable. Unacknowledged writes that didn't reach quorum may be lost during recovery. This is consistent with standard database semantics—a transaction that hasn't been acknowledged as committed to the client has no durability guarantee.
The recovery process effectively distinguishes these cases through the distribution pattern of log records across storage nodes. A write that previously achieved quorum will have a characteristic footprint across the storage fleet that differs from a write that only reached one or two nodes before failure.
Your understanding of the quorum intersection guarantee is correct: it ensures that every previously acknowledged commit (which by definition achieved write quorum) will be discovered during recovery and included in the reconstructed VCL. The conservative truncation of the ragged edge ensures consistency while preserving all durable, acknowledged transactions.
Sources
Amazon Aurora reliability - Amazon Aurora
Resilience in Amazon Aurora DSQL - Amazon Aurora DSQL
Relevant content
asked 3 years ago
asked 2 years ago
