pub struct ListenConfig {
pub http: String,
pub max_connections: Option<usize>,
pub tls: Option<ListenTlsConfig>,
pub idle_timeout_secs: u64,
pub header_read_timeout_secs: u64,
}Expand description
The listener ProxyServer::serve runs.
Fields§
§http: StringListen address (default: “0.0.0.0:8080”).
max_connections: Option<usize>Most connections served at once; past it the next connection is accepted when one closes. Unset: no limit.
tls: Option<ListenTlsConfig>TLS on the listener, mTLS with client_ca_file. Unset: cleartext.
idle_timeout_secs: u64Seconds a connection may go without a request in flight before it is
closed (HTTP/2 gets a GOAWAY), so idle clients do not hold
max_connections slots. 0 keeps idle connections open. Default: 60.
header_read_timeout_secs: u64Seconds an HTTP/1.1 client has to send a request’s headers. At least
- Default: 30.
Trait Implementations§
Source§impl Clone for ListenConfig
impl Clone for ListenConfig
Source§impl Debug for ListenConfig
impl Debug for ListenConfig
Source§impl Default for ListenConfig
impl Default for ListenConfig
Source§impl<'de> Deserialize<'de> for ListenConfig
impl<'de> Deserialize<'de> for ListenConfig
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 ListenConfig
impl RefUnwindSafe for ListenConfig
impl Send for ListenConfig
impl Sync for ListenConfig
impl Unpin for ListenConfig
impl UnsafeUnpin for ListenConfig
impl UnwindSafe for ListenConfig
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
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> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
Wrap the input message
T in a tonic::Request