15
15
- [ Story 3] ( #story-3 )
16
16
- [ Story 4] ( #story-4 )
17
17
- [ Story 5] ( #story-5 )
18
- - [ Notes/Constraints/Caveats (Optional) ] ( #notesconstraintscaveats-optional )
18
+ - [ Notes/Constraints/Caveats] ( #notesconstraintscaveats )
19
19
- [ Risks and Mitigations] ( #risks-and-mitigations )
20
20
- [ Design Details] ( #design-details )
21
21
- [ Standard Heuristic Implementation (kube-proxy dataplane)] ( #standard-heuristic-implementation-kube-proxy-dataplane )
50
50
- [ Granular Routing Controls] ( #granular-routing-controls )
51
51
- [ Reuse Pod Topology Spread Constraints for Traffic Distribution] ( #reuse-pod-topology-spread-constraints-for-traffic-distribution )
52
52
- [ Complementary Use of Pod Topology Spread Constraints and routingPreference] ( #complementary-use-of-pod-topology-spread-constraints-and-routingpreference )
53
- - [ Infrastructure Needed (Optional)] ( #infrastructure-needed-optional )
54
53
<!-- /toc -->
55
54
56
55
## Release Signoff Checklist
@@ -132,7 +131,7 @@ Topology aware routing together with `internalTrafficPolicy` were meant to be
132
131
the successors of ` topologyKeys ` and allow implementations to be more flexible.
133
132
134
133
* TopologyAwareRouting:
135
- * Responds the annotation service.kubernetes.io/topology-mode. When this
134
+ * Responds the annotation ` service.kubernetes.io/topology-mode ` . When this
136
135
annotation is set to Auto, an implementation specific heuristic is used to
137
136
route the traffic.
138
137
* ** Goal:** The aim with Auto was to allow implementations to be as smart as
@@ -196,8 +195,8 @@ such a preference in future refinements.
196
195
interpretation might vary across implementations.
197
196
198
197
* ** Replacement of Traffic Policies:** The new field is complementary to
199
- InternalTrafficPolicy and ExternalTrafficPolicy . It does not aim to substitute
200
- their role in enforcing strict traffic locality.
198
+ ` internalTrafficPolicy ` and ` externalTrafficPolicy ` . It does not aim to
199
+ substitute their role in enforcing strict traffic locality.
201
200
202
201
* ** Immediate Support for All Possible Heuristics:** The initial implementation
203
202
focuses on a core set of heuristics. Addition of new heuristics (like
@@ -212,6 +211,8 @@ while making routing decisions. It does not offer strict routing guarantees.
212
211
213
212
The field will support the following initial values:
214
213
214
+ <<[ UNRESOLVED Name for field values is under discussion] >>
215
+
215
216
* ` Default ` : Indicates no specific routing preference. The user delegates the
216
217
routing decision to the implementation, allowing it to apply its best-effort
217
218
strategy.
@@ -221,6 +222,8 @@ The field will support the following initial values:
221
222
the client. If no endpoints are available within the zone, traffic should be
222
223
routed to other zones.
223
224
225
+ <<[ /UNRESOLVED] >>
226
+
224
227
Implementations are strongly encouraged to support the standard values. While
225
228
some flexibility in interpretation is permitted, implementations should aim to
226
229
align their behavior with the described intent of these preferences as closely
@@ -248,7 +251,7 @@ NOTE: Implementations reserve the right to refine the behavior associated with
248
251
* ** Requirement:** I don't have strong preferences for how my application
249
252
traffic is routed. I prioritize simplicity and trust my Kubernetes
250
253
implementation to optimize traffic distribution.
251
- * ** Solution:** Set ` routingPreference= Default ` (or leave the field unset)
254
+ * ** Solution:** Set ` routingPreference: Default ` (or leave the field unset)
252
255
* ** Effect:** The Kubernetes implementation will apply its best-effort routing
253
256
strategy based on its design. This strategy might change over time as the
254
257
implementation evolves. It may load balance across zones or regions.
@@ -257,7 +260,7 @@ NOTE: Implementations reserve the right to refine the behavior associated with
257
260
* ** Requirement:** I want my application to primarily receive traffic from
258
261
endpoints within the same zone for performance or cost reasons. However,
259
262
I want to avoid connection failures if no local endpoints are available.
260
- * ** Solution:** Set ` routingPreference= Zone `
263
+ * ** Solution:** Set ` routingPreference: Zone `
261
264
* ** Effect:** The Kubernetes implementation will aim to prioritize routing
262
265
traffic to endpoints in the same zone as the client. If no endpoints are
263
266
available within the zone, traffic will be routed to other zones. It's
@@ -269,7 +272,7 @@ NOTE: Implementations reserve the right to refine the behavior associated with
269
272
* ** Requirement:** I prioritize application availability and want to minimize the
270
273
risk of outages due to localized overload. I'm willing to accept potentially
271
274
higher costs associated with cross-zone traffic distribution.
272
- * ** Solution:** Set ` routingPreference= Spread `
275
+ * ** Solution:** Set ` routingPreference: Spread `
273
276
* ** Effect:** The Kubernetes implementation will try to distribute traffic as
274
277
equally as possible across endpoints, potentially spanning multiple zones or
275
278
regions. This can improve resilience but might lead to increased network
@@ -290,13 +293,13 @@ NOTE: Implementations reserve the right to refine the behavior associated with
290
293
* ** Requirement:** I have some other precise preferences for how traffic should
291
294
be routed, and I know that my chosen implementation supports the desired
292
295
preference.
293
- * ** Solution:** Set ` routingPreference= <domain>/<heuristicName> ` (where
296
+ * ** Solution:** Set ` routingPreference: <domain>/<heuristicName> ` (where
294
297
` <domain> ` and ` <heuristicName> ` are provided by your implementation).
295
298
* ** Effect:** The Kubernetes implementation will apply the specified routing
296
299
heuristic. It's important to note that the precise behavior of
297
300
implementation-specific heuristics might vary.
298
301
299
- ### Notes/Constraints/Caveats (Optional)
302
+ ### Notes/Constraints/Caveats
300
303
301
304
This proposal is our third attempt at an API revolving around such a
302
305
configuration. There's a non-zero chance that we may need to revisit this again.
@@ -340,15 +343,16 @@ as the control plane) will support the three standard routing preferences
340
343
341
344
#### ` Zone `
342
345
* This preference will be implemented by the use of Hints within EndpointSlices.
343
- * We already use Hints to implement ` service.kubernetes.io/topology-mode=Auto `
344
- Similarly, we’ll use the same Hints within the EndpointSlice to implement the
345
- ` Zone ` heuristic – the hints will match the zone of the endpoint itself.
346
+ * We already use Hints to implement ` service.kubernetes.io/topology-mode: Auto `
347
+ In a similar manner, the EndpointSlice controller will now also populate hints
348
+ for ` routingPreference: Zone ` -- although in this case, the zone hint will
349
+ match the endpoint of the zone itself.
346
350
* While it may seem redundant to populate the hints here since kube-proxy can
347
351
already derive the zone hint from the endpoints zone (as they would be the
348
352
same), we will still use this for implementation simply because of the reason
349
353
that it’s easier to implement and provides a better design. Consider an
350
354
alternative implementation where kube-proxy reads
351
- ` routingPreference= Zone ` field and then constructs the route rules
355
+ ` routingPreference: Zone ` field and then constructs the route rules
352
356
accordingly. This means some extra logic needs to be baked into the kube-proxy
353
357
which could have just as easily been implemented by an already existing
354
358
extensibility mechanism (i.e. EndpointSlice hints)
@@ -417,8 +421,8 @@ currently provide a condition denoting acknowledgment from the dataplane. In the
417
421
future when this is possible, another condition like the following could be
418
422
used:
419
423
420
- * RoutingPreferenceReady
421
- * ** Type:** ` RoutingPreferenceReady `
424
+ * RoutingPreferenceHonored
425
+ * ** Type:** ` RoutingPreferenceHonored `
422
426
* ** Description:** Confirms that the dataplane has received the hints,
423
427
acknowledged them, and configured itself accordingly.
424
428
@@ -480,22 +484,22 @@ captures the precedence
480
484
<td>-</td>
481
485
<td>-</td>
482
486
<td>Auto</td>
483
- <td>routingPreference= Auto</td>
484
- <td>routingPreference= Auto</td>
487
+ <td>routingPreference: Auto</td>
488
+ <td>routingPreference: Auto</td>
485
489
</tr >
486
490
<tr >
487
491
<td>Local</td>
488
492
<td>-</td>
489
493
<td>Auto</td>
490
- <td>ExternalTrafficPolicy= Local</td>
491
- <td>routingPreference= Auto</td>
494
+ <td>ExternalTrafficPolicy: Local</td>
495
+ <td>routingPreference: Auto</td>
492
496
</tr >
493
497
<tr >
494
498
<td>Local</td>
495
499
<td>Local</td>
496
500
<td>Auto</td>
497
- <td>ExternalTrafficPolicy= Local</td>
498
- <td>InternalTrafficPolicy= Local</td>
501
+ <td>ExternalTrafficPolicy: Local</td>
502
+ <td>InternalTrafficPolicy: Local</td>
499
503
</tr >
500
504
</tbody >
501
505
</table >
@@ -526,25 +530,24 @@ The following packages will also see minor changes:
526
530
527
531
##### Integration tests
528
532
529
- * Verify that if both the annotation ` service.kubernetes.io/topology-mode= Auto `
530
- and field ` routingPreference= Zone ` are configured, precedence is given
531
- to the annotation.
533
+ * Verify that if both the annotation ` service.kubernetes.io/topology-mode: Auto `
534
+ and field ` routingPreference: Zone ` are configured, precedence is given to the
535
+ annotation.
532
536
533
537
##### e2e tests
534
538
535
539
* Verify that EndpointSlice hints are correctly populated when
536
- ` routingPreference=Zone `
537
- * Verify through probes that when ` routingPreference=Zone ` , requests
538
- originating from a zone which has service pods get sent to a pod in the same
539
- zone. For requests originating from zones with no service pods, requests
540
- should not get blackholed and should rather be forwarded to any service pod
541
- from the cluster.
540
+ ` routingPreference ` is set to ` Zone ` .
541
+ * Verify through probes that for ` routingPreference: Zone ` , requests originating
542
+ from a zone which has service pods get sent to a pod in the same zone. For
543
+ requests originating from zones with no service pods, requests should not get
544
+ blackholed and should rather be forwarded to any service pod from the cluster.
542
545
543
546
### Graduation Criteria
544
547
545
548
#### Alpha
546
549
547
- - Feature implemented behind a feature flag
550
+ - Feature implemented behind a feature gate
548
551
- Initial e2e tests completed and enabled
549
552
550
553
### Upgrade / Downgrade Strategy
@@ -570,11 +573,11 @@ Version skews should naturally get handled as per the following behaviour.
570
573
571
574
* ** kube-apiserver:** [ Kubernetes Version Skew
572
575
Policies] ( https://kubernetes.io/releases/version-skew-policy/#supported-version-skew )
573
- require that kube-apiserver is atleast at the version of kube-proxy or
576
+ require that kube-apiserver is at least at the version of kube-proxy or
574
577
kube-controller-manager. The only valid version skew would mean that a newer
575
578
kube-apiserver serves the new ` routingPreference ` field but the older
576
579
kube-proxy and kube-controller-manager would silently ignore this field. (No
577
- adverse affect, behaviour equivalent to feature being disabled)
580
+ adverse affect, behaviour equivalent to feature being disabled).
578
581
579
582
* ** New kube-controller-manager (EndpointSlice controller) / Old kube-proxy:**
580
583
@@ -991,8 +994,3 @@ distribution when used in conjunction.
991
994
pod distribution across zones, maximizing the likelihood that the
992
995
` routingPreference ` can be satisfied and reduce (although not completely
993
996
eliminate) chances of overload for a single zone.
994
-
995
-
996
- ## Infrastructure Needed (Optional)
997
-
998
- N/A
0 commit comments