Files
thptqg/docs
tiennm99 c407130162 perf(db): write 4 KiB pages, because requests cost more than bytes
The 1 KiB page size optimised for the fewest bytes per seeked row. The
first real measurement says that is the wrong quantity: a name search
made 390 requests for 608 KB and took 16.9 seconds. The worker reads
with synchronous XHR (lazyFile.ts opens every GET with async=false), so
requests are strictly serial at roughly 40 ms each, and 390 x 40 ms is
the whole of that time. The bytes were never the problem.

Four times the page size means a quarter of the pages for the same
scan, and a shallower b-tree for each of the 100 result rows the search
seeks individually. It also costs about 5% less file.
2026-08-14 16:52:33 +07:00
..

Docs

  • project-overview.md — goal, scope, constraints, the datasets, history
  • system-architecture.md — data flow, canonical schema, routing, how one frontend serves both exam years
  • data-pipeline.md — Excel parse quirks, per-dataset formats, overflow-sheet gotcha, expected row counts, verifying a rebuild
  • deployment-guide.md — GitHub Pages workflow, adding a dataset, rollback, troubleshooting