hayson-engine
The storage engine behind hayson — a document database on
plain text files. This is the embeddable core: one table is one append-only JSONL file (or a
directory of them, partitioned by a field's value), alongside a hayson.json catalog document
holding every table's schema. In-memory registries (key → file offset, field indexes, a full-text
index) make lookups and queries fast without an on-disk index.
hayson-engine has no server, no network, and no isolation levels of its own — it is the same
core linked in-process by hayson-server
(over gRPC), hayson-cli
(local mode) and hayson-browser, and mirrors the TypeScript
@theritual/hayson package on
the same on-disk format.
Database format: docs/format.md.
Installation
Usage
use Database;
use Path;
let db = open?;
The public API is a hand-curated list of twelve modules — atomic, buffer, catalog,
compaction, crypto, database, errors, lock, query, schema, table, txn — each
re-exporting the names it means to expose; see their module docs. The layers underneath (the log
files, the write queue, the in-memory registries, the index snapshots) are private, and
tests/public_api.rs holds the surface to that list.