pub trait Backoff: Send + Sync {
// Required methods
fn next_delay(&self, attempt: u32) -> Duration;
fn reset(&mut self);
}
Expand description
Trait defining backoff behavior
Required Methods§
sourcefn next_delay(&self, attempt: u32) -> Duration
fn next_delay(&self, attempt: u32) -> Duration
Calculate the next backoff delay