Code RoomWrite-ahead log batching
HardPrep Room Coding #3417

Write-ahead log batching

System designStorage & CDNSenior–Staff~45 min

A single-node OLTP engine's commit path is fsync-bound: every committing transaction calls fsync on the WAL to be durable, and under 50k tx/sec the disk can't sustain one fsync per commit — throughput collapses and commit latency spikes. You must raise commit throughput without weakening the durability guarantee (a transaction reported committed must survive a power loss). Design the WAL write/commit path: how you batch durability work across concurrent committers, how you keep latency bounded, and the knobs that trade latency for throughput.

What a strong answer looks like

Clarify scale and constraints first. Propose a clean component breakdown, then go deep on the hard parts (data model, bottlenecks, consistency, failure modes) and name the trade-offs you are making.

Clarify5:00 left
Estimate5:00 planned
Design15:00 planned
Deep dive12:00 planned
Failure8:00 planned
0:00
Which questions mattered is sealed until you submit. Telling you now would just be handing over the edge cases.