Skip to main content

Crate vlo_types

Crate vlo_types 

Source
Expand description

Wire types for the Vlo kernel protocol (see docs/kernel-protocol.md).

Everything that crosses the wasm boundary or lands in a journal is defined here, once, with serde for the wire and schemars for the generated JSON Schema that the TypeScript SDK types are derived from.

Rules:

  • No floats in anything that is hashed (KernelState, Usage). Money is micro-USD.
  • Time is milliseconds since the Unix epoch (*_ms), never a date type.
  • JSON that must survive byte-exact (user state, payloads) is carried as String at the storage edge and as serde_json::Value inside the kernel.

Re-exports§

pub use command::*;
pub use envelope::*;
pub use kernel_state::*;
pub use protocol::*;
pub use retry::*;
pub use transition::*;

Modules§

command
Commands a reducer returns, and the reduction that carries them (see docs/workflows.md).
envelope
The event envelope: kinds, statuses, causes, usage, and the journaled event shape.
kernel_state
Kernel-owned per-run bookkeeping, hashed together with the user state.
protocol
Inputs and outputs of the eight kernel exports (see docs/kernel-protocol.md).
retry
Retry policy and the plan the kernel derives from it.
transition
The write-set a transition produces, and the rows it is built from.

Constants§

INLINE_LIMIT_BYTES
Inline payload / state limit in bytes before the host offloads to the blob store (see docs/limits.md).
PROTOCOL_VERSION
Kernel protocol version. The host refuses a kernel whose protocol differs.