Skip to content

Commit

Permalink
Added missing retryOn conditions (#6772)
Browse files Browse the repository at this point in the history
Signed-off-by: Tero Saarni <[email protected]>
  • Loading branch information
tsaarni authored Nov 26, 2024
1 parent d05f43a commit 63bb34a
Show file tree
Hide file tree
Showing 8 changed files with 38 additions and 1 deletion.
5 changes: 4 additions & 1 deletion apis/projectcontour/v1/httpproxy.go
Original file line number Diff line number Diff line change
Expand Up @@ -1146,7 +1146,7 @@ type TimeoutPolicy struct {
}

// RetryOn is a string type alias with validation to ensure that the value is valid.
// +kubebuilder:validation:Enum="5xx";gateway-error;reset;connect-failure;retriable-4xx;refused-stream;retriable-status-codes;retriable-headers;cancelled;deadline-exceeded;internal;resource-exhausted;unavailable
// +kubebuilder:validation:Enum="5xx";gateway-error;reset;reset-before-request;connect-failure;envoy-ratelimited;retriable-4xx;refused-stream;retriable-status-codes;retriable-headers;http3-post-connect-failure;cancelled;deadline-exceeded;internal;resource-exhausted;unavailable
type RetryOn string

// RetryPolicy defines the attributes associated with retrying policy.
Expand All @@ -1171,11 +1171,14 @@ type RetryPolicy struct {
// - `5xx`
// - `gateway-error`
// - `reset`
// - `reset-before-request`
// - `connect-failure`
// - `envoy-ratelimited`
// - `retriable-4xx`
// - `refused-stream`
// - `retriable-status-codes`
// - `retriable-headers`
// - `http3-post-connect-failure`
//
// Supported [gRPC conditions](https://www.envoyproxy.io/docs/envoy/latest/configuration/http/http_filters/router_filter#x-envoy-retry-grpc-on):
//
Expand Down
1 change: 1 addition & 0 deletions changelogs/unreleased/6772-tsaarni-small.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Added conditions `reset-before-request`, `envoy-ratelimited` and `http3-post-connect-failure` for `httpproxy.spec.routes.retryPolicy.retryOn`, see Envoy [documentation](https://www.envoyproxy.io/docs/envoy/v1.32.0/configuration/http/http_filters/router_filter#config-http-filters-router-x-envoy-retry-on) for more details.
6 changes: 6 additions & 0 deletions examples/contour/01-crds.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6702,11 +6702,14 @@ spec:
- `5xx`
- `gateway-error`
- `reset`
- `reset-before-request`
- `connect-failure`
- `envoy-ratelimited`
- `retriable-4xx`
- `refused-stream`
- `retriable-status-codes`
- `retriable-headers`
- `http3-post-connect-failure`
Supported [gRPC conditions](https://www.envoyproxy.io/docs/envoy/latest/configuration/http/http_filters/router_filter#x-envoy-retry-grpc-on):
- `cancelled`
- `deadline-exceeded`
Expand All @@ -6720,11 +6723,14 @@ spec:
- 5xx
- gateway-error
- reset
- reset-before-request
- connect-failure
- envoy-ratelimited
- retriable-4xx
- refused-stream
- retriable-status-codes
- retriable-headers
- http3-post-connect-failure
- cancelled
- deadline-exceeded
- internal
Expand Down
6 changes: 6 additions & 0 deletions examples/render/contour-deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6922,11 +6922,14 @@ spec:
- `5xx`
- `gateway-error`
- `reset`
- `reset-before-request`
- `connect-failure`
- `envoy-ratelimited`
- `retriable-4xx`
- `refused-stream`
- `retriable-status-codes`
- `retriable-headers`
- `http3-post-connect-failure`
Supported [gRPC conditions](https://www.envoyproxy.io/docs/envoy/latest/configuration/http/http_filters/router_filter#x-envoy-retry-grpc-on):
- `cancelled`
- `deadline-exceeded`
Expand All @@ -6940,11 +6943,14 @@ spec:
- 5xx
- gateway-error
- reset
- reset-before-request
- connect-failure
- envoy-ratelimited
- retriable-4xx
- refused-stream
- retriable-status-codes
- retriable-headers
- http3-post-connect-failure
- cancelled
- deadline-exceeded
- internal
Expand Down
6 changes: 6 additions & 0 deletions examples/render/contour-gateway-provisioner.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6713,11 +6713,14 @@ spec:
- `5xx`
- `gateway-error`
- `reset`
- `reset-before-request`
- `connect-failure`
- `envoy-ratelimited`
- `retriable-4xx`
- `refused-stream`
- `retriable-status-codes`
- `retriable-headers`
- `http3-post-connect-failure`
Supported [gRPC conditions](https://www.envoyproxy.io/docs/envoy/latest/configuration/http/http_filters/router_filter#x-envoy-retry-grpc-on):
- `cancelled`
- `deadline-exceeded`
Expand All @@ -6731,11 +6734,14 @@ spec:
- 5xx
- gateway-error
- reset
- reset-before-request
- connect-failure
- envoy-ratelimited
- retriable-4xx
- refused-stream
- retriable-status-codes
- retriable-headers
- http3-post-connect-failure
- cancelled
- deadline-exceeded
- internal
Expand Down
6 changes: 6 additions & 0 deletions examples/render/contour-gateway.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6738,11 +6738,14 @@ spec:
- `5xx`
- `gateway-error`
- `reset`
- `reset-before-request`
- `connect-failure`
- `envoy-ratelimited`
- `retriable-4xx`
- `refused-stream`
- `retriable-status-codes`
- `retriable-headers`
- `http3-post-connect-failure`
Supported [gRPC conditions](https://www.envoyproxy.io/docs/envoy/latest/configuration/http/http_filters/router_filter#x-envoy-retry-grpc-on):
- `cancelled`
- `deadline-exceeded`
Expand All @@ -6756,11 +6759,14 @@ spec:
- 5xx
- gateway-error
- reset
- reset-before-request
- connect-failure
- envoy-ratelimited
- retriable-4xx
- refused-stream
- retriable-status-codes
- retriable-headers
- http3-post-connect-failure
- cancelled
- deadline-exceeded
- internal
Expand Down
6 changes: 6 additions & 0 deletions examples/render/contour.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6922,11 +6922,14 @@ spec:
- `5xx`
- `gateway-error`
- `reset`
- `reset-before-request`
- `connect-failure`
- `envoy-ratelimited`
- `retriable-4xx`
- `refused-stream`
- `retriable-status-codes`
- `retriable-headers`
- `http3-post-connect-failure`
Supported [gRPC conditions](https://www.envoyproxy.io/docs/envoy/latest/configuration/http/http_filters/router_filter#x-envoy-retry-grpc-on):
- `cancelled`
- `deadline-exceeded`
Expand All @@ -6940,11 +6943,14 @@ spec:
- 5xx
- gateway-error
- reset
- reset-before-request
- connect-failure
- envoy-ratelimited
- retriable-4xx
- refused-stream
- retriable-status-codes
- retriable-headers
- http3-post-connect-failure
- cancelled
- deadline-exceeded
- internal
Expand Down
3 changes: 3 additions & 0 deletions site/content/docs/main/config/api-reference.html
Original file line number Diff line number Diff line change
Expand Up @@ -3518,11 +3518,14 @@ <h3 id="projectcontour.io/v1.RetryPolicy">RetryPolicy
<li><code>5xx</code></li>
<li><code>gateway-error</code></li>
<li><code>reset</code></li>
<li><code>reset-before-request</code></li>
<li><code>connect-failure</code></li>
<li><code>envoy-ratelimited</code></li>
<li><code>retriable-4xx</code></li>
<li><code>refused-stream</code></li>
<li><code>retriable-status-codes</code></li>
<li><code>retriable-headers</code></li>
<li><code>http3-post-connect-failure</code></li>
</ul>
<p>Supported <a href="https://www.envoyproxy.io/docs/envoy/latest/configuration/http/http_filters/router_filter#x-envoy-retry-grpc-on">gRPC conditions</a>:</p>
<ul>
Expand Down

0 comments on commit 63bb34a

Please sign in to comment.