pub trait Storage:
Send
+ Sync
+ 'static
+ Clone {
Show 27 methods
// Required methods
fn job_types_added<'life0, 'async_trait>(
&'life0 self,
job_types: Vec<JobType>,
) -> Pin<Box<dyn Future<Output = Result<(), Report>> + Send + 'async_trait>>
where 'life0: 'async_trait,
Self: 'async_trait;
fn jobs_added<'life0, 'async_trait>(
&'life0 self,
jobs: Vec<NewJob>,
) -> Pin<Box<dyn Future<Output = Result<(), Report>> + Send + 'async_trait>>
where 'life0: 'async_trait,
Self: 'async_trait;
fn jobs_cancelled<'life0, 'life1, 'async_trait>(
&'life0 self,
job_ids: &'life1 [Uuid],
timestamp: SystemTime,
) -> Pin<Box<dyn Future<Output = Result<Vec<CancelledJob>, Report>> + Send + 'async_trait>>
where 'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait;
fn executions_added<'life0, 'async_trait>(
&'life0 self,
executions: Vec<NewExecution>,
timestamp: SystemTime,
) -> Pin<Box<dyn Future<Output = Result<(), Report>> + Send + 'async_trait>>
where 'life0: 'async_trait,
Self: 'async_trait;
fn executions_ready<'life0, 'life1, 'async_trait>(
&'life0 self,
execution_ids: &'life1 [Uuid],
timestamp: SystemTime,
) -> Pin<Box<dyn Future<Output = Result<(), Report>> + Send + 'async_trait>>
where 'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait;
fn execution_assigned<'life0, 'async_trait>(
&'life0 self,
execution_id: Uuid,
executor_id: Uuid,
timestamp: SystemTime,
) -> Pin<Box<dyn Future<Output = Result<(), Report>> + Send + 'async_trait>>
where 'life0: 'async_trait,
Self: 'async_trait;
fn execution_started<'life0, 'async_trait>(
&'life0 self,
execution_id: Uuid,
timestamp: SystemTime,
) -> Pin<Box<dyn Future<Output = Result<(), Report>> + Send + 'async_trait>>
where 'life0: 'async_trait,
Self: 'async_trait;
fn execution_succeeded<'life0, 'async_trait>(
&'life0 self,
execution_id: Uuid,
timestamp: SystemTime,
output_payload_json: String,
) -> Pin<Box<dyn Future<Output = Result<(), Report>> + Send + 'async_trait>>
where 'life0: 'async_trait,
Self: 'async_trait;
fn executions_failed<'life0, 'life1, 'async_trait>(
&'life0 self,
execution_ids: &'life1 [Uuid],
timestamp: SystemTime,
reason: String,
mark_job_unschedulable: bool,
) -> Pin<Box<dyn Future<Output = Result<(), Report>> + Send + 'async_trait>>
where 'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait;
fn orphan_execution_ids<'life0, 'life1, 'async_trait>(
&'life0 self,
executor_ids: &'life1 [Uuid],
) -> Pin<Box<dyn Future<Output = Result<Vec<Uuid>, Report>> + Send + 'async_trait>>
where 'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait;
fn jobs_unschedulable<'life0, 'life1, 'async_trait>(
&'life0 self,
job_ids: &'life1 [Uuid],
timestamp: SystemTime,
) -> Pin<Box<dyn Future<Output = Result<(), Report>> + Send + 'async_trait>>
where 'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait;
fn pending_executions<'life0, 'async_trait>(
&'life0 self,
after: Option<Uuid>,
) -> Pin<Box<dyn Future<Output = Result<Vec<PendingExecution>, Report>> + Send + 'async_trait>>
where 'life0: 'async_trait,
Self: 'async_trait;
fn ready_executions<'life0, 'async_trait>(
&'life0 self,
after: Option<Uuid>,
) -> Pin<Box<dyn Future<Output = Result<Vec<ReadyExecution>, Report>> + Send + 'async_trait>>
where 'life0: 'async_trait,
Self: 'async_trait;
fn pending_jobs<'life0, 'async_trait>(
&'life0 self,
after: Option<Uuid>,
) -> Pin<Box<dyn Future<Output = Result<Vec<PendingJob>, Report>> + Send + 'async_trait>>
where 'life0: 'async_trait,
Self: 'async_trait;
fn query_jobs<'life0, 'async_trait>(
&'life0 self,
cursor: Option<String>,
limit: usize,
order: JobQueryOrder,
filters: JobQueryFilters,
) -> Pin<Box<dyn Future<Output = Result<JobQueryResult, Report>> + Send + 'async_trait>>
where 'life0: 'async_trait,
Self: 'async_trait;
fn query_job_ids<'life0, 'async_trait>(
&'life0 self,
filters: JobQueryFilters,
) -> Pin<Box<dyn Future<Output = Result<Vec<Uuid>, Report>> + Send + 'async_trait>>
where 'life0: 'async_trait,
Self: 'async_trait;
fn count_jobs<'life0, 'async_trait>(
&'life0 self,
filters: JobQueryFilters,
) -> Pin<Box<dyn Future<Output = Result<u64, Report>> + Send + 'async_trait>>
where 'life0: 'async_trait,
Self: 'async_trait;
fn query_job_types<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<Vec<JobType>, Report>> + Send + 'async_trait>>
where 'life0: 'async_trait,
Self: 'async_trait;
fn delete_jobs<'life0, 'async_trait>(
&'life0 self,
filters: JobQueryFilters,
) -> Pin<Box<dyn Future<Output = Result<Vec<Uuid>, Report>> + Send + 'async_trait>>
where 'life0: 'async_trait,
Self: 'async_trait;
fn schedules_added<'life0, 'async_trait>(
&'life0 self,
schedules: Vec<NewSchedule>,
) -> Pin<Box<dyn Future<Output = Result<(), Report>> + Send + 'async_trait>>
where 'life0: 'async_trait,
Self: 'async_trait;
fn schedules_cancelled<'life0, 'life1, 'async_trait>(
&'life0 self,
schedule_ids: &'life1 [Uuid],
timestamp: SystemTime,
) -> Pin<Box<dyn Future<Output = Result<Vec<CancelledSchedule>, Report>> + Send + 'async_trait>>
where 'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait;
fn schedules_unschedulable<'life0, 'life1, 'async_trait>(
&'life0 self,
schedule_ids: &'life1 [Uuid],
timestamp: SystemTime,
) -> Pin<Box<dyn Future<Output = Result<(), Report>> + Send + 'async_trait>>
where 'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait;
fn pending_schedules<'life0, 'async_trait>(
&'life0 self,
after: Option<Uuid>,
) -> Pin<Box<dyn Future<Output = Result<Vec<PendingSchedule>, Report>> + Send + 'async_trait>>
where 'life0: 'async_trait,
Self: 'async_trait;
fn query_schedules<'life0, 'async_trait>(
&'life0 self,
cursor: Option<String>,
limit: usize,
filters: ScheduleQueryFilters,
order: ScheduleQueryOrder,
) -> Pin<Box<dyn Future<Output = Result<ScheduleQueryResult, Report>> + Send + 'async_trait>>
where 'life0: 'async_trait,
Self: 'async_trait;
fn query_schedule_ids<'life0, 'async_trait>(
&'life0 self,
filters: ScheduleQueryFilters,
) -> Pin<Box<dyn Future<Output = Result<Vec<Uuid>, Report>> + Send + 'async_trait>>
where 'life0: 'async_trait,
Self: 'async_trait;
fn count_schedules<'life0, 'async_trait>(
&'life0 self,
filters: ScheduleQueryFilters,
) -> Pin<Box<dyn Future<Output = Result<u64, Report>> + Send + 'async_trait>>
where 'life0: 'async_trait,
Self: 'async_trait;
fn delete_schedules<'life0, 'async_trait>(
&'life0 self,
filters: ScheduleQueryFilters,
) -> Pin<Box<dyn Future<Output = Result<Vec<Uuid>, Report>> + Send + 'async_trait>>
where 'life0: 'async_trait,
Self: 'async_trait;
}
Expand description
An interface for storing and querying job and schedule data used by the Ora server.
Required Methods§
Sourcefn job_types_added<'life0, 'async_trait>(
&'life0 self,
job_types: Vec<JobType>,
) -> Pin<Box<dyn Future<Output = Result<(), Report>> + Send + 'async_trait>>where
'life0: 'async_trait,
Self: 'async_trait,
fn job_types_added<'life0, 'async_trait>(
&'life0 self,
job_types: Vec<JobType>,
) -> Pin<Box<dyn Future<Output = Result<(), Report>> + Send + 'async_trait>>where
'life0: 'async_trait,
Self: 'async_trait,
Add or update a job type.
Sourcefn jobs_added<'life0, 'async_trait>(
&'life0 self,
jobs: Vec<NewJob>,
) -> Pin<Box<dyn Future<Output = Result<(), Report>> + Send + 'async_trait>>where
'life0: 'async_trait,
Self: 'async_trait,
fn jobs_added<'life0, 'async_trait>(
&'life0 self,
jobs: Vec<NewJob>,
) -> Pin<Box<dyn Future<Output = Result<(), Report>> + Send + 'async_trait>>where
'life0: 'async_trait,
Self: 'async_trait,
Persist the given new jobs.
Sourcefn jobs_cancelled<'life0, 'life1, 'async_trait>(
&'life0 self,
job_ids: &'life1 [Uuid],
timestamp: SystemTime,
) -> Pin<Box<dyn Future<Output = Result<Vec<CancelledJob>, Report>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait,
fn jobs_cancelled<'life0, 'life1, 'async_trait>(
&'life0 self,
job_ids: &'life1 [Uuid],
timestamp: SystemTime,
) -> Pin<Box<dyn Future<Output = Result<Vec<CancelledJob>, Report>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait,
Cancel the given jobs.
- Mark the job as cancelled.
- Mark the job as unschedulable.
Returns the cancelled jobs with their active executions, if any.
Sourcefn executions_added<'life0, 'async_trait>(
&'life0 self,
executions: Vec<NewExecution>,
timestamp: SystemTime,
) -> Pin<Box<dyn Future<Output = Result<(), Report>> + Send + 'async_trait>>where
'life0: 'async_trait,
Self: 'async_trait,
fn executions_added<'life0, 'async_trait>(
&'life0 self,
executions: Vec<NewExecution>,
timestamp: SystemTime,
) -> Pin<Box<dyn Future<Output = Result<(), Report>> + Send + 'async_trait>>where
'life0: 'async_trait,
Self: 'async_trait,
Add new executions.
Sourcefn executions_ready<'life0, 'life1, 'async_trait>(
&'life0 self,
execution_ids: &'life1 [Uuid],
timestamp: SystemTime,
) -> Pin<Box<dyn Future<Output = Result<(), Report>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait,
fn executions_ready<'life0, 'life1, 'async_trait>(
&'life0 self,
execution_ids: &'life1 [Uuid],
timestamp: SystemTime,
) -> Pin<Box<dyn Future<Output = Result<(), Report>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait,
An execution is ready to be executed.
Sourcefn execution_assigned<'life0, 'async_trait>(
&'life0 self,
execution_id: Uuid,
executor_id: Uuid,
timestamp: SystemTime,
) -> Pin<Box<dyn Future<Output = Result<(), Report>> + Send + 'async_trait>>where
'life0: 'async_trait,
Self: 'async_trait,
fn execution_assigned<'life0, 'async_trait>(
&'life0 self,
execution_id: Uuid,
executor_id: Uuid,
timestamp: SystemTime,
) -> Pin<Box<dyn Future<Output = Result<(), Report>> + Send + 'async_trait>>where
'life0: 'async_trait,
Self: 'async_trait,
An execution was assigned to an executor.
Sourcefn execution_started<'life0, 'async_trait>(
&'life0 self,
execution_id: Uuid,
timestamp: SystemTime,
) -> Pin<Box<dyn Future<Output = Result<(), Report>> + Send + 'async_trait>>where
'life0: 'async_trait,
Self: 'async_trait,
fn execution_started<'life0, 'async_trait>(
&'life0 self,
execution_id: Uuid,
timestamp: SystemTime,
) -> Pin<Box<dyn Future<Output = Result<(), Report>> + Send + 'async_trait>>where
'life0: 'async_trait,
Self: 'async_trait,
Set an execution as started.
Sourcefn execution_succeeded<'life0, 'async_trait>(
&'life0 self,
execution_id: Uuid,
timestamp: SystemTime,
output_payload_json: String,
) -> Pin<Box<dyn Future<Output = Result<(), Report>> + Send + 'async_trait>>where
'life0: 'async_trait,
Self: 'async_trait,
fn execution_succeeded<'life0, 'async_trait>(
&'life0 self,
execution_id: Uuid,
timestamp: SystemTime,
output_payload_json: String,
) -> Pin<Box<dyn Future<Output = Result<(), Report>> + Send + 'async_trait>>where
'life0: 'async_trait,
Self: 'async_trait,
Set an execution as succeeded.
Sourcefn executions_failed<'life0, 'life1, 'async_trait>(
&'life0 self,
execution_ids: &'life1 [Uuid],
timestamp: SystemTime,
reason: String,
mark_job_unschedulable: bool,
) -> Pin<Box<dyn Future<Output = Result<(), Report>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait,
fn executions_failed<'life0, 'life1, 'async_trait>(
&'life0 self,
execution_ids: &'life1 [Uuid],
timestamp: SystemTime,
reason: String,
mark_job_unschedulable: bool,
) -> Pin<Box<dyn Future<Output = Result<(), Report>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait,
Set an execution as failed, if mark_job_unschedulable
is false
the job is not marked as unschedulable, this happens when the job
is retried.
Sourcefn orphan_execution_ids<'life0, 'life1, 'async_trait>(
&'life0 self,
executor_ids: &'life1 [Uuid],
) -> Pin<Box<dyn Future<Output = Result<Vec<Uuid>, Report>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait,
fn orphan_execution_ids<'life0, 'life1, 'async_trait>(
&'life0 self,
executor_ids: &'life1 [Uuid],
) -> Pin<Box<dyn Future<Output = Result<Vec<Uuid>, Report>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait,
Return assigned executions that are not assigned to any of the given executor IDs.
Sourcefn jobs_unschedulable<'life0, 'life1, 'async_trait>(
&'life0 self,
job_ids: &'life1 [Uuid],
timestamp: SystemTime,
) -> Pin<Box<dyn Future<Output = Result<(), Report>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait,
fn jobs_unschedulable<'life0, 'life1, 'async_trait>(
&'life0 self,
job_ids: &'life1 [Uuid],
timestamp: SystemTime,
) -> Pin<Box<dyn Future<Output = Result<(), Report>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait,
Mark a job as unschedulable.
No more executions will be created for the jobs and the given IDs must not be
returned by the pending_jobs
method. However existing executions are not affected.
Sourcefn pending_executions<'life0, 'async_trait>(
&'life0 self,
after: Option<Uuid>,
) -> Pin<Box<dyn Future<Output = Result<Vec<PendingExecution>, Report>> + Send + 'async_trait>>where
'life0: 'async_trait,
Self: 'async_trait,
fn pending_executions<'life0, 'async_trait>(
&'life0 self,
after: Option<Uuid>,
) -> Pin<Box<dyn Future<Output = Result<Vec<PendingExecution>, Report>> + Send + 'async_trait>>where
'life0: 'async_trait,
Self: 'async_trait,
Executions that are not yet ready to be executed.
The returned values must be in ascending order,
an optional after
parameter can be used to filter out values
that were created before the given UUID.
If the after
parameter is given, the stream must not include
the execution with the given UUID and any IDs that are smaller.
The implementation may choose to return a limited number of executions in a single call in order to avoid resource exhaustion.
Sourcefn ready_executions<'life0, 'async_trait>(
&'life0 self,
after: Option<Uuid>,
) -> Pin<Box<dyn Future<Output = Result<Vec<ReadyExecution>, Report>> + Send + 'async_trait>>where
'life0: 'async_trait,
Self: 'async_trait,
fn ready_executions<'life0, 'async_trait>(
&'life0 self,
after: Option<Uuid>,
) -> Pin<Box<dyn Future<Output = Result<Vec<ReadyExecution>, Report>> + Send + 'async_trait>>where
'life0: 'async_trait,
Self: 'async_trait,
Unassigned executions that are ready at the time of the call.
The returned values must be in ascending order,
an optional after
parameter can be used to filter out values
that were created before the given UUID.
The returned executions must be ordered by their ID in ascending order.
The implementation may choose to return a limited number of executions in a single call in order to avoid resource exhaustion.
Sourcefn pending_jobs<'life0, 'async_trait>(
&'life0 self,
after: Option<Uuid>,
) -> Pin<Box<dyn Future<Output = Result<Vec<PendingJob>, Report>> + Send + 'async_trait>>where
'life0: 'async_trait,
Self: 'async_trait,
fn pending_jobs<'life0, 'async_trait>(
&'life0 self,
after: Option<Uuid>,
) -> Pin<Box<dyn Future<Output = Result<Vec<PendingJob>, Report>> + Send + 'async_trait>>where
'life0: 'async_trait,
Self: 'async_trait,
Jobs that satisfy the following conditions:
- have no executions in progress
- are active
The returned values must be in ascending order,
an optional after
parameter can be used to filter out values
that were created before the given UUID.
The implementation may choose to return a limited number of executions in a single call in order to avoid resource exhaustion.
Sourcefn query_jobs<'life0, 'async_trait>(
&'life0 self,
cursor: Option<String>,
limit: usize,
order: JobQueryOrder,
filters: JobQueryFilters,
) -> Pin<Box<dyn Future<Output = Result<JobQueryResult, Report>> + Send + 'async_trait>>where
'life0: 'async_trait,
Self: 'async_trait,
fn query_jobs<'life0, 'async_trait>(
&'life0 self,
cursor: Option<String>,
limit: usize,
order: JobQueryOrder,
filters: JobQueryFilters,
) -> Pin<Box<dyn Future<Output = Result<JobQueryResult, Report>> + Send + 'async_trait>>where
'life0: 'async_trait,
Self: 'async_trait,
Query and return a list of jobs with the given parameters.
A next token can be provided to continue the query from the last result.
Sourcefn query_job_ids<'life0, 'async_trait>(
&'life0 self,
filters: JobQueryFilters,
) -> Pin<Box<dyn Future<Output = Result<Vec<Uuid>, Report>> + Send + 'async_trait>>where
'life0: 'async_trait,
Self: 'async_trait,
fn query_job_ids<'life0, 'async_trait>(
&'life0 self,
filters: JobQueryFilters,
) -> Pin<Box<dyn Future<Output = Result<Vec<Uuid>, Report>> + Send + 'async_trait>>where
'life0: 'async_trait,
Self: 'async_trait,
Query and return a list of job IDs with the given parameters.
Sourcefn count_jobs<'life0, 'async_trait>(
&'life0 self,
filters: JobQueryFilters,
) -> Pin<Box<dyn Future<Output = Result<u64, Report>> + Send + 'async_trait>>where
'life0: 'async_trait,
Self: 'async_trait,
fn count_jobs<'life0, 'async_trait>(
&'life0 self,
filters: JobQueryFilters,
) -> Pin<Box<dyn Future<Output = Result<u64, Report>> + Send + 'async_trait>>where
'life0: 'async_trait,
Self: 'async_trait,
Count the number of jobs that satisfy the given filters.
Sourcefn query_job_types<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<Vec<JobType>, Report>> + Send + 'async_trait>>where
'life0: 'async_trait,
Self: 'async_trait,
fn query_job_types<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<Vec<JobType>, Report>> + Send + 'async_trait>>where
'life0: 'async_trait,
Self: 'async_trait,
Query and return a list of job types with the given parameters.
Sourcefn delete_jobs<'life0, 'async_trait>(
&'life0 self,
filters: JobQueryFilters,
) -> Pin<Box<dyn Future<Output = Result<Vec<Uuid>, Report>> + Send + 'async_trait>>where
'life0: 'async_trait,
Self: 'async_trait,
fn delete_jobs<'life0, 'async_trait>(
&'life0 self,
filters: JobQueryFilters,
) -> Pin<Box<dyn Future<Output = Result<Vec<Uuid>, Report>> + Send + 'async_trait>>where
'life0: 'async_trait,
Self: 'async_trait,
Remove jobs and all related data, returns the removed job IDs.
This should also remove all executions created by the jobs.
Sourcefn schedules_added<'life0, 'async_trait>(
&'life0 self,
schedules: Vec<NewSchedule>,
) -> Pin<Box<dyn Future<Output = Result<(), Report>> + Send + 'async_trait>>where
'life0: 'async_trait,
Self: 'async_trait,
fn schedules_added<'life0, 'async_trait>(
&'life0 self,
schedules: Vec<NewSchedule>,
) -> Pin<Box<dyn Future<Output = Result<(), Report>> + Send + 'async_trait>>where
'life0: 'async_trait,
Self: 'async_trait,
Persist the given new schedules.
Sourcefn schedules_cancelled<'life0, 'life1, 'async_trait>(
&'life0 self,
schedule_ids: &'life1 [Uuid],
timestamp: SystemTime,
) -> Pin<Box<dyn Future<Output = Result<Vec<CancelledSchedule>, Report>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait,
fn schedules_cancelled<'life0, 'life1, 'async_trait>(
&'life0 self,
schedule_ids: &'life1 [Uuid],
timestamp: SystemTime,
) -> Pin<Box<dyn Future<Output = Result<Vec<CancelledSchedule>, Report>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait,
Cancel the given schedules.
- Mark the schedule as cancelled.
- Mark the schedule as unschedulable.
Returns the cancelled schedules.
Sourcefn schedules_unschedulable<'life0, 'life1, 'async_trait>(
&'life0 self,
schedule_ids: &'life1 [Uuid],
timestamp: SystemTime,
) -> Pin<Box<dyn Future<Output = Result<(), Report>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait,
fn schedules_unschedulable<'life0, 'life1, 'async_trait>(
&'life0 self,
schedule_ids: &'life1 [Uuid],
timestamp: SystemTime,
) -> Pin<Box<dyn Future<Output = Result<(), Report>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait,
Mark the given schedules as unschedulable.
Sourcefn pending_schedules<'life0, 'async_trait>(
&'life0 self,
after: Option<Uuid>,
) -> Pin<Box<dyn Future<Output = Result<Vec<PendingSchedule>, Report>> + Send + 'async_trait>>where
'life0: 'async_trait,
Self: 'async_trait,
fn pending_schedules<'life0, 'async_trait>(
&'life0 self,
after: Option<Uuid>,
) -> Pin<Box<dyn Future<Output = Result<Vec<PendingSchedule>, Report>> + Send + 'async_trait>>where
'life0: 'async_trait,
Self: 'async_trait,
Return all pending schedules.
A pending schedule is a schedule that satisfies all the following conditions:
- is active
- has not been cancelled
- has no active jobs
The returned values must be in ascending order,
an optional after
parameter can be used to filter out values
that were created before the given UUID.
The implementation may choose to return a limited number of executions in a single call in order to avoid resource exhaustion.
Sourcefn query_schedules<'life0, 'async_trait>(
&'life0 self,
cursor: Option<String>,
limit: usize,
filters: ScheduleQueryFilters,
order: ScheduleQueryOrder,
) -> Pin<Box<dyn Future<Output = Result<ScheduleQueryResult, Report>> + Send + 'async_trait>>where
'life0: 'async_trait,
Self: 'async_trait,
fn query_schedules<'life0, 'async_trait>(
&'life0 self,
cursor: Option<String>,
limit: usize,
filters: ScheduleQueryFilters,
order: ScheduleQueryOrder,
) -> Pin<Box<dyn Future<Output = Result<ScheduleQueryResult, Report>> + Send + 'async_trait>>where
'life0: 'async_trait,
Self: 'async_trait,
Query and return a list of schedules with the given parameters.
A next token can be provided to continue the query from the last result.
Sourcefn query_schedule_ids<'life0, 'async_trait>(
&'life0 self,
filters: ScheduleQueryFilters,
) -> Pin<Box<dyn Future<Output = Result<Vec<Uuid>, Report>> + Send + 'async_trait>>where
'life0: 'async_trait,
Self: 'async_trait,
fn query_schedule_ids<'life0, 'async_trait>(
&'life0 self,
filters: ScheduleQueryFilters,
) -> Pin<Box<dyn Future<Output = Result<Vec<Uuid>, Report>> + Send + 'async_trait>>where
'life0: 'async_trait,
Self: 'async_trait,
Query and return a list of schedule IDs with the given parameters.
Sourcefn count_schedules<'life0, 'async_trait>(
&'life0 self,
filters: ScheduleQueryFilters,
) -> Pin<Box<dyn Future<Output = Result<u64, Report>> + Send + 'async_trait>>where
'life0: 'async_trait,
Self: 'async_trait,
fn count_schedules<'life0, 'async_trait>(
&'life0 self,
filters: ScheduleQueryFilters,
) -> Pin<Box<dyn Future<Output = Result<u64, Report>> + Send + 'async_trait>>where
'life0: 'async_trait,
Self: 'async_trait,
Count the number of schedules that satisfy the given filters.
Sourcefn delete_schedules<'life0, 'async_trait>(
&'life0 self,
filters: ScheduleQueryFilters,
) -> Pin<Box<dyn Future<Output = Result<Vec<Uuid>, Report>> + Send + 'async_trait>>where
'life0: 'async_trait,
Self: 'async_trait,
fn delete_schedules<'life0, 'async_trait>(
&'life0 self,
filters: ScheduleQueryFilters,
) -> Pin<Box<dyn Future<Output = Result<Vec<Uuid>, Report>> + Send + 'async_trait>>where
'life0: 'async_trait,
Self: 'async_trait,
Remove schedules and all related data, returns the removed schedule IDs.
This should also remove all jobs created by the schedules.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.