pub struct RetryStrategy {
pub max_attempts: u32,
pub base_interval_ms: u64,
pub backoff: BackoffStrategy,
}Expand description
Retry strategy configuration
Fields§
§max_attempts: u32Maximum retry attempts
base_interval_ms: u64Base retry interval in milliseconds
backoff: BackoffStrategyBackoff strategy
Implementations§
Source§impl RetryStrategy
impl RetryStrategy
Sourcepub fn get_delay_ms(&self, attempt: u32) -> u64
pub fn get_delay_ms(&self, attempt: u32) -> u64
Get the delay for a given attempt
Trait Implementations§
Source§impl Clone for RetryStrategy
impl Clone for RetryStrategy
Source§fn clone(&self) -> RetryStrategy
fn clone(&self) -> RetryStrategy
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for RetryStrategy
impl Debug for RetryStrategy
Auto Trait Implementations§
impl Freeze for RetryStrategy
impl RefUnwindSafe for RetryStrategy
impl Send for RetryStrategy
impl Sync for RetryStrategy
impl Unpin for RetryStrategy
impl UnsafeUnpin for RetryStrategy
impl UnwindSafe for RetryStrategy
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more