Skip to main content

Crate kernel

Crate kernel 

Source
Expand description

§flusso-kernel

The cross-cutting vocabulary for flusso — the validated types every other layer trades in.

§Quick reference

ItemRole
commonValidated primitives — TableName, ColumnName, and the other identifier newtypes
configThe structures built from them — IndexSchema, Field, Join, Aggregate, Filter, IndexMapping
optionsThe neutral, ordered value tree a port entry carries to its adapter — Options, OptionValue
adapterWhat an adapter declares about its configuration — AdapterConfig, AdapterDescription, Port, override_var
traitsThe conversion the config crate implements — ParseFrom (text into entities)

This is the kernel: every other crate produces or consumes these types. They’re the canonical, already-validated shape of a search document and its building blocks, carrying no trace of the file format they were parsed from and naming no adapter.

ℹ️ Info — the assembled deployment config (Config/Index/the port entries) is a composition concern and lives a layer up in the config crate; each adapter’s own settings live in that adapter. Keeping both out of here lets the adapters depend on the vocabulary without reaching the top-level config, and lets the config layer carry an adapter’s options without knowing their shape.

Identifier types are built with nutype: they’re constructed only through try_new, so an invalid name never reaches the model.

Re-exports§

pub use adapter::*;
pub use common::*;
pub use config::*;
pub use envelope::*;
pub use options::*;
pub use port_entry::*;
pub use traits::*;

Modules§

adapter
What an adapter declares about itself: which port it implements, its kind string, and the shape of its options.
common
config
envelope
What flows through the stream: the position in the source’s change feed and the envelope a lane carries for one document.
options
The neutral, ordered value tree a port entry carries between the config layer and the adapter that understands it.
port_entry
One configured port: which adapter (type) and its options.
traits