Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
outbound: add request timeout fields (#243)
This branch adds fields to the `OutboundPolicies` API messages for configuring request timeouts. The `HttpRoute.Rule` and `GrpcRoute.Rule` messages now contain a `requestTimeout` field, which contains a `Duration` for a request timeout for that rule. In addition, the `RouteBackend` messages also contain a `requestTimeout` field, which configures a duration for requests dispatched to that specific backend. All new fields have comments describing their intended semantics. These fields are primarily intended to support the new timeout fields added to the HTTPRoute CRD in GEP-1742 (see linkerd/linkerd2#10969). The HTTPRoute timeout configuration are an additional field on the `rule` fields in a route that contains optional `request` and `backendRequest` timeouts. This means that a single request timeout and backend request timeout is set for all backends on an individual route rule. The proxy API additions in this PR are somewhat more flexible than the current HTTPRoute CRD, as each `RouteBackend` has its *own* field for the `backendRequest` timeout. This means that in theory, independent `backendRequest` timeout values could be configured for each individual backend. HTTPRoute doesn't currently support this, but it felt like a good idea to add this flexibility in the proxy API regardless, to support future use cases.
- Loading branch information