Expand description
Generic byte-tree facade.
This file is the main reusable interface of the B-tree layer. It lets callers treat a tree as
an ordered map from &[u8] to &[u8] while the implementation handles page layout, splitting,
merging, cursor navigation, and large-value overflow.
Layer split:
caller
provides: ordered key bytes, opaque value bytes
sees: insert / delete / get / cursor / range helpers / stats
byte tree
owns: root tracking, node mutation, structural validation, overflow-backed values
pager
owns: page IO, free-page reuse, checksums, journaling, WAL, lockingLarge values are represented with a B-tree-owned wrapper:
logical value
|
v
StoredValueLayout
local payload bytes
total length
first overflow pageThat extra indirection is what keeps overflow handling generic instead of pushing it into the catalog or table code.