consumer
ModuleStreams, consumers and the messages they deliver.
Contents
Structs
ConsumerA pull consumer.JetStreamMessageA message delivered by a JetStream consumer, to acknowledge.MessageBatchThe messages one pull returned.OrderedConsumerAn ordered consumer: an ephemeral push consumer with flow control and heartbeats, delivering in order, and recreated from the next stream sequence when a gap shows.PushSubscriptionA push consumer's subscription: data messages go to the callback, flow-control requests are answered and heartbeats swallowed. Drive it with `Connection::wait` or `Connection::process_message`.StreamA stream, with the info it was fetched with.use utopia_nats::jetstream::consumer::Consumer;Rust
pub struct ConsumerA pull consumer.
use utopia_nats::jetstream::consumer::JetStreamMessage;Rust
pub struct JetStreamMessageA message delivered by a JetStream consumer, to acknowledge.
use utopia_nats::jetstream::consumer::MessageBatch;Rust
pub struct MessageBatchThe messages one pull returned.
Also implements
IntoIterator.use utopia_nats::jetstream::consumer::OrderedConsumer;Rust
pub struct OrderedConsumerAn ordered consumer: an ephemeral push consumer with flow control and heartbeats, delivering in order, and recreated from the next stream sequence when a gap shows.
use utopia_nats::jetstream::consumer::PushSubscription;Rust
pub struct PushSubscriptionA push consumer's subscription: data messages go to the callback,
flow-control requests are answered and heartbeats swallowed. Drive it
with Connection::wait or Connection::process_message.
use utopia_nats::jetstream::consumer::Stream;Rust
pub struct StreamA stream, with the info it was fetched with.
use utopia_nats::jetstream::consumer::AckKind;Rust
pub enum AckKindHow a JetStream message is answered.
Rust
pub type PushCallback = Box<dyn FnMut(JetStreamMessage) -> Result<(), CallbackError> + Send>A callback receiving the messages of a push consumer.