pub struct TimeoutConfig {
pub timeout_duration: Duration,
pub max_retries: u32,
pub initial_retry_delay: Duration,
pub max_retry_delay: Duration,
pub backoff_multiplier: f64,
pub use_jitter: bool,
pub retry_on_timeout: bool,
pub retry_on_errors: Vec<String>,
}
Expand description
Configuration for timeout detection and retry behavior
Fields§
§timeout_duration: Duration
Maximum time allowed for the operation
max_retries: u32
Maximum number of retry attempts
initial_retry_delay: Duration
Initial delay between retries
max_retry_delay: Duration
Maximum delay between retries
backoff_multiplier: f64
Backoff multiplier for exponential backoff
use_jitter: bool
Whether to use jitter in retry delays
retry_on_timeout: bool
Whether to retry on timeout
retry_on_errors: Vec<String>
Whether to retry on specific error types
Implementations§
Source§impl TimeoutConfig
impl TimeoutConfig
Trait Implementations§
Source§impl Clone for TimeoutConfig
impl Clone for TimeoutConfig
Source§fn clone(&self) -> TimeoutConfig
fn clone(&self) -> TimeoutConfig
Returns a duplicate of the value. Read more
1.0.0 · 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 TimeoutConfig
impl Debug for TimeoutConfig
Source§impl Default for TimeoutConfig
impl Default for TimeoutConfig
Source§impl<'de> Deserialize<'de> for TimeoutConfig
impl<'de> Deserialize<'de> for TimeoutConfig
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for TimeoutConfig
impl RefUnwindSafe for TimeoutConfig
impl Send for TimeoutConfig
impl Sync for TimeoutConfig
impl Unpin for TimeoutConfig
impl UnwindSafe for TimeoutConfig
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