Trait apalis_core::layers::ack::Ack

source ·
pub trait Ack<J> {
    type Acknowledger;

    // Required method
    fn ack<'life0, 'life1, 'life2, 'async_trait>(
        &'life0 self,
        worker_id: &'life1 WorkerId,
        data: &'life2 Self::Acknowledger
    ) -> Pin<Box<dyn Future<Output = Result<(), AckError>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait,
             'life2: 'async_trait;
}
Available on crate feature extensions only.
Expand description

A trait for acknowledging successful job processing

Required Associated Types§

source

type Acknowledger

The data to fetch from context to allow acknowledgement

Required Methods§

source

fn ack<'life0, 'life1, 'life2, 'async_trait>( &'life0 self, worker_id: &'life1 WorkerId, data: &'life2 Self::Acknowledger ) -> Pin<Box<dyn Future<Output = Result<(), AckError>> + Send + 'async_trait>>where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait,

Acknowledges successful processing of the given request

Implementors§

source§

impl<J, S> Ack<J> for Swhere S: Storage<Output = J> + Send + Sync, J: Send + Sync,

Available on crate feature storage only.