v0.3.1-pre.003

This commit is contained in:
2026-08-29 07:51:09 +02:00
parent 11e4cde77f
commit ecc5607fd4
13 changed files with 1274 additions and 34 deletions

View File

@@ -1,5 +1,5 @@
// file: crates/ksp-store-api/src/lib.rs
// version: 1
// version: 2
#![warn(missing_docs)]
#![deny(unreachable_pub)]
@@ -17,8 +17,49 @@
//! dispatch remain outside this crate.
mod capability;
mod error;
mod model;
/// Error code used when a RAW Store model violates one of its backend-agnostic invariants.
pub use self::error::ERROR_CODE_RAW_MODEL_INVALID;
/// Error code used when a KSP-owned RAW persistence payload violates its format or admission contract.
pub use self::error::ERROR_CODE_RAW_PAYLOAD_INVALID;
/// Error code used when acquisition provenance is malformed, unsafe or internally inconsistent.
pub use self::error::ERROR_CODE_RAW_PROVENANCE_INVALID;
/// Maximum UTF-8 byte length accepted for one safe logical RAW/provenance code.
pub use self::model::raw_primitives::MAX_RAW_CODE_BYTES;
/// Maximum KSP-owned canonical RAW payload admitted by the Store API.
pub use self::model::raw_primitives::MAX_RAW_PAYLOAD_BYTES;
/// Maximum source-wire payload size recorded as acquisition metadata.
pub use self::model::raw_primitives::MAX_RAW_SOURCE_PAYLOAD_BYTES;
/// Maximum supported Unix millisecond timestamp.
pub use self::model::raw_primitives::MAX_RAW_UNIX_MILLIS;
/// Origin category describing why one acquisition was performed.
pub use self::model::raw_primitives::RawAcquisitionOrigin;
/// Safe source-independent acquisition provenance attached to one persisted observation.
pub use self::model::raw_primitives::RawAcquisitionProvenance;
/// Fixed-size digest identifying canonical or source bytes without retaining them.
pub use self::model::raw_primitives::RawContentHash;
/// Bounded identifier of one KSP-owned source-independent RAW persistence format.
pub use self::model::raw_primitives::RawFormatId;
/// Bounded logical network/cluster identifier used in backend-independent Store identities.
pub use self::model::raw_primitives::RawNetworkId;
/// Stable deterministic idempotence key for one persisted acquisition observation.
pub use self::model::raw_primitives::RawObservationKey;
/// Bounded source-independent KSP RAW persistence payload.
pub use self::model::raw_primitives::RawPayload;
/// Bounded logical code used by acquisition provenance fields.
pub use self::model::raw_primitives::RawProvenanceCode;
/// Bounded UTC timestamp represented as whole milliseconds since Unix epoch.
pub use self::model::raw_primitives::RawTimestamp;
/// Canonical 64-byte Solana transaction signature used by Store identities.
pub use self::model::raw_primitives::RawTransactionSignature;
/// Canonical source-independent N1 RAW transaction persisted by Store backends.
pub use self::model::raw_transaction::RawTransaction;
/// Persistable acquisition observation linked to one canonical RAW transaction.
pub use self::model::raw_transaction::RawTransactionObservation;
/// Durable backend-independent identity of one canonical RAW transaction.
pub use self::model::raw_transaction::RawTransactionReference;
/// Common KSP error type used by Store-facing contracts.
pub use ksp_core_lib::Error;
/// Stable structured code identifying a KSP error category and condition.