Level and edge
A consumer will miss events, and every event type says how the consumer gets back to a correct picture. A level announces that a current value changed, such as a unit's state, and a fresh snapshot recovers it. An edge announces an occurrence that leaves no trace in the current picture, and the log store keeps it. The class is declared with the type, and between the two nothing is lost in silence. This page gives the two classes, the rule that joins each to its recovery, and how an operator's decision is kept apart from an observation.
The two classes
| Class | Announces | Recovered by |
|---|---|---|
| level | that the current value of something changed — a unit's state, a channel's attachment, a plugin's policy | resynchronising: a fresh snapshot makes a consumer correct again |
| edge | an occurrence that leaves no trace in the current picture — a document that failed validation | reading: the log store holds it |
The rule
The subject of every level event appears in the snapshot, and every edge event has a durable counterpart as a log entry.
Between the two, nothing is lost in silence. Any individual event may be lost to a consumer; a level is recovered from the next snapshot and an edge from the log store.
| Direction | Holds when | A failure would be |
|---|---|---|
| level → snapshot | every level type's subject is a kind the snapshot carries | a subject a resynchronised consumer is silently wrong about |
| edge → log store | every edge type is written to the log store as it is published | an occurrence nobody can investigate |
- What a snapshot contains follows from the catalogue: the subjects of the level types the filter selects, and nothing else.
- Levels are written to the log store too, though a snapshot recovers them: a record of what happened is kept even where the current value could be rebuilt.
Observations and decisions
| Published | Kept | Budget | |
|---|---|---|---|
| an observation — a unit's life, a channel's occupancy, a connection | yes | as a log entry | under the log store's retention |
| a decision — an operator changing what a plugin may do | yes | as an audit record beside the policy it changed, in the Registry | none |
One type is a decision, plugin.policy.changed; every other type is an observation. See
the catalogue.