Skip to main content

OutboxHandler

Trait OutboxHandler 

Source
pub trait OutboxHandler: Send + Sync {
    type Error: Display + Send;

    // Required method
    fn handle<'life0, 'life1, 'async_trait>(
        &'life0 self,
        row: &'life1 OutboxRow,
    ) -> Pin<Box<dyn Future<Output = Result<(), Self::Error>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait;
}
Expand description

User-provided delivery target for outbox rows.

Required Associated Types§

Source

type Error: Display + Send

Handler error type.

Required Methods§

Source

fn handle<'life0, 'life1, 'async_trait>( &'life0 self, row: &'life1 OutboxRow, ) -> Pin<Box<dyn Future<Output = Result<(), Self::Error>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Deliver one event. Returning Err schedules a retry with exponential backoff.

Dyn Compatibility§

This trait is dyn compatible.

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

Implementors§