Skip to content

Commit 49c7eac

Browse files
authored
Merge pull request kubernetes#2442 from andrewsykim/prr-1959
KEP-1959: add prod readiness review for alpha
2 parents abb6665 + 47ddb31 commit 49c7eac

File tree

3 files changed

+190
-13
lines changed

3 files changed

+190
-13
lines changed
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
kep-number: 1959
2+
alpha:
3+
approver: "@johnbelamaric"

keps/sig-cloud-provider/1959-service-lb-class-field/README.md

Lines changed: 180 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,13 @@
1616
- [Graduation Criteria](#graduation-criteria)
1717
- [Upgrade / Downgrade Strategy](#upgrade--downgrade-strategy)
1818
- [Version Skew Strategy](#version-skew-strategy)
19+
- [Production Readiness Review Questionnaire](#production-readiness-review-questionnaire)
20+
- [Feature Enablement and Rollback](#feature-enablement-and-rollback)
21+
- [Rollout, Upgrade and Rollback Planning](#rollout-upgrade-and-rollback-planning)
22+
- [Monitoring Requirements](#monitoring-requirements)
23+
- [Dependencies](#dependencies)
24+
- [Scalability](#scalability)
25+
- [Troubleshooting](#troubleshooting)
1926
- [Implementation History](#implementation-history)
2027
- [Drawbacks](#drawbacks)
2128
- [Alternatives](#alternatives)
@@ -29,12 +36,12 @@
2936

3037
Items marked with (R) are required *prior to targeting to a milestone / release*.
3138

32-
- [ ] (R) Enhancement issue in release milestone, which links to KEP dir in [kubernetes/enhancements] (not the initial KEP PR)
33-
- [ ] (R) KEP approvers have approved the KEP status as `implementable`
34-
- [ ] (R) Design details are appropriately documented
35-
- [ ] (R) Test plan is in place, giving consideration to SIG Architecture and SIG Testing input
36-
- [ ] (R) Graduation criteria is in place
37-
- [ ] (R) Production readiness review completed
39+
- [X] (R) Enhancement issue in release milestone, which links to KEP dir in [kubernetes/enhancements] (not the initial KEP PR)
40+
- [X] (R) KEP approvers have approved the KEP status as `implementable`
41+
- [X] (R) Design details are appropriately documented
42+
- [X] (R) Test plan is in place, giving consideration to SIG Architecture and SIG Testing input
43+
- [X] (R) Graduation criteria is in place
44+
- [X] (R) Production readiness review completed
3845
- [ ] Production readiness review approved
3946
- [ ] "Implementation History" section is up-to-date for milestone
4047
- [ ] User-facing documentation has been created in [kubernetes/website], for publication to [kubernetes.io]
@@ -132,20 +139,22 @@ type ServiceSpec struct {
132139
// implementation is watching for Services with a matching class name. Any default load balancer
133140
// implementation (e.g. cloud providers) should ignore Services that set this field.
134141
// +optional
135-
LoadBalancerClassName string `json:"loadBalancerClass,omitempty"`
142+
LoadBalancerClass string `json:"loadBalancerClass,omitempty"`
136143
}
137144
```
138145

139-
* `loadBalancerClass` will be immutable only when the Service type is `LoadBalancer`, this way existing and future implementations
140-
do not have to worry about handling Services that change the class name. The class name is mutable and can be cleared when the
141-
type changes.
146+
* `loadBalancerClass` will be immutable when the Service type is `LoadBalancer`, this way existing and future implementations
147+
do not have to worry about handling Services that change the class name. The class name is mutable only when the type is not LoadBalancer and
148+
must be cleared when the type changes.
142149
* `loadBalancerClass` will be validated against label-style format.
143150
* the `loadBalancerClass` field will be feature gated. The field will be dropped during API strategy unless
144151
the feature gate is enabled.
152+
* all external implementations of Service LoadBalancer using a non-empty class name should use the finalizer `service.kubernetes.io/load-balancer-cleanup`
153+
to ensure proper garbage collection of external resources.
145154

146155
Required updates to service controller:
147156
* if the class field is NOT set for a Service, allow the cloud provider to reconcile the load balancer.
148-
* if the class annotation IS set for a Service, skip reconciliation of the Service from the cloud provider.
157+
* if the class field IS set for a Service, skip reconciliation of the Service from the cloud provider.
149158

150159
### Test Plan
151160

@@ -156,7 +165,7 @@ or an existing Service has the field set.
156165
* test API validation for immutability.
157166

158167
Integration tests:
159-
* test that the class field is propoerly cleared/validated when the Service type changes to and from `LoadBalancer`.
168+
* test that the class field is properly cleared/validated when the Service type changes to and from `LoadBalancer`.
160169

161170
E2E tests:
162171
* test that creating a Service with an unknown class name results in no load balancer being created for a Service.
@@ -181,6 +190,165 @@ has the field set already. This ensures apiserver can handle the new field on do
181190
Since this feature will be alpha for at least 1 release, an n-1 kube-controller-manager or cloud-controller-manager should
182191
handle enablement of this feature if a new apiserver enabled it.
183192

193+
## Production Readiness Review Questionnaire
194+
195+
### Feature Enablement and Rollback
196+
197+
_This section must be completed when targeting alpha to a release._
198+
199+
* **How can this feature be enabled / disabled in a live cluster?**
200+
- [X] Feature gate (also fill in values in `kep.yaml`)
201+
- Feature gate name: ServiceLoadBalancerClass
202+
- Components depending on the feature gate: kube-apiserver, kube-controller-manager
203+
- [ ] Other
204+
- Describe the mechanism:
205+
- Will enabling / disabling the feature require downtime of the control
206+
plane?
207+
- Will enabling / disabling the feature require downtime or reprovisioning
208+
of a node? (Do not assume `Dynamic Kubelet Config` feature is enabled).
209+
210+
* **Does enabling the feature change any default behavior?**
211+
No, the default service controller in Kubernetes will continue to watch and implement
212+
any Services with an empty class name. Behavior is only changed when the class name is set.
213+
214+
* **Can the feature be disabled once it has been enabled (i.e. can we roll back
215+
the enablement)?**
216+
Yes, the feature can be disabled, but any existing Services using the new field will
217+
continue to have the field set. External controllers watching a specific class name
218+
will continue to watch and reconcile those Services.
219+
220+
* **What happens if we reenable the feature if it was previously rolled back?**
221+
New Services can continue to use the field. Existing Services with the field always had
222+
the field set so no behavior is changed when the feature is re-enabled.
223+
224+
225+
* **Are there any tests for feature enablement/disablement?**
226+
Yes, there will be unit tests in Service strategy, validation and defaulting to ensure
227+
the field cannot be used when the feature is disabled.
228+
229+
### Rollout, Upgrade and Rollback Planning
230+
231+
_This section must be completed when targeting beta graduation to a release._
232+
233+
* **How can a rollout fail? Can it impact already running workloads?**
234+
235+
TBD for beta
236+
237+
* **What specific metrics should inform a rollback?**
238+
239+
TBD for beta
240+
241+
* **Were upgrade and rollback tested? Was the upgrade->downgrade->upgrade path tested?**
242+
243+
TBD for beta
244+
245+
* **Is the rollout accompanied by any deprecations and/or removals of features, APIs,
246+
fields of API types, flags, etc.?**
247+
248+
TBD for beta
249+
250+
### Monitoring Requirements
251+
252+
_This section must be completed when targeting beta graduation to a release._
253+
254+
* **How can an operator determine if the feature is in use by workloads?**
255+
256+
TBD for beta
257+
258+
* **What are the SLIs (Service Level Indicators) an operator can use to determine
259+
the health of the service?**
260+
261+
TBD for beta
262+
263+
- [ ] Metrics
264+
- Metric name:
265+
- [Optional] Aggregation method:
266+
- Components exposing the metric:
267+
- [ ] Other (treat as last resort)
268+
- Details:
269+
270+
* **What are the reasonable SLOs (Service Level Objectives) for the above SLIs?**
271+
272+
TBD for beta
273+
274+
* **Are there any missing metrics that would be useful to have to improve observability
275+
of this feature?**
276+
277+
TBD for beta
278+
279+
### Dependencies
280+
281+
_This section must be completed when targeting beta graduation to a release._
282+
283+
* **Does this feature depend on any specific services running in the cluster?**
284+
285+
TBD for beta
286+
287+
288+
### Scalability
289+
290+
_For alpha, this section is encouraged: reviewers should consider these questions
291+
and attempt to answer them._
292+
293+
_For beta, this section is required: reviewers must answer these questions._
294+
295+
_For GA, this section is required: approvers should be able to confirm the
296+
previous answers based on experience in the field._
297+
298+
* **Will enabling / using this feature result in any new API calls?**
299+
300+
Introduction of this feature enables multiple implementations of Service LoadBalancer
301+
for a single cluster. New API calls will be introduced by new controllers operating against
302+
Services with a non-empty class name. This feature does not introduce new API calls from
303+
core Kubernetes components.
304+
305+
* **Will enabling / using this feature result in introducing new API types?**
306+
307+
No
308+
309+
* **Will enabling / using this feature result in any new calls to the cloud
310+
provider?**
311+
312+
Yes, introduction of new load balancer "classes" can introduce new calls to the cloud provider.
313+
314+
* **Will enabling / using this feature result in increasing size or count of
315+
the existing API objects?**
316+
317+
Yes, Service will (negligibly) increase with the addition of 1 new field.
318+
319+
* **Will enabling / using this feature result in increasing time taken by any
320+
operations covered by [existing SLIs/SLOs]?**
321+
322+
No
323+
324+
* **Will enabling / using this feature result in non-negligible increase of
325+
resource usage (CPU, RAM, disk, IO, ...) in any components?**
326+
327+
This change should not impact any core Kubernetes components.
328+
329+
### Troubleshooting
330+
331+
The Troubleshooting section currently serves the `Playbook` role. We may consider
332+
splitting it into a dedicated `Playbook` document (potentially with some monitoring
333+
details). For now, we leave it here.
334+
335+
_This section must be completed when targeting beta graduation to a release._
336+
337+
* **How does this feature react if the API server and/or etcd is unavailable?**
338+
339+
TBD for beta.
340+
341+
* **What are other known failure modes?**
342+
343+
TBD for beta.
344+
345+
* **What steps should be taken if SLOs are not being met to determine the problem?**
346+
347+
TBD for beta.
348+
349+
[supported limits]: https://git.k8s.io/community//sig-scalability/configs-and-limits/thresholds.md
350+
[existing SLIs/SLOs]: https://git.k8s.io/community/sig-scalability/slos/slos.md#kubernetes-slisslos
351+
184352
## Implementation History
185353

186354
- the `Summary`, `Motivation`, `Proposal` and `Design Details` sections was merged, signaling SIG acceptance

keps/sig-cloud-provider/1959-service-lb-class-field/kep.yaml

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,9 +24,15 @@ stage: alpha
2424
# The most recent milestone for which work toward delivery of this KEP has been
2525
# done. This can be the current (upcoming) milestone, if it is being actively
2626
# worked on.
27-
# latest-milestone: "v1.21"
27+
latest-milestone: "v1.21"
2828

2929
# The milestone at which this feature was, or is targeted to be, at each stage.
3030
milestone:
3131
alpha: "v1.21"
3232

33+
feature-gates:
34+
- name: ServiceLoadBalancerClass
35+
components:
36+
- kube-apiserver
37+
- kube-controller-manager
38+
disable-supported: true

0 commit comments

Comments
 (0)