Skip to main content

Module wal

Module wal 

Source
Expand description

Append-only write-ahead log for committed state snapshots.

A frame is considered committed only after its complete header, payload, and checksums have reached the WAL file. Recovery accepts valid complete frames and repairs and ignores an incomplete final frame, which is the normal result of a killed process during append.

Structs§

Frame

Constants§

MAX_WAL_BYTES
Maximum total WAL size before callers must checkpoint.

Functions§

append
Append a committed frame.
latest
Return the highest valid frame. A partial/corrupt tail is ignored; an invalid frame before the tail is an error because it would hide later data.
truncate