Skip to content

Commit

Permalink
Update streams.md
Browse files Browse the repository at this point in the history
  • Loading branch information
emiltin authored Dec 17, 2024
1 parent 5ddfa62 commit ad8e697
Showing 1 changed file with 16 additions and 22 deletions.
38 changes: 16 additions & 22 deletions docs/pages/streams.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,11 @@ Status updates are delivered via _streams_.

A stream defines how status updates are delived, including:

- status module and code, e.g. tlc/2
- attribute set
- update rate
- aggregation, e.g. sum and average
- chunking. ie. gather multiple events in a single message
- defaults state
- timeouts
- module and code, e.g. tlc/2
- attributes and their settings, e.g. live or update rate
- aggregation, e.g. sum or average
- default state (on/off)
- pruning, e.g. timeout

A node can have ome or more streams configured for each status type.

Expand All @@ -40,8 +38,7 @@ To receive data the stream must be started and you must be subscribed to the ass
Starting and stopping a stream controls whether data is published to the
associated topic path on the broker. If a stream is configured as on by default, you don't need to manually start it.

Subscribing to the associated topic path controls whether you receive
data from the broker.
Subscribing to the associated topic path controls whether you receive data from the broker.

## Starting and Stopping
When you start a stream, it starts publishing data to broker,
Expand All @@ -64,26 +61,23 @@ When you stop a stream, data is no longer publishhed to the broker.
Consumers will no longer receive data, even if they are still subscribed to the relevant topic path.

## Stream configuration
### Status module and id
### Module and id
Identifies the status with module name, and status code id, e.g. `tlc/2`.

### Attributes
The set of attributes to include in status updates. For each attribute:
- Type: Live (Send on Change), Lazy (send when other attributes change)
- Aggregation: off, count, average, median, max, min. Aggration is done according to the key interval.
The set of attributes to include in status updates, and their settings. For each attribute:
- Type: Send on Change, Send Along (send when other attributes change)
- Aggregation: off, count, average, median, max, min. Aggration is done according to the update rate.

### Key Interval
### Update Rate
Interval to send full updates, which are retained on the broker.

### Delta Interval
Interval to send delta updates which contain only attributes that changed
and are not retained on the broker.
### Delta Rate
Interval to send delta updates which contain only attributes that changed and are not retained on the broker.

If set to live, delta updates are send immediately when attributes changes.

If set to a number, it indicating the number of delta updates between key updates.
Update are send according to keyframe and delta intervals, not immediatelely
when attributes change.
Options:
- send on change: Delta updates are send immediately when attributes changes.
- interval: Delta update are send according to delta intervals.

### Default State
A stream configured as off by default must be started before it publishes data to the broker.
Expand Down

0 comments on commit ad8e697

Please sign in to comment.