Reliability
Recoverable commits and checkpoints.
TriviumDB records changes in a CRC-protected write-ahead log and replays the safe prefix on startup. Transaction commits validate first, append a TxBegin/TxCommit batch, then apply to memory; checkpoint files are synced and published with atomic rename.
- Transaction validationDry-run check IDs, dimensions, payload size, and graph references before a transaction commit.
- WAL + CRCStore length-delimited bincode records with CRC32 so recovery can detect torn or corrupted tails.
- Safe-prefix replayPromote complete TxBegin/TxCommit batches, replay verified records, and truncate to a safe offset.
- Checkpoint renameWrite temporary checkpoint files, sync them, and publish with atomic rename.
- Sync modeWAL flush/fsync strength follows configuration: full, normal, or off.