Step

Trait Step 

Source
pub trait Step<Task>
where Task: Sized, Self: Into<Task> + Send + Sized + Debug + DeserializeOwned + Serialize,
{ const RETRY_LIMIT: i32 = 0i32; const RETRY_DELAY: Duration = _; // Required method fn step<'life0, 'async_trait>( self, db: &'life0 PgPool, ) -> Pin<Box<dyn Future<Output = StepResult<Task>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait; // Provided methods fn retry_limit(&self) -> i32 { ... } fn retry_delay(&self) -> Duration { ... } }
Expand description

A tait to implement on each task step

Provided Associated Constants§

Source

const RETRY_LIMIT: i32 = 0i32

How many times retry_limit the step on an error

Source

const RETRY_DELAY: Duration = _

The time to wait between retries

Required Methods§

Source

fn step<'life0, 'async_trait>( self, db: &'life0 PgPool, ) -> Pin<Box<dyn Future<Output = StepResult<Task>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Processes the current step and returns the next if any

Provided Methods§

Source

fn retry_limit(&self) -> i32

Proxies the RETRY const, doesn’t mean to be changed in impls

Source

fn retry_delay(&self) -> Duration

Proxies the RETRY_DELAY const, doesn’t mean to be changed in impls

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.

Implementors§