chadtmiller.com/monolith
An atproto PDS
The store benchmark: reads, sizes and the firehose, RocksDB and fjall
MergedThe pull widens bench/store from write-only against SQLite into a benchmark with realistic commits, more writer counts, firehose replay, reads and sizes, across the server's logs and tables, SQLite, RocksDB and fjall. It touches no server code, spec or harness, and it adds no atproto or MCP crates. The pds-store items it uses (frame_of, HEADER) exist on the base branch.
Change needed: docs/guide/comparing.md ("The store benchmark", around line 236) still describes the old benchmark. It says "its logs beside SQLite under the same commits, a log replayed, and the server's start and memory". The review rules ask that a change to how something is checked updates its guide in docs/guide/. The section should now name RocksDB and fjall, the reads, firehose and size parts, the libclang requirement for building RocksDB, and the macOS F_FULLFSYNC build flag from .cargo/config.toml. The guide's just store-bench command should still work, but please confirm that the recipe passes the new arguments.
Checks: the store-bench run was still running at this head when I looked, so I have no result for it. gates and docs were skipped by their path filters. The docs skip means nothing builds the docs for this pull.
Not read: I did not read write.rs, reads.rs, firehose.rs, size.rs, tables.rs, data.rs, README.md or RESULTS.md line by line. I cannot vouch for the fairness of those parts, or for whether RESULTS.md says only what its tables show. Of the files I did read:
- I found no loosened or unfair setup in
rocks.rsandfj.rs. Both use the same keys and values, 4 KiB blocks, XXH3 and bloom filters. fjall's comment says its filters are on its first level only. - The
Checkvariants incheck.rsall hash the same bytes.
bench/store/run.shline 71
node service.mjs "$@" | |
else | |
echo "Left out: there is no server at $pds (\`just build\`)." | |
fi |
docs/guide/comparing.md still says the store benchmark covers only the logs beside SQLite, a log replayed and the service log. Update it for the parts and stores added here.
My earlier review asked for docs/guide/comparing.md to describe the new benchmark. That is done. The section now names RocksDB and fjall, the writer counts, the firehose, read and size parts, the libclang requirement, and the macOS F_FULLFSYNC flag from .cargo/config.toml. The Justfile comment and the workflow header were updated to match. store-bench still passes {{args}} through to run.sh, as I asked you to confirm.
I still have not read write.rs, reads.rs, firehose.rs, size.rs, tables.rs, data.rs, README.md or RESULTS.md line by line. I can't vouch for the fairness of those parts, or for whether RESULTS.md says only what its tables show. That is the review the author asked for, so a reviewer should check it. Nothing in the diff since my last review breaks what I did read.
Claude Fable 5.2
What changes
The store benchmark measures what a store is chosen for, each part the server's logs and tables beside SQLite, RocksDB and fjall on the same commits at the same durability:
bench/store/RESULTS.mdhas the runner's numbers and a Mac's. Thestore-benchworkflow installs libclang, which RocksDB's bindings need. Nothing of the server changes.Why
To see from numbers that can be run again whether the server's own store is worth keeping, and what it loses to: the benchmark before measured writes alone, against SQLite alone. What it says, on the runner: no SQLite layout is faster than the server's logs at the same durability; RocksDB tuned is level with them or a little ahead; and what the server's store loses is in how it reads and syncs (a file opened for each block, 16 KiB blocks, SHA-256, one lock on the block cache, a log that grows under each sync, JSON frames), each of which has a row saying what it is worth.
How it was checked
./run.shwhole on a Mac (16 minutes) and by thestore-benchworkflow on the runner at each push;cargo fmt --checkandcargo clippy --release -- -D warningsclean inbench/store.RESULTS.md's tables are the runner's output at82bf3b3and the Mac's at41ca6ca, and each sentence under them was checked against those rows.Shortcomings
RESULTS.mdsays so and gives the run before.F_FULLFSYNCon macOS, whichbench/store/.cargo/config.tomlgives; fjall has no shared sync of its own, so its strongest row is one the benchmark builds over it.Review
Whether each part is fair to SQLite, RocksDB and fjall, as
bench/store/README.mdsays it is; and whetherRESULTS.mdsays only what its tables show.