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
Copy file name to clipboardExpand all lines: content/en/docs/reference/using-api/deprecation-guide.md
+38-33Lines changed: 38 additions & 33 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -6,7 +6,7 @@ reviewers:
6
6
- smarterclayton
7
7
title: "Deprecated API Migration Guide"
8
8
weight: 45
9
-
content_type: api_reference
9
+
content_type: reference
10
10
---
11
11
12
12
<!-- overview -->
@@ -25,15 +25,23 @@ deprecated API versions to newer and more stable API versions.
25
25
26
26
The **v1.25** release will stop serving the following deprecated API versions:
27
27
28
-
#### Event
28
+
#### Event {#event-v125}
29
29
30
30
The **events.k8s.io/v1beta1** API version of Event will no longer be served in v1.25.
31
31
32
32
* Migrate manifests and API clients to use the **events.k8s.io/v1** API version, available since v1.19.
33
33
* All existing persisted objects are accessible via the new API
34
-
* Notable changes
35
-
36
-
#### RuntimeClass
34
+
* Notable changes in **events.k8s.io/v1**:
35
+
*`type` is limited to `Normal` and `Warning`
36
+
*`involvedObject` is renamed to `regarding`
37
+
*`action`, `reason`, `reportingComponent`, and `reportingInstance` are required when creating new **events.k8s.io/v1** Events
38
+
* use `eventTime` instead of the deprecated `firstTimestamp` field (which is renamed to `deprecatedFirstTimestamp` and not permitted in new **events.k8s.io/v1** Events)
39
+
* use `series.lastObservedTime` instead of the deprecated `lastTimestamp` field (which is renamed to `deprecatedLastTimestamp` and not permitted in new **events.k8s.io/v1** Events)
40
+
* use `series.count` instead of the deprecated `count` field (which is renamed to `deprecatedCount` and not permitted in new **events.k8s.io/v1** Events)
41
+
* use `reportingComponent` instead of the deprecated `source.component` field (which is renamed to `deprecatedSource.component` and not permitted in new **events.k8s.io/v1** Events)
42
+
* use `reportingInstance` instead of the deprecated `source.host` field (which is renamed to `deprecatedSource.host` and not permitted in new **events.k8s.io/v1** Events)
43
+
44
+
#### RuntimeClass {#runtimeclass-v125}
37
45
38
46
RuntimeClass in the **node.k8s.io/v1beta1** API version will no longer be served in v1.25.
39
47
@@ -45,12 +53,12 @@ RuntimeClass in the **node.k8s.io/v1beta1** API version will no longer be served
45
53
46
54
The **v1.22** release will stop serving the following deprecated API versions:
47
55
48
-
#### MutatingWebhookConfiguration and ValidatingWebhookConfiguration
56
+
#### Webhook resources {#webhook-resources-v122}
49
57
50
58
The **admissionregistration.k8s.io/v1beta1** API version of MutatingWebhookConfiguration and ValidatingWebhookConfiguration will no longer be served in v1.22.
51
59
52
60
* Migrate manifests and API clients to use the **admissionregistration.k8s.io/v1** API version, available since v1.16.
53
-
* All existing persisted objects are accessible via the new API
61
+
* All existing persisted objects are accessible via the new APIs
54
62
* Notable changes:
55
63
*`webhooks[*].failurePolicy` default changed from `Ignore` to `Fail` for v1
56
64
*`webhooks[*].matchPolicy` default changed from `Exact` to `Equivalent` for v1
@@ -59,7 +67,7 @@ The **admissionregistration.k8s.io/v1beta1** API version of MutatingWebhookConfi
59
67
*`webhooks[*].admissionReviewVersions` default value is removed and the field made required for v1 (supported versions for AdmissionReview are `v1` and `v1beta1`)
60
68
*`webhooks[*].name` must be unique in the list for objects created via `admissionregistration.k8s.io/v1`
The **apiextensions.k8s.io/v1beta1** API version of CustomResourceDefinition will no longer be served in v1.22.
65
73
@@ -73,34 +81,34 @@ The **apiextensions.k8s.io/v1beta1** API version of CustomResourceDefinition wil
73
81
*`spec.additionalPrinterColumns` is removed in v1; use `spec.versions[*].additionalPrinterColumns` instead
74
82
*`spec.conversion.webhookClientConfig` is moved to `spec.conversion.webhook.clientConfig` in v1
75
83
*`spec.conversion.conversionReviewVersions` is moved to `spec.conversion.webhook.conversionReviewVersions` in v1
76
-
*`spec.versions[*].schema.openAPIV3Schema` is now required when creating v1 CustomResourceDefinitions, and must be a [structural schema](/docs/tasks/extend-kubernetes/custom-resources/custom-resource-definitions/#specifying-a-structural-schema)
77
-
*`spec.preserveUnknownFields: true` is disallowed when creating v1 CustomResourceDefinitions; it must be specified within schema definitions as `x-kubernetes-preserve-unknown-fields: true`
84
+
*`spec.versions[*].schema.openAPIV3Schema` is now required when creating v1 CustomResourceDefinition objects, and must be a [structural schema](/docs/tasks/extend-kubernetes/custom-resources/custom-resource-definitions/#specifying-a-structural-schema)
85
+
*`spec.preserveUnknownFields: true` is disallowed when creating v1 CustomResourceDefinition objects; it must be specified within schema definitions as `x-kubernetes-preserve-unknown-fields: true`
78
86
* In `additionalPrinterColumns` items, the `JSONPath` field was renamed to `jsonPath` in v1 (fixes [#66531](https://github.com/kubernetes/kubernetes/issues/66531))
79
87
80
-
#### APIService
88
+
#### APIService {#apiservice-v122}
81
89
82
90
The **apiregistration.k8s.io/v1beta1** API version of APIService will no longer be served in v1.22.
83
91
84
92
* Migrate manifests and API clients to use the **apiregistration.k8s.io/v1** API version, available since v1.10.
85
93
* All existing persisted objects are accessible via the new API
86
94
* No notable changes
87
95
88
-
#### TokenReview
96
+
#### TokenReview {#tokenreview-v122}
89
97
90
98
The **authentication.k8s.io/v1beta1** API version of TokenReview will no longer be served in v1.22.
91
99
92
100
* Migrate manifests and API clients to use the **authentication.k8s.io/v1** API version, available since v1.6.
The **authorization.k8s.io/v1beta1** API version of LocalSubjectAccessReview, SelfSubjectAccessReview, and SubjectAccessReview will no longer be served in v1.22.
98
106
99
107
* Migrate manifests and API clients to use the **authorization.k8s.io/v1** API version, available since v1.6.
100
108
* Notable changes:
101
109
*`spec.group` was renamed to `spec.groups` in v1 (fixes [#32709](https://github.com/kubernetes/kubernetes/issues/32709))
The **certificates.k8s.io/v1beta1** API version of CertificateSigningRequest will no longer be served in v1.22.
106
114
@@ -115,15 +123,15 @@ The **certificates.k8s.io/v1beta1** API version of CertificateSigningRequest wil
115
123
*`status.conditions[*].status` is now required
116
124
*`status.certificate` must be PEM-encoded, and contain only `CERTIFICATE` blocks
117
125
118
-
#### Lease
126
+
#### Lease {#lease-v122}
119
127
120
128
The **coordination.k8s.io/v1beta1** API version of Lease will no longer be served in v1.22.
121
129
122
130
* Migrate manifests and API clients to use the **coordination.k8s.io/v1** API version, available since v1.14.
123
131
* All existing persisted objects are accessible via the new API
124
132
* No notable changes
125
133
126
-
#### Ingress
134
+
#### Ingress {#ingress-v122}
127
135
128
136
The **extensions/v1beta1** and **networking.k8s.io/v1beta1** API versions of Ingress will no longer be served in v1.22.
129
137
@@ -136,31 +144,31 @@ The **extensions/v1beta1** and **networking.k8s.io/v1beta1** API versions of Ing
136
144
* String backend `servicePort` fields are renamed to `service.port.name`
137
145
*`pathType` is now required for each specified path. Options are `Prefix`, `Exact`, and `ImplementationSpecific`. To match the undefined `v1beta1` behavior, use `ImplementationSpecific`.
138
146
139
-
#### IngressClass
147
+
#### IngressClass {#ingressclass-v122}
140
148
141
149
The **networking.k8s.io/v1beta1** API version of IngressClass will no longer be served in v1.22.
142
150
143
151
* Migrate manifests and API clients to use the **networking.k8s.io/v1** API version, available since v1.19.
144
152
* All existing persisted objects are accessible via the new API
145
153
* No notable changes
146
154
147
-
#### RBAC
155
+
#### RBAC resources {#rbac-resources-v122}
148
156
149
157
The **rbac.authorization.k8s.io/v1beta1** API version of ClusterRole, ClusterRoleBinding, Role, and RoleBinding will no longer be served in v1.22.
150
158
151
159
* Migrate manifests and API clients to use the **networking.k8s.io/v1** API version, available since v1.8.
152
-
* All existing persisted objects are accessible via the new API
160
+
* All existing persisted objects are accessible via the new APIs
153
161
* No notable changes
154
162
155
-
#### PriorityClass
163
+
#### PriorityClass {#priorityclass-v122}
156
164
157
165
The **scheduling.k8s.io/v1beta1** API version of PriorityClass will no longer be served in v1.22.
158
166
159
167
* Migrate manifests and API clients to use the **scheduling.k8s.io/v1** API version, available since v1.14.
160
168
* All existing persisted objects are accessible via the new API
161
169
* No notable changes
162
170
163
-
#### Storage
171
+
#### Storage resources {#storage-resources-v122}
164
172
165
173
The **storage.k8s.io/v1beta1** API version of CSIDriver, CSINode, StorageClass, and VolumeAttachment will no longer be served in v1.22.
166
174
@@ -169,21 +177,21 @@ The **storage.k8s.io/v1beta1** API version of CSIDriver, CSINode, StorageClass,
169
177
* CSINode is available in **storage.k8s.io/v1** since v1.17
170
178
* StorageClass is available in **storage.k8s.io/v1** since v1.6
171
179
* VolumeAttachment is available in **storage.k8s.io/v1** v1.13
172
-
* All existing persisted objects are accessible via the new API
180
+
* All existing persisted objects are accessible via the new APIs
173
181
* No notable changes
174
182
175
183
### v1.16
176
184
177
185
The **v1.16** release stopped serving the following deprecated API versions:
178
186
179
-
#### NetworkPolicy
187
+
#### NetworkPolicy {#networkpolicy-v116}
180
188
181
189
The **extensions/v1beta1** API version of NetworkPolicy is no longer served as of v1.16.
182
190
183
191
* Migrate manifests and API clients to use the **networking.k8s.io/v1** API version, available since v1.8.
184
192
* All existing persisted objects are accessible via the new API
185
193
186
-
#### DaemonSet
194
+
#### DaemonSet {#daemonset-v116}
187
195
188
196
The **extensions/v1beta1** and **apps/v1beta2** API versions of DaemonSet are no longer served as of v1.16.
189
197
@@ -194,7 +202,7 @@ The **extensions/v1beta1** and **apps/v1beta2** API versions of DaemonSet are no
194
202
*`spec.selector` is now required and immutable after creation; use the existing template labels as the selector for seamless upgrades
195
203
*`spec.updateStrategy.type` now defaults to `RollingUpdate` (the default in `extensions/v1beta1` was `OnDelete`)
196
204
197
-
#### Deployment
205
+
#### Deployment {#deployment-v116}
198
206
199
207
The **extensions/v1beta1**, **apps/v1beta1**, and **apps/v1beta2** API versions of Deployment are no longer served as of v1.16.
200
208
@@ -207,7 +215,7 @@ The **extensions/v1beta1**, **apps/v1beta1**, and **apps/v1beta2** API versions
207
215
*`spec.revisionHistoryLimit` now defaults to `10` (the default in `apps/v1beta1` was `2`, the default in `extensions/v1beta1` was to retain all)
208
216
*`maxSurge` and `maxUnavailable` now default to `25%` (the default in `extensions/v1beta1` was `1`)
209
217
210
-
#### StatefulSet
218
+
#### StatefulSet {#statefulset-v116}
211
219
212
220
The **apps/v1beta1** and **apps/v1beta2** API versions of StatefulSet are no longer served as of v1.16.
213
221
@@ -217,7 +225,7 @@ The **apps/v1beta1** and **apps/v1beta2** API versions of StatefulSet are no lon
217
225
*`spec.selector` is now required and immutable after creation; use the existing template labels as the selector for seamless upgrades
218
226
*`spec.updateStrategy.type` now defaults to `RollingUpdate` (the default in `apps/v1beta1` was `OnDelete`)
219
227
220
-
#### ReplicaSet
228
+
#### ReplicaSet {#replicaset-v116}
221
229
222
230
The **extensions/v1beta1**, **apps/v1beta1**, and **apps/v1beta2** API versions of ReplicaSet are no longer served as of v1.16.
223
231
@@ -226,17 +234,14 @@ The **extensions/v1beta1**, **apps/v1beta1**, and **apps/v1beta2** API versions
226
234
* Notable changes:
227
235
*`spec.selector` is now required and immutable after creation; use the existing template labels as the selector for seamless upgrades
228
236
229
-
## What To Do
230
-
231
-
Kubernetes 1.22 will be released later in 2021, so be sure to audit
232
-
your configuration and integrations now!
237
+
## What to do
233
238
234
239
### Test with deprecated APIs disabled
235
240
236
241
You can test your clusters by starting an API server with specific API versions disabled
237
242
to simulate upcoming removals. Add the following flag to the API server startup arguments:
238
243
239
-
`--runtime-config=$group/$version=false`
244
+
`--runtime-config=<group>/<version>=false`
240
245
241
246
For example:
242
247
@@ -262,4 +267,4 @@ to locate use of deprecated APIs.
0 commit comments