Struct azure_core::RetryOptions
source · [−]pub struct RetryOptions { /* private fields */ }
Expand description
Specify how retries should behave.
Note that not all requests can be retried. These options will only be used when a retry is attempted.
The default is an exponential retry policy using the default ExponentialRetryOptions
.
Implementations
sourceimpl RetryOptions
impl RetryOptions
sourcepub fn exponential(options: ExponentialRetryOptions) -> Self
pub fn exponential(options: ExponentialRetryOptions) -> Self
A retry strategy where attempts happen at intervals that get exponentially longer with each retry.
sourcepub fn fixed(options: FixedRetryOptions) -> Self
pub fn fixed(options: FixedRetryOptions) -> Self
A retry strategy where attempts happen at fixed intervals; each delay is a consistent duration.
sourcepub fn custom<T: RetryPolicy + 'static>(policy: Arc<T>) -> Self
pub fn custom<T: RetryPolicy + 'static>(policy: Arc<T>) -> Self
A custom retry using the supplied retry policy.
Trait Implementations
sourceimpl Clone for RetryOptions
impl Clone for RetryOptions
sourcefn clone(&self) -> RetryOptions
fn clone(&self) -> RetryOptions
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresourceimpl Debug for RetryOptions
impl Debug for RetryOptions
sourceimpl Default for RetryOptions
impl Default for RetryOptions
sourcefn default() -> RetryOptions
fn default() -> RetryOptions
Returns the “default value” for a type. Read more
Auto Trait Implementations
impl !RefUnwindSafe for RetryOptions
impl Send for RetryOptions
impl Sync for RetryOptions
impl Unpin for RetryOptions
impl !UnwindSafe for RetryOptions
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more