Systems & Backend

Write-Ahead Log

also: WAL · redo log

Append the change to a log before touching the data — the trick behind durability in nearly every database.

A write-ahead log records every change as an append before applying it to data structures. Appends are fast and atomic; after a crash, replay the log to recover. The WAL is the backbone of ACID durability, the source CDC reads, the thing replicas replay — arguably the single most reused idea in storage systems.