Expand description
Centralized domain DB access for ZLayer.
This crate is the home for the generic persistence machinery shared across
ZLayer’s SQLite-backed resource stores. Increment 1 hosts:
StorageError— the shared error type returned by every storage operation (moved verbatim fromzlayer-api::storage).JsonStoreand its companionsIndexSpec/JsonTable— the generic “blob + optional unique indexes”SQLiteadapter. Its engine-neutral name lets theZLayerZQLmirror swap in a ZQL-backedJsonStoreof identical API by overriding thebackendmodule alone.
These were lifted out of crates/zlayer-api/src/storage/ so that domain DB
access can be centralized here. zlayer-api re-exports them unchanged, so
every existing caller (zlayer_api::storage::{StorageError, IndexSpec, JsonTable, JsonStore}) keeps compiling.
Structs§
- Index
Spec - Specification for a single secondary column peeled out of
Tat write time. All peeled columns are typedTEXTinSQLite;Nonefrom the extractor becomes SQLNULL. - Json
Store - Generic blob store keyed by a string
id. - Json
Table - Full table specification: name + the ordered list of indexed columns.
Enums§
- Storage
Error - Storage errors