Skip to main content

JobStore

Trait JobStore 

Source
pub trait JobStore: Send + Sync {
    // Required methods
    fn save(&self, job: &JobRecord, events: &[Event]) -> Result<()>;
    fn get(&self, id: &str) -> Option<(JobRecord, Vec<Event>)>;
    fn list(&self, limit: usize) -> Vec<JobRecord>;
}
Expand description

Job records and their events.

Required Methods§

Source

fn save(&self, job: &JobRecord, events: &[Event]) -> Result<()>

Source

fn get(&self, id: &str) -> Option<(JobRecord, Vec<Event>)>

Source

fn list(&self, limit: usize) -> Vec<JobRecord>

Most recent first.

Dyn Compatibility§

This trait is dyn compatible.

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

Implementors§