modem-contract
The management-plane contract, as a library: the registry, its locks, the
payload types every document on the wire is serialized from, and the schemas
@rpc/modem/describe serves. Compiled once, for every driver that serves the
contract — this repository's, and the owner's IP driver, which must serve the
same contract rather than a copy of it (#119).
No Zenoh runtime. zenkey is linked without its zenoh feature: the key
grammar, the registry slice type and the RFC 08 §7 schema envelope are pure
data, and scripts/guards.sh holds the line at the zenoh crate itself.
Nothing here can open a session, and nothing here knows how a value is
produced — LinkState::of and its siblings take the facts, not the driver.
What is here
registry/ |
modem.toml and types.toml, the contract zenkey-build lints at build time and introspect serves verbatim (RFC 08 §6) |
registry.lock, deprecated.lock, conditional.lock |
the RFC 08 §3.1 compatibility snapshot and the two ledgers, outside registry/ so a lock written there cannot re-trigger the build that wrote it |
src/registry |
the typed key builders zenkey-build generates from the registry |
src/documents.rs |
every payload type, derived-schema and serde in one place, so what is described is what is serialized (#37) |
src/schema.rs |
the SchemaSet describe serves, and verify_total, which refuses to let a producer come up while it describes less than it declares |
PROFILE, PRODUCER |
the application identity every key is minted under, and the producer name — the host is the origin, the device is a subject chunk |
Regenerating
tests/registry_contract.rs lints the registry without any feature, renders
the AsyncAPI document and compares, and checks that every subject the ledger
says may be silent is one the registry declares.