pub struct ClientConfig {
pub user_agent: String,
pub connect_timeout: Duration,
pub request_timeout: Duration,
pub response_timeout: Duration,
pub stream_timeout: Option<Duration>,
pub max_redirects: u32,
pub max_response_bytes: usize,
pub retry: RetryPolicy,
pub on_retry: Option<Arc<dyn Fn(&RetryEvent) + Send + Sync>>,
}Fields§
§user_agent: String§connect_timeout: Duration§request_timeout: DurationWhole-request deadline for buffered calls (headers + body).
response_timeout: DurationTime to receive response headers; for streams this is the first-byte (first-token) deadline.
stream_timeout: Option<Duration>Optional total lifetime cap for a stream body.
max_redirects: u32Redirects followed (0 = never; credentials are never replayed to a new host).
max_response_bytes: usize§retry: RetryPolicy§on_retry: Option<Arc<dyn Fn(&RetryEvent) + Send + Sync>>Trait Implementations§
Source§impl Clone for ClientConfig
impl Clone for ClientConfig
Auto Trait Implementations§
impl !RefUnwindSafe for ClientConfig
impl !UnwindSafe for ClientConfig
impl Freeze for ClientConfig
impl Send for ClientConfig
impl Sync for ClientConfig
impl Unpin for ClientConfig
impl UnsafeUnpin for ClientConfig
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