Chris Collins

Tagged “wal”

Exploration ·

How a database survives a crash

Pull the plug on a database halfway through a write and it comes back with every committed transaction and none of the half-finished ones. How? Follow a write through the log, the buffer pool and the disk, compare B+trees with LSM-trees, watch compaction, and then see the other half of the promise — what concurrent transactions are allowed to see — with real PostgreSQL and SQLite running between the paragraphs.

Data and event platformsSoftware engineering

Tool ·

Time-series database lab

Inside a time-series database: validate InfluxDB line protocol and Prometheus exposition text and see the series keys; watch Gorilla, Prometheus XOR/XOR2 and InfluxDB TSM compression bit by bit on your data (byte-identical to Prometheus's and InfluxDB's own encoders); estimate cardinality and memory; downsample counters correctly; size retention tiers; and watch Prometheus cut and compact blocks.

Data and event platformsSoftware engineering

Tool ·

SQLite internals

Real SQLite in your browser with a console, and what is underneath: the database file decoded page by page (header, b-tree pages, cell pointers, cells and records, overflow and freelist pages), a b-tree diagram for any table or index, VDBE bytecode annotated opcode by opcode, query plans as trees, the pages each statement writes — and eleven labs from rowid tables to WAL.

Data and event platforms

Tool ·

Storage engines: LSM-tree vs B-tree, simulated

A B+tree and an LSM-tree side by side in your browser, fed the same operations: page splits and merges, the WAL and buffer pool, memtable flushes, leveled, size-tiered and lazy-leveling compaction, Bloom filters, fence pointers and tombstones — with write, read and space amplification counted as you watch, guided scenarios and the textbook cost models.

Data and event platformsSoftware engineering