Skip to main content

Crate subspace_contracts

Crate subspace_contracts 

Source
Expand description

Board-to-board contracts. A contract is an interface that no board owns: a stable name, a version and the typed messages boards exchange through it. A board that publishes or answers a contract and a board that listens to or asks it both depend on this crate, never on each other, so either can be absent or disabled.

Two kinds of message exist. An Event announces that something happened and expects no answer. A Request asks the one board that responds to the contract for an immediate answer from the state it holds. Messages carry identities and small summaries, never credentials or bulk content.

The broker that routes messages, and the declarations boards make at registration, live in board-kit (subspace_dashboard::contracts).

Modules§

decisions
Navigation to a decision by its project-scoped reference. The answering board opens and reads it in its own scope.
github
GitHub pull request navigation, independent of any board or account.
issues
The issues contract: recognising issue references in text and resolving them to short summaries, between a board that holds an issue tracker session (the responder) and boards that show text mentioning issues.

Structs§

MessageKey
The identity of one message type: contract, version, name and kind.

Enums§

MessageKind
Whether a message is an Event or a Request.

Traits§

Contract
A named, versioned interface between boards.
Event
A notification that something happened. Delivered at most once to every running board that subscribes to it, with no answer and no replay.
Request
A question with a typed answer, routed to the contract’s one responder.