Trait common_function::handlers::TableMutationHandler

source ·
pub trait TableMutationHandler: Send + Sync {
    // Required methods
    fn insert<'life0, 'async_trait>(
        &'life0 self,
        request: InsertRequest,
        ctx: QueryContextRef,
    ) -> Pin<Box<dyn Future<Output = Result<Output>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
    fn delete<'life0, 'async_trait>(
        &'life0 self,
        request: DeleteRequest,
        ctx: QueryContextRef,
    ) -> Pin<Box<dyn Future<Output = Result<AffectedRows>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
    fn flush<'life0, 'async_trait>(
        &'life0 self,
        request: FlushTableRequest,
        ctx: QueryContextRef,
    ) -> Pin<Box<dyn Future<Output = Result<AffectedRows>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
    fn compact<'life0, 'async_trait>(
        &'life0 self,
        request: CompactTableRequest,
        ctx: QueryContextRef,
    ) -> Pin<Box<dyn Future<Output = Result<AffectedRows>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
    fn flush_region<'life0, 'async_trait>(
        &'life0 self,
        region_id: RegionId,
        ctx: QueryContextRef,
    ) -> Pin<Box<dyn Future<Output = Result<AffectedRows>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
    fn compact_region<'life0, 'async_trait>(
        &'life0 self,
        region_id: RegionId,
        ctx: QueryContextRef,
    ) -> Pin<Box<dyn Future<Output = Result<AffectedRows>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
}
Expand description

A trait for handling table mutations in QueryEngine.

Required Methods§

source

fn insert<'life0, 'async_trait>( &'life0 self, request: InsertRequest, ctx: QueryContextRef, ) -> Pin<Box<dyn Future<Output = Result<Output>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Inserts rows into the table.

source

fn delete<'life0, 'async_trait>( &'life0 self, request: DeleteRequest, ctx: QueryContextRef, ) -> Pin<Box<dyn Future<Output = Result<AffectedRows>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Delete rows from the table.

source

fn flush<'life0, 'async_trait>( &'life0 self, request: FlushTableRequest, ctx: QueryContextRef, ) -> Pin<Box<dyn Future<Output = Result<AffectedRows>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Trigger a flush task for table.

source

fn compact<'life0, 'async_trait>( &'life0 self, request: CompactTableRequest, ctx: QueryContextRef, ) -> Pin<Box<dyn Future<Output = Result<AffectedRows>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Trigger a compaction task for table.

source

fn flush_region<'life0, 'async_trait>( &'life0 self, region_id: RegionId, ctx: QueryContextRef, ) -> Pin<Box<dyn Future<Output = Result<AffectedRows>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Trigger a flush task for a table region.

source

fn compact_region<'life0, 'async_trait>( &'life0 self, region_id: RegionId, ctx: QueryContextRef, ) -> Pin<Box<dyn Future<Output = Result<AffectedRows>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Trigger a compaction task for a table region.

Implementors§