Skip to main content

IdempotencyStore

Trait IdempotencyStore 

Source
pub trait IdempotencyStore:
    Send
    + Sync
    + Debug {
    // Required methods
    fn get<'life0, 'life1, 'async_trait>(
        &'life0 self,
        key: &'life1 IdempotencyKey,
    ) -> Pin<Box<dyn Future<Output = Result<Option<IdempotencyRecord>, IdempotencyError>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait;
    fn put_if_absent<'life0, 'async_trait>(
        &'life0 self,
        key: IdempotencyKey,
        record: IdempotencyRecord,
    ) -> Pin<Box<dyn Future<Output = Result<PutOutcome, IdempotencyError>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
}

Required Methods§

Source

fn get<'life0, 'life1, 'async_trait>( &'life0 self, key: &'life1 IdempotencyKey, ) -> Pin<Box<dyn Future<Output = Result<Option<IdempotencyRecord>, IdempotencyError>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Source

fn put_if_absent<'life0, 'async_trait>( &'life0 self, key: IdempotencyKey, record: IdempotencyRecord, ) -> Pin<Box<dyn Future<Output = Result<PutOutcome, IdempotencyError>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Dyn Compatibility§

This trait is dyn compatible.

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

Implementors§