pub trait JobHandle: Send + Sync + 'static {
    type Err: Debug;

    fn ack_job<'life0, 'async_trait>(
        &'life0 self
    ) -> Pin<Box<dyn Future<Output = Result<(), Self::Err>> + Send + 'async_trait>>
    where
        'life0: 'async_trait,
        Self: 'async_trait
; fn nack_job<'life0, 'async_trait>(
        &'life0 self
    ) -> Pin<Box<dyn Future<Output = Result<(), Self::Err>> + Send + 'async_trait>>
    where
        'life0: 'async_trait,
        Self: 'async_trait
; }
Expand description

A trait to manager job timeouts and (n)acks

Required Associated Types

Type of errors that can occur

Required Methods

Ack the job referred by this JobHandle

N-ack the job referred by this JobHandle, this must trigger a requeue if the amount of tries has not exceeded the maximum amount

Implementors