Module commands
Expand description
Commands sent from the client handle to the event loop.
Each command carries two completion channels:
-
queued_txis fired once the command’s session mutation has been made durable, regardless of connection state:- Subscriptions and
QoS>= 1 publishes: after the persist that covers the stored filter / outbox entry succeeds (immediately after the mutation when no persistence is configured). QoS0 publishes: immediately on acceptance (no durable state).
The
Optionwrapper allows the event loop to pre-fire the signal during the offline backoff phase and then process the wire send later. - Subscriptions and
-
completion_txis fired when the broker acknowledges the operation (PUBACK / PUBCOMP / SUBACK / UNSUBACK). ForQoS0 publishes it is resolved when the bytes are written.
Structs§
- Pending
Ack - Held by the event loop for an in-flight SUBSCRIBE or UNSUBSCRIBE, keyed by packet id. The core now owns the filter list and the reason-code rules; the runtime only needs to resolve the user-facing future on the ack.
- Pending
Publish - Held by the event loop for each in-flight
QoS>= 1 publish.
Enums§
- AckCompletion
- Where an in-flight SUBSCRIBE/UNSUBSCRIBE’s outcome goes once the SUBACK/UNSUBACK arrives (or the operation is dropped or superseded).
- Command