Struct k8s_gateway_api::HttpRouteTimeouts
source · pub struct HttpRouteTimeouts {
pub request: Option<K8sDuration>,
pub backend_request: Option<K8sDuration>,
}
Expand description
HTTPRouteTimeouts defines timeouts that can be configured for an HTTPRoute. Timeout values are represented with Gateway API Duration formatting. Specifying a zero value such as “0s” is interpreted as no timeout.
Fields§
§request: Option<K8sDuration>
Request specifies the maximum duration for a gateway to respond to an HTTP request. If the gateway has not been able to respond before this deadline is met, the gateway MUST return a timeout error.
For example, setting the rules.timeouts.request
field to the value 10s
in an
HTTPRoute
will cause a timeout if a client request is taking longer than 10 seconds
to complete.
This timeout is intended to cover as close to the whole request-response transaction as possible although an implementation MAY choose to start the timeout after the entire request stream has been received instead of immediately after the transaction is initiated by the client.
When this field is unspecified, request timeout behavior is implementation-specific.
Support: Extended
backend_request: Option<K8sDuration>
BackendRequest specifies a timeout for an individual request from the gateway to a backend. This covers the time from when the request first starts being sent from the gateway to when the full response has been received from the backend.
An entire client HTTP transaction with a gateway, covered by the Request timeout, may result in more than one call from the gateway to the destination backend, for example, if automatic retries are supported.
Because the Request timeout encompasses the BackendRequest timeout, the value of BackendRequest must be <= the value of Request timeout.
Support: Extended
Trait Implementations§
source§impl Clone for HttpRouteTimeouts
impl Clone for HttpRouteTimeouts
source§fn clone(&self) -> HttpRouteTimeouts
fn clone(&self) -> HttpRouteTimeouts
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moresource§impl Debug for HttpRouteTimeouts
impl Debug for HttpRouteTimeouts
source§impl<'de> Deserialize<'de> for HttpRouteTimeouts
impl<'de> Deserialize<'de> for HttpRouteTimeouts
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 JsonSchema for HttpRouteTimeouts
impl JsonSchema for HttpRouteTimeouts
source§fn schema_name() -> String
fn schema_name() -> String
source§fn schema_id() -> Cow<'static, str>
fn schema_id() -> Cow<'static, str>
source§fn json_schema(gen: &mut SchemaGenerator) -> Schema
fn json_schema(gen: &mut SchemaGenerator) -> Schema
source§fn is_referenceable() -> bool
fn is_referenceable() -> bool
$ref
keyword. Read moresource§impl PartialEq for HttpRouteTimeouts
impl PartialEq for HttpRouteTimeouts
source§fn eq(&self, other: &HttpRouteTimeouts) -> bool
fn eq(&self, other: &HttpRouteTimeouts) -> bool
self
and other
values to be equal, and is used
by ==
.