Expand description
Content-addressed object store (Phase 9).
A .voldoc descriptor’s object table is a single ordered sequence. Each
entry is either an inline byte object (OBJECT, tag 0x10) or a reference
to an object held by an ObjectStore (EXTERNAL_REF, tag 0x80). Inline
and external objects share one id space, so equal bytes are equal ids
regardless of which document they came from.
§Two digests, two roles
| digest | role | authority |
|---|---|---|
| SHA-256 | whole reconstructed source; archival identity | parse/materialize/verify |
BLAKE3-256 (Id) | one object’s bytes; store namespace | relational/advisory |
An Id is an ephemeral, relational name for a shareable object. It is
never a substitute for the source digest and never appears in INTEGRITY.
§Verification rule
ObjectStore::get must re-hash the returned bytes and reject with
crate::ErrorClass::IntegrityMismatch unless BLAKE3(bytes) == id.
ObjectStore::get_range cannot re-verify the whole object; exactness for a
store-backed materialization therefore rests on the EXTERNAL_REF declared
length and the descriptor’s INTEGRITY SHA-256 checked by materialize.
Structs§
- Account
Report - Cohort accounting across the three frozen universes.
- Embedded
Store - A content-addressed directory store.
- FsSeed
Store - The reference seed substrate: one file per node under
root/seed. - GcReport
- Outcome of a mark-and-sweep GC pass.
- Id
Idis a newtype over the 32 raw bytes ofBLAKE3-256(object_bytes), with no domain prefix. Hex is lower-case.- IoCounters
- A shared set of physical-read byte counters, one per class.
- IoSnapshot
- A point-in-time copy of
IoCounters. Subtract two to attribute bytes to an interval. - NodeId
NodeIdis a newtype over the 32 raw bytes ofBLAKE3-256("VOLE:PSEED:v1" || canonical_node_bytes). Hex is lower-case.- Null
Resolver - A resolver that resolves nothing; used by the standalone
materialize. - Packed
Seed Store - A packed content-addressed store of canonical procedural seed nodes.
- Root
Account - Per-root accounting.
- Seed
Store Stats - Physical accounting of a seed store.
- Store
Stats - Size accounting reported by a backend.
Enums§
- Sync
Policy - When the packed writer forces appended records to stable storage.
Constants§
- SEED_
FORMAT_ VERSION - Canonical seed-node format version.
- SEED_
NODE_ DOMAIN - Domain-separation prefix for a procedural seed node’s content id.
- STORE_
FORMAT_ VERSION - Current on-disk store format version.
- STORE_
MAGIC - Store marker magic (
VOLDST+ 0x1A text-EOF + NUL).
Traits§
- Object
Resolver - The resolver consumed by store-backed materialization. A blanket impl makes
every
ObjectStorea resolver, so callers pass&store. - Object
Store - A content-addressed store keyed by
BLAKE3-256of the object bytes. - Seed
Store - A content-addressed store of canonical procedural seed nodes.
Functions§
- account
- Compute the three accounting universes for
roots, resolving objects and closure throughstore. - externalize
- Inline → external: put every object’s bytes into
store, replacing it with anObjectSource::Externalreference. - gc
- Mark-and-sweep garbage collection over a set of root descriptors.
- hydrate
- External → inline: resolve every reference through
resolver(verifying id and length) and replace it withObjectSource::Inline. The external feature bit clears automatically becauserequired_features()is derived. - seed_
closure - Collect the transitive closure of
rootsin a seed store, verifying that no dependency is missing.deps_ofmaps a node’s canonical bytes to its dependency ids; it must be deterministic.