InspectionStorage

Trait InspectionStorage 

Source
pub trait InspectionStorage:
    ResultStorage
    + Send
    + Sync {
    // Required methods
    fn stats<'life0, 'async_trait>(
        &'life0 self,
    ) -> Pin<Box<dyn Future<Output = Result<QueueStats, StorageError>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
    fn list_pending<'life0, 'async_trait>(
        &'life0 self,
        offset: usize,
        limit: usize,
    ) -> Pin<Box<dyn Future<Output = Result<Vec<ActivitySnapshot>, StorageError>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
    fn list_processing<'life0, 'async_trait>(
        &'life0 self,
        offset: usize,
        limit: usize,
    ) -> Pin<Box<dyn Future<Output = Result<Vec<ActivitySnapshot>, StorageError>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
    fn list_scheduled<'life0, 'async_trait>(
        &'life0 self,
        offset: usize,
        limit: usize,
    ) -> Pin<Box<dyn Future<Output = Result<Vec<ActivitySnapshot>, StorageError>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
    fn list_completed<'life0, 'async_trait>(
        &'life0 self,
        offset: usize,
        limit: usize,
    ) -> Pin<Box<dyn Future<Output = Result<Vec<ActivitySnapshot>, StorageError>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
    fn list_dead_letter<'life0, 'async_trait>(
        &'life0 self,
        offset: usize,
        limit: usize,
    ) -> Pin<Box<dyn Future<Output = Result<Vec<DeadLetterRecord>, StorageError>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
    fn get_activity<'life0, 'async_trait>(
        &'life0 self,
        activity_id: Uuid,
    ) -> Pin<Box<dyn Future<Output = Result<Option<ActivitySnapshot>, StorageError>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
    fn get_activity_events<'life0, 'async_trait>(
        &'life0 self,
        activity_id: Uuid,
        limit: usize,
    ) -> Pin<Box<dyn Future<Output = Result<Vec<ActivityEvent>, StorageError>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
    fn event_stream(
        &self,
    ) -> BoxStream<'static, Result<ActivityEvent, StorageError>>;
}
Expand description

Trait for observability and inspection operations.

This trait provides read-only access to queue state for monitoring, debugging, and building UIs.

Required Methods§

Source

fn stats<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<QueueStats, StorageError>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get current queue statistics.

Source

fn list_pending<'life0, 'async_trait>( &'life0 self, offset: usize, limit: usize, ) -> Pin<Box<dyn Future<Output = Result<Vec<ActivitySnapshot>, StorageError>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

List activities in the pending queue.

Source

fn list_processing<'life0, 'async_trait>( &'life0 self, offset: usize, limit: usize, ) -> Pin<Box<dyn Future<Output = Result<Vec<ActivitySnapshot>, StorageError>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

List activities currently being processed.

Source

fn list_scheduled<'life0, 'async_trait>( &'life0 self, offset: usize, limit: usize, ) -> Pin<Box<dyn Future<Output = Result<Vec<ActivitySnapshot>, StorageError>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

List activities scheduled for future execution.

Source

fn list_completed<'life0, 'async_trait>( &'life0 self, offset: usize, limit: usize, ) -> Pin<Box<dyn Future<Output = Result<Vec<ActivitySnapshot>, StorageError>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

List completed activities (recent).

Source

fn list_dead_letter<'life0, 'async_trait>( &'life0 self, offset: usize, limit: usize, ) -> Pin<Box<dyn Future<Output = Result<Vec<DeadLetterRecord>, StorageError>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

List activities in the dead letter queue.

Source

fn get_activity<'life0, 'async_trait>( &'life0 self, activity_id: Uuid, ) -> Pin<Box<dyn Future<Output = Result<Option<ActivitySnapshot>, StorageError>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get a specific activity by ID.

Source

fn get_activity_events<'life0, 'async_trait>( &'life0 self, activity_id: Uuid, limit: usize, ) -> Pin<Box<dyn Future<Output = Result<Vec<ActivityEvent>, StorageError>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get recent events for an activity.

Source

fn event_stream( &self, ) -> BoxStream<'static, Result<ActivityEvent, StorageError>>

Stream real-time activity events.

Returns a stream that yields events as they occur.

Implementors§