You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
(See status definitions [here](/geps/overview/#gep-states).)
7
7
@@ -29,7 +29,7 @@ Multiple data plane proxies offer optional configuration for budgeted retries, i
29
29
30
30
Configuring a limit for client retries is an important factor in building a resilient system, allowing requests to be successfully retried during periods of intermittent failure. But too many client-side retries can also exacerbate consistent failures and slow down recovery, quickly overwhelming a failing system and leading to cascading failures such as retry storms. Configuring a sane limit for max client-side retries is often challenging in complex systems. Allowing an application developer (Ana) to configure a dynamic "retry budget" reduces the risk of a high number of retries across clients. It allows a service to perform as expected in both times of high & low request load, as well as both during periods of intermittent & consistent failures.
31
31
32
-
While retry budget configuration has been a frequently discussed feature within the community, differences in the semantics between data plane implementations creates a challenge for a consensus on the correct location for the configuration. This proposal aims to determine where retry budget's should be defined within the Gateway API, and whether data plane proxies may need to be altered to accommodate the specification.
32
+
While retry budget configuration has been a frequently discussed feature within the community, differences in the semantics between data plane implementations creates a challenge for a consensus on the correct location for the configuration. This proposal aims to determine where retry budgets should be defined within the Gateway API, and whether data plane proxies may need to be altered to accommodate the specification.
33
33
34
34
### Background on implementations
35
35
@@ -49,7 +49,9 @@ By default, Envoy uses a static threshold for retries. But when configured, Envo
49
49
50
50
The Linkerd implementation of retry budgets is configured alongside service route configuration, within the [ServiceProfile CRD](https://linkerd.io/2.12/reference/service-profiles/), limiting the number of total retries for a service as a percentage of the number of recent requests. In practice, this functions similarly to Envoy's retry budget implementation, as it is configured in a single location and measures the ratio of retry requests to original requests across all traffic destined for the service.
51
51
52
-
Linkerd uses [budgeted retries](https://linkerd.io/2.15/features/retries-and-timeouts/) as the default configuration to specify retries to a service, but - as of [edge-24.7.5](https://github.com/linkerd/linkerd2/releases/tag/edge-24.7.5) - supports counted retries. In all cases, retries are implemented by the `linkerd2-proxy` making the request on behalf on an application workload.
52
+
(Note that budgeted retries have become less commonly used since Linkerd added support for counted retries in [edge-24.7.5](https://github.com/linkerd/linkerd2/releases/tag/edge-24.7.5): ServiceProfile operates at the level of a backend workload, meaning that it cannot configure anything at the level of a route, but counted retries can be configured using annotations on Service, HTTPRoute, and GRPCRoute.)
53
+
54
+
For both counted retries and budgeted retries, the actual retry logic is implemented by the `linkerd2-proxy` making the request on behalf on an application workload. The receiving proxy is not aware of the retry configuration at all.
53
55
54
56
Linkerd's budgeted retries allow retrying an indefinite number of times, as long as the fraction of retries remains within the budget. Budgeted retries are supported only using Linkerd's native ServiceProfile CRD, which allows enabling retries, setting the retry budget (by default, 20% plus 10 "extra" retries per second), and configuring the window over which the fraction of retries to non-retries is calculated. The `retryBudget` field of the ServiceProfile spec can be configured with the following optional parameters:
55
57
@@ -81,11 +83,144 @@ The implementation of a version of Linkerd's `ttl` parameter within Envoy might
81
83
82
84
### Go
83
85
84
-
TODO
86
+
```golang
87
+
typeBackendTrafficPolicystruct {
88
+
// BackendTrafficPolicy defines the configuration for how traffic to a target backend should be handled.
89
+
//
90
+
// Support: Extended
91
+
//
92
+
// +optional
93
+
// <gateway:experimental>
94
+
//
95
+
// Note: there is no Override or Default policy configuration.
96
+
97
+
metav1.TypeMeta`json:",inline"`
98
+
metav1.ObjectMeta`json:"metadata,omitempty"`
99
+
100
+
// Spec defines the desired state of BackendTrafficPolicy.
101
+
SpecBackendTrafficPolicySpec`json:"spec"`
102
+
103
+
// Status defines the current state of BackendTrafficPolicy.
104
+
StatusPolicyStatus`json:"status,omitempty"`
105
+
}
106
+
107
+
typeBackendTrafficPolicySpecstruct {
108
+
// TargetRef identifies an API object to apply policy to.
109
+
// Currently, Backends (i.e. Service, ServiceImport, or any
110
+
// implementation-specific backendRef) are the only valid API
message: "BackendTrafficPolicy field sessionPersistence is not supported for Istio mesh traffic."
212
+
- ancestorRef:
213
+
kind: Gateway
214
+
namespace: foo-ns
215
+
name: foo-ingress
216
+
controllerName: "istio.io/mesh-controller"
217
+
conditions:
218
+
- type: "Accepted"
219
+
status: "False"
220
+
reason: "Invalid"
221
+
message: "BackendTrafficPolicy fields retry.budgetPercentage, retry.budgetInterval and retry.minRetryRate are not supported for Istio ingress gateways."
0 commit comments