Expand description
§Qubit Event Bus
A lightweight, thread-safe in-process event bus for Rust.
Structs§
- Acknowledgement
- Handle used by subscriber code to acknowledge an event.
- Attempt
Timeout Option - Per-attempt timeout settings.
- Batch
Publish Failure - Failure captured while best-effort batch publishing continues.
- Batch
Publish Result - Result summary returned by best-effort batch publishing.
- Dead
Letter Record - Standard dead-letter record with diagnostic metadata and original payload.
- Event
Envelope - Standard message structure flowing through the event bus.
- Event
Envelope Builder - Builder used to create
EventEnvelopevalues with optional metadata. - Event
Envelope Metadata - Type-erased event metadata exposed to global interceptors.
- Local
Event Bus - Thread-safe in-process event bus.
- Local
Event BusFactory - Factory used to create
LocalEventBusinstances with default options. - Publish
Options - Immutable options applied when publishing events.
- Publish
Options Builder - Builder used to create
PublishOptions. - Retry
Options - Immutable retry option snapshot used by
crate::Retry. - Staged
Event Envelope - Typed event and publish options staged inside a transaction.
- Subscribe
Options - Immutable options applied to subscriber processing.
- Subscribe
Options Builder - Builder used to create
SubscribeOptions. - Subscriber
Interceptor AnyChain - Chain handle passed to global subscriber interceptors.
- Subscriber
Interceptor Chain - Chain handle passed to subscriber interceptors.
- Subscription
- Handle returned from a successful subscription.
- Topic
- Type-safe event topic.
- Topic
Key - Hashable key used internally to separate topics by name and payload type.
- Unsupported
Transactional Event Bus - Placeholder transactional bus used by factories without transaction support.
- Unsupported
Transactional Publisher - Placeholder transactional publisher used by unsupported transactional buses.
Enums§
- AckMode
- Controls how subscriber handlers acknowledge event processing.
- Attempt
Timeout Policy - Action taken when one attempt exceeds its configured per-attempt timeout.
- Event
BusError - Error returned by event bus configuration, publishing, or subscription work.
- Retry
Delay - Base delay strategy before jitter is applied.
- Retry
Jitter - Jitter strategy applied after a base
crate::RetryDelayhas been calculated.
Traits§
- Dead
Letter Strategy - Creates dead-letter envelopes for failed subscriber deliveries.
- Dead
Letter Strategy Any - Creates dead-letter envelopes without knowing the original payload type.
- Dead
Letter Strategy AnyCallback - Closure contract accepted by global dead-letter strategy builders.
- Dead
Letter Strategy Callback - Closure contract accepted by dead-letter strategy builders.
- Event
Bus - Common event bus contract implemented by concrete backends.
- Event
BusFactory - Factory contract for creating event bus instances.
- Into
Event BusResult - Converts closure return values into
EventBusResult<()>. - Into
Publisher Interceptor AnyResult - Converts global publisher interceptor return values into the standard form.
- Into
Publisher Interceptor Result - Converts publisher interceptor return values into the standard result form.
- Publisher
Interceptor - Intercepts events before they are published by a local event bus.
- Publisher
Interceptor Any - Intercepts outgoing event metadata before typed publisher interceptors run.
- Staged
Event - Type-erased event staged inside a transaction.
- Subscriber
Interceptor - Intercepts subscriber processing with around-style control.
- Subscriber
Interceptor Any - Intercepts subscriber processing for every payload type.
- Transactional
Event Bus - Event bus extension for transactional publishing backends.
- Transactional
Publisher - Publisher that buffers events until a transaction is committed.
Functions§
- discard_
dead_ letters - Creates a strategy that discards failed events.
- prefixed_
dead_ letters - Creates a strategy that routes standard dead letters to prefixed topics.
- standard_
dead_ letters_ to - Creates a strategy that routes standard dead-letter payloads to a topic.
Type Aliases§
- Dead
Letter Original Payload - Type-erased original payload stored inside dead-letter records.
- Dead
Letter Payload - Standard payload used by dead-letter envelopes.
- Event
BusResult - Result type used by event bus operations.