pub struct NSQConsumerConfig { /* private fields */ }
Expand description

Configuration object for an NSQ consumer.

Implementations

A default configuration. You will likely need to configure other options.

The maximum number of messages to process at once shared across all connections. Defaults to a single message.

Where an NSQ consumer should find connections. Either an explicit list of NSQ Daemons, or a list of NSQ Lookup Daemons to find NSQ instances. Defaults to no connections.

NSQ Daemon connection options, such as compression and TLS.

What percentage of messages to sample from the stream. Defaults to consuming all messages.

To maintain max in flight NSQ Daemons need to periodically have the ready count rebalanced. For example as nodes fail. Defaults to every 5 seconds.

The maximum limit on how long a requeued message is delayed. Defaults to 15 minutes.

When a message is first requeued, this controls how long it should be delayed for. Defaults to 90 seconds.

Construct an NSQ consumer with this configuration.

Trait Implementations

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Performs the conversion.

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more

Instruments this type with the current Span, returning an Instrumented wrapper. Read more

Performs the conversion.

The resulting type after obtaining ownership.

Creates owned data from borrowed data, usually by cloning. Read more

🔬 This is a nightly-only experimental API. (toowned_clone_into)

Uses borrowed data to replace owned data, usually by cloning. Read more

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more