Subscriptions
Nothing that watches a deployment asks it repeatedly what is happening. A client that wants to know subscribes, on either projection, and receives the same contract.
What a subscription promises
| # | Rule | On this surface |
|---|---|---|
| 1 | it begins with a snapshot | the record a read returns, for every subject the filter selects |
| 2 | delivery is bounded per subscriber | one queue of 256 events per subscription, not per connection |
| 3 | an overflow is announced with a fresh snapshot | the announcement belongs to the subscription and is not an event; nobody else sees it |
| 4 | events about one subject arrive in order | across subjects nothing is promised |
| 5 | what a client accumulates is a cache | valid while the subscription lives, never an authority; a client about to act asks the Core |
The snapshot is taken at an event sequence and the stream resumes at the next one. The rules are the event model's; see a subscription.
What a client selects with
The event axes, combined by conjunction. An axis the filter omits selects everything on it.
| Axis | Form |
|---|---|
| subject | a kind, or a kind and an identity |
| severity | a floor: at or above a value |
| type | exactly, or by prefix, read as segments |
| occurrence | exactly, or by prefix; only events that carry one |
See names and filtering.
On each projection
| The operator projection | The shell projection | |
|---|---|---|
| How one begins | subscribe, an operation whose answer is a stream | one stands from the moment the connection opens |
| Its filter | the caller's, stated in the call | every subject, every type, no severity floor — until the caller replaces it |
| How many | one per call, as many calls as the client makes | up to 8 on one connection, the standing one included |
| How one ends | the caller closes the stream | the caller cancels its call, or the connection ends |
The standing subscription is an ordinary subscription: its call identity is reported when the connection opens, it may be replaced by subscribing with a narrower filter, and it may be cancelled.
Never confirmed here
No operation on this surface acknowledges a position, and no field of a subscription requests one. A tool that falls behind is told so by an overflow and given a fresh snapshot. Confirmed subscriptions exist only where something depends on a consumer being current, which is the interface surface.
A connection that stops answering is closed on its transport's liveness, not on confirmation.
Not an authorisation
Subscribing changes when a client learns something, never what it may learn. No filter widens what the surface entitles a caller to, and no event is carried to one client and withheld from another on the same surface.
Figures
| a subscription's queue | 256 events |
| the standing subscription's filter | every subject, every type, no severity floor |
| subscriptions per shell connection | 8 |
| confirmation | none, on either projection |