Skip to main content

MQPullConsumer

Trait MQPullConsumer 

Source
pub trait MQPullConsumer: Send + Sync {
    // Required methods
    async fn start(&self) -> ClientResult<()>;
    async fn shutdown(&self) -> ClientResult<()>;
    async fn pull(
        &self,
        message_queue: &MessageQueue,
        sub_expression: &str,
        offset: i64,
        max_messages: i32,
    ) -> ClientResult<PullResult>;
}
๐Ÿ‘ŽDeprecated since 0.9.0:

Classic Pull is retained for compatibility; prefer DefaultLitePullConsumer for new applications

Expand description

Common async surface implemented by Classic Pull facades.

Required Methodsยง

Source

async fn start(&self) -> ClientResult<()>

๐Ÿ‘ŽDeprecated since 0.9.0:

Classic Pull is retained for compatibility; prefer DefaultLitePullConsumer for new applications

Starts the consumer.

Source

async fn shutdown(&self) -> ClientResult<()>

๐Ÿ‘ŽDeprecated since 0.9.0:

Classic Pull is retained for compatibility; prefer DefaultLitePullConsumer for new applications

Shuts the consumer down.

Source

async fn pull( &self, message_queue: &MessageQueue, sub_expression: &str, offset: i64, max_messages: i32, ) -> ClientResult<PullResult>

๐Ÿ‘ŽDeprecated since 0.9.0:

Classic Pull is retained for compatibility; prefer DefaultLitePullConsumer for new applications

Pulls one queue by tag expression.

Dyn Compatibilityยง

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementorsยง