#[non_exhaustive]pub enum ClientConfigKey {
Show 18 variants
AllowHttp,
AllowInvalidCertificates,
ConnectTimeout,
DefaultContentType,
Http1Only,
Http2KeepAliveInterval,
Http2KeepAliveTimeout,
Http2KeepAliveWhileIdle,
Http2MaxFrameSize,
Http2Only,
PoolIdleTimeout,
PoolMaxIdlePerHost,
ProxyUrl,
ProxyCaCertificate,
ProxyExcludes,
RandomizeAddresses,
Timeout,
UserAgent,
}Expand description
Configuration keys for ClientOptions
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
AllowHttp
Allow non-TLS, i.e. non-HTTPS connections
Supported keys:
allow_http
AllowInvalidCertificates
Skip certificate validation on https connections.
Warning
You should think very carefully before using this method. If invalid certificates are trusted, any certificate for any site will be trusted for use. This includes expired certificates. This introduces significant vulnerabilities, and should only be used as a last resort or for testing
Supported keys:
allow_invalid_certificates
ConnectTimeout
Timeout for only the connect phase of a Client
Supported keys:
connect_timeout
DefaultContentType
Http1Only
Only use HTTP/1 connections
Supported keys:
http1_only
Http2KeepAliveInterval
Interval for HTTP/2 Ping frames should be sent to keep a connection alive.
Supported keys:
http2_keep_alive_interval
Http2KeepAliveTimeout
Timeout for receiving an acknowledgement of the keep-alive ping.
Supported keys:
http2_keep_alive_timeout
Http2KeepAliveWhileIdle
Enable HTTP/2 keep alive pings for idle connections
Supported keys:
http2_keep_alive_while_idle
Http2MaxFrameSize
Sets the maximum frame size to use for HTTP/2.
Supported keys:
http2_max_frame_size
Http2Only
Only use HTTP/2 connections
Supported keys:
http2_only
PoolIdleTimeout
The pool max idle timeout
This is the length of time an idle connection will be kept alive
Supported keys:
pool_idle_timeout
PoolMaxIdlePerHost
maximum number of idle connections per host
Supported keys:
pool_max_idle_per_host
ProxyUrl
HTTP proxy to use for requests
Supported keys:
proxy_url
ProxyCaCertificate
PEM-formatted CA certificate for proxy connections
Supported keys:
proxy_ca_certificate
ProxyExcludes
List of hosts that bypass proxy
Supported keys:
proxy_excludes
RandomizeAddresses
Randomize order addresses that the DNS resolution yields.
This will spread the connections across more servers.
Warning
This will override the DNS resolver configured by reqwest.
Supported keys:
randomize_addresses
Timeout
Request timeout
The timeout is applied from when the request starts connecting until the response body has finished
Supported keys:
timeout
UserAgent
User-Agent header to be used by this client
Supported keys:
user_agent
Trait Implementations§
Source§impl AsRef<str> for ClientConfigKey
impl AsRef<str> for ClientConfigKey
Source§impl Clone for ClientConfigKey
impl Clone for ClientConfigKey
Source§fn clone(&self) -> ClientConfigKey
fn clone(&self) -> ClientConfigKey
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for ClientConfigKey
impl Debug for ClientConfigKey
Source§impl<'de> Deserialize<'de> for ClientConfigKey
impl<'de> Deserialize<'de> for ClientConfigKey
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>,
Source§impl FromStr for ClientConfigKey
impl FromStr for ClientConfigKey
Source§impl Hash for ClientConfigKey
impl Hash for ClientConfigKey
Source§impl PartialEq for ClientConfigKey
impl PartialEq for ClientConfigKey
Source§impl Serialize for ClientConfigKey
impl Serialize for ClientConfigKey
impl Copy for ClientConfigKey
impl Eq for ClientConfigKey
impl StructuralPartialEq for ClientConfigKey
Auto Trait Implementations§
impl Freeze for ClientConfigKey
impl RefUnwindSafe for ClientConfigKey
impl Send for ClientConfigKey
impl Sync for ClientConfigKey
impl Unpin for ClientConfigKey
impl UnsafeUnpin for ClientConfigKey
impl UnwindSafe for ClientConfigKey
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more