Trait MakeQueue

Source
pub trait MakeQueue: Send + Sync {
    type InputQueue: InputQueue<Err = Self::Err>;
    type OutputQueue: OutputQueue<Err = Self::Err>;
    type Err: Error + Send + Sync;

    // Required methods
    fn input_queue<'life0, 'life1, 'async_trait>(
        &'life0 self,
        name: &'life1 str,
        url: Url,
    ) -> Pin<Box<dyn Future<Output = Result<Self::InputQueue, Self::Err>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait;
    fn output_queue<'life0, 'life1, 'async_trait>(
        &'life0 self,
        name: &'life1 str,
        url: Url,
    ) -> Pin<Box<dyn Future<Output = Result<Self::OutputQueue, Self::Err>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait;
}
Expand description

The queue factory trait that takes care of creating queues

Required Associated Types§

Source

type InputQueue: InputQueue<Err = Self::Err>

The type of InputQueue returned by this factory

Source

type OutputQueue: OutputQueue<Err = Self::Err>

The type of OutputQueue returned by this factory

Source

type Err: Error + Send + Sync

The type of error that can occur when creating a job queue

Required Methods§

Source

fn input_queue<'life0, 'life1, 'async_trait>( &'life0 self, name: &'life1 str, url: Url, ) -> Pin<Box<dyn Future<Output = Result<Self::InputQueue, Self::Err>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Create a new job queue using this factory

Source

fn output_queue<'life0, 'life1, 'async_trait>( &'life0 self, name: &'life1 str, url: Url, ) -> Pin<Box<dyn Future<Output = Result<Self::OutputQueue, Self::Err>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Create a new OutputQueue with this MakeQueue

Implementors§