Skip to content

Commit 4f8d7fd

Browse files
authored
Merge pull request #4447 from kubernetes-client/copilot/migrate-to-jakarta-namespace
Migrate from javax.annotation to jakarta.annotation namespace
2 parents 96aebb3 + 4f1e1b2 commit 4f8d7fd

File tree

203 files changed

+980
-971
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

203 files changed

+980
-971
lines changed

client-java-contrib/admissionreview/pom.xml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,8 @@
2525
<artifactId>gson</artifactId>
2626
</dependency>
2727
<dependency>
28-
<groupId>javax.annotation</groupId>
29-
<artifactId>javax.annotation-api</artifactId>
28+
<groupId>jakarta.annotation</groupId>
29+
<artifactId>jakarta.annotation-api</artifactId>
3030
<scope>provided</scope>
3131
</dependency>
3232
</dependencies>

client-java-contrib/admissionreview/src/main/java/io/kubernetes/client/admissionreview/models/AdmissionRequest.java

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
/** AdmissionRequest describes the admission.Attributes for the admission request. */
2222
@ApiModel(
2323
description = "AdmissionRequest describes the admission.Attributes for the admission request.")
24-
@javax.annotation.Generated(
24+
@jakarta.annotation.Generated(
2525
value = "org.openapitools.codegen.languages.JavaClientCodegen",
2626
date = "2021-07-01T14:30:02.888Z[Etc/UTC]")
2727
public class AdmissionRequest {
@@ -112,7 +112,7 @@ public AdmissionRequest dryRun(Boolean dryRun) {
112112
*
113113
* @return dryRun
114114
*/
115-
@javax.annotation.Nullable
115+
@jakarta.annotation.Nullable
116116
@ApiModelProperty(
117117
value =
118118
"DryRun indicates that modifications will definitely not be persisted for this request. Defaults to false.")
@@ -157,7 +157,7 @@ public AdmissionRequest name(String name) {
157157
*
158158
* @return name
159159
*/
160-
@javax.annotation.Nullable
160+
@jakarta.annotation.Nullable
161161
@ApiModelProperty(
162162
value =
163163
"Name is the name of the object as presented in the request. On a CREATE operation, the client may omit name and rely on the server to generate the name. If that is the case, this field will contain an empty string.")
@@ -180,7 +180,7 @@ public AdmissionRequest namespace(String namespace) {
180180
*
181181
* @return namespace
182182
*/
183-
@javax.annotation.Nullable
183+
@jakarta.annotation.Nullable
184184
@ApiModelProperty(value = "Namespace is the namespace associated with the request (if any).")
185185
public String getNamespace() {
186186
return namespace;
@@ -201,7 +201,7 @@ public AdmissionRequest _object(Map<String, Object> _object) {
201201
*
202202
* @return _object
203203
*/
204-
@javax.annotation.Nullable
204+
@jakarta.annotation.Nullable
205205
@ApiModelProperty(value = "")
206206
public Map<String, Object> getObject() {
207207
return _object;
@@ -222,7 +222,7 @@ public AdmissionRequest oldObject(Map<String, Object> oldObject) {
222222
*
223223
* @return oldObject
224224
*/
225-
@javax.annotation.Nullable
225+
@jakarta.annotation.Nullable
226226
@ApiModelProperty(value = "")
227227
public Map<String, Object> getOldObject() {
228228
return oldObject;
@@ -267,7 +267,7 @@ public AdmissionRequest options(Map<String, Object> options) {
267267
*
268268
* @return options
269269
*/
270-
@javax.annotation.Nullable
270+
@jakarta.annotation.Nullable
271271
@ApiModelProperty(value = "")
272272
public Map<String, Object> getOptions() {
273273
return options;
@@ -288,7 +288,7 @@ public AdmissionRequest requestKind(GroupVersionKind requestKind) {
288288
*
289289
* @return requestKind
290290
*/
291-
@javax.annotation.Nullable
291+
@jakarta.annotation.Nullable
292292
@ApiModelProperty(value = "")
293293
public GroupVersionKind getRequestKind() {
294294
return requestKind;
@@ -309,7 +309,7 @@ public AdmissionRequest requestResource(GroupVersionResource requestResource) {
309309
*
310310
* @return requestResource
311311
*/
312-
@javax.annotation.Nullable
312+
@jakarta.annotation.Nullable
313313
@ApiModelProperty(value = "")
314314
public GroupVersionResource getRequestResource() {
315315
return requestResource;
@@ -333,7 +333,7 @@ public AdmissionRequest requestSubResource(String requestSubResource) {
333333
*
334334
* @return requestSubResource
335335
*/
336-
@javax.annotation.Nullable
336+
@jakarta.annotation.Nullable
337337
@ApiModelProperty(
338338
value =
339339
"RequestSubResource is the name of the subresource of the original API request, if any (for example, \"status\" or \"scale\") If this is specified and differs from the value in \"subResource\", an equivalent match and conversion was performed. See documentation for the \"matchPolicy\" field in the webhook configuration type.")
@@ -377,7 +377,7 @@ public AdmissionRequest subResource(String subResource) {
377377
*
378378
* @return subResource
379379
*/
380-
@javax.annotation.Nullable
380+
@jakarta.annotation.Nullable
381381
@ApiModelProperty(
382382
value =
383383
"SubResource is the subresource being requested, if any (for example, \"status\" or \"scale\")")

client-java-contrib/admissionreview/src/main/java/io/kubernetes/client/admissionreview/models/AdmissionResponse.java

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@
2424

2525
/** AdmissionResponse describes an admission response. */
2626
@ApiModel(description = "AdmissionResponse describes an admission response.")
27-
@javax.annotation.Generated(
27+
@jakarta.annotation.Generated(
2828
value = "org.openapitools.codegen.languages.JavaClientCodegen",
2929
date = "2021-07-01T14:30:02.888Z[Etc/UTC]")
3030
public class AdmissionResponse {
@@ -108,7 +108,7 @@ public AdmissionResponse putAuditAnnotationsItem(String key, String auditAnnotat
108108
*
109109
* @return auditAnnotations
110110
*/
111-
@javax.annotation.Nullable
111+
@jakarta.annotation.Nullable
112112
@ApiModelProperty(
113113
value =
114114
"AuditAnnotations is an unstructured key value map set by remote admission controller (e.g. error=image-blacklisted). MutatingAdmissionWebhook and ValidatingAdmissionWebhook admission controller will prefix the keys with admission webhook name (e.g. imagepolicy.example.com/error=image-blacklisted). AuditAnnotations will be provided by the admission webhook to add additional context to the audit log for this request.")
@@ -131,7 +131,7 @@ public AdmissionResponse patch(byte[] patch) {
131131
*
132132
* @return patch
133133
*/
134-
@javax.annotation.Nullable
134+
@jakarta.annotation.Nullable
135135
@ApiModelProperty(
136136
value = "The patch body. Currently we only support \"JSONPatch\" which implements RFC 6902.")
137137
public byte[] getPatch() {
@@ -153,7 +153,7 @@ public AdmissionResponse patchType(String patchType) {
153153
*
154154
* @return patchType
155155
*/
156-
@javax.annotation.Nullable
156+
@jakarta.annotation.Nullable
157157
@ApiModelProperty(value = "The type of Patch. Currently we only allow \"JSONPatch\".")
158158
public String getPatchType() {
159159
return patchType;
@@ -174,7 +174,7 @@ public AdmissionResponse status(Status status) {
174174
*
175175
* @return status
176176
*/
177-
@javax.annotation.Nullable
177+
@jakarta.annotation.Nullable
178178
@ApiModelProperty(value = "")
179179
public Status getStatus() {
180180
return status;
@@ -230,7 +230,7 @@ public AdmissionResponse addWarningsItem(String warningsItem) {
230230
*
231231
* @return warnings
232232
*/
233-
@javax.annotation.Nullable
233+
@jakarta.annotation.Nullable
234234
@ApiModelProperty(
235235
value =
236236
"warnings is a list of warning messages to return to the requesting API client. Warning messages describe a problem the client making the API request should correct or be aware of. Limit warnings to 120 characters if possible. Warnings over 256 characters and large numbers of warnings may be truncated.")

client-java-contrib/admissionreview/src/main/java/io/kubernetes/client/admissionreview/models/AdmissionReview.java

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919

2020
/** AdmissionReview describes an admission review request/response. */
2121
@ApiModel(description = "AdmissionReview describes an admission review request/response.")
22-
@javax.annotation.Generated(
22+
@jakarta.annotation.Generated(
2323
value = "org.openapitools.codegen.languages.JavaClientCodegen",
2424
date = "2021-07-01T14:30:02.888Z[Etc/UTC]")
2525
public class AdmissionReview {
@@ -57,7 +57,7 @@ public AdmissionReview apiVersion(String apiVersion) {
5757
*
5858
* @return apiVersion
5959
*/
60-
@javax.annotation.Nullable
60+
@jakarta.annotation.Nullable
6161
@ApiModelProperty(
6262
value =
6363
"APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources")
@@ -83,7 +83,7 @@ public AdmissionReview kind(String kind) {
8383
*
8484
* @return kind
8585
*/
86-
@javax.annotation.Nullable
86+
@jakarta.annotation.Nullable
8787
@ApiModelProperty(
8888
value =
8989
"Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds")
@@ -106,7 +106,7 @@ public AdmissionReview request(AdmissionRequest request) {
106106
*
107107
* @return request
108108
*/
109-
@javax.annotation.Nullable
109+
@jakarta.annotation.Nullable
110110
@ApiModelProperty(value = "")
111111
public AdmissionRequest getRequest() {
112112
return request;
@@ -127,7 +127,7 @@ public AdmissionReview response(AdmissionResponse response) {
127127
*
128128
* @return response
129129
*/
130-
@javax.annotation.Nullable
130+
@jakarta.annotation.Nullable
131131
@ApiModelProperty(value = "")
132132
public AdmissionResponse getResponse() {
133133
return response;

client-java-contrib/admissionreview/src/main/java/io/kubernetes/client/admissionreview/models/GroupVersionKind.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@
2424
@ApiModel(
2525
description =
2626
"GroupVersionKind unambiguously identifies a kind. It doesn't anonymously include GroupVersion to avoid automatic coersion. It doesn't use a GroupVersion to avoid custom marshalling")
27-
@javax.annotation.Generated(
27+
@jakarta.annotation.Generated(
2828
value = "org.openapitools.codegen.languages.JavaClientCodegen",
2929
date = "2021-07-01T14:30:02.888Z[Etc/UTC]")
3030
public class GroupVersionKind {

client-java-contrib/admissionreview/src/main/java/io/kubernetes/client/admissionreview/models/GroupVersionResource.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@
2525
@ApiModel(
2626
description =
2727
"GroupVersionResource unambiguously identifies a resource. It doesn't anonymously include GroupVersion to avoid automatic coersion. It doesn't use a GroupVersion to avoid custom marshalling")
28-
@javax.annotation.Generated(
28+
@jakarta.annotation.Generated(
2929
value = "org.openapitools.codegen.languages.JavaClientCodegen",
3030
date = "2021-07-01T14:30:02.888Z[Etc/UTC]")
3131
public class GroupVersionResource {

client-java-contrib/admissionreview/src/main/java/io/kubernetes/client/admissionreview/models/ListMeta.java

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@
2424
@ApiModel(
2525
description =
2626
"ListMeta describes metadata that synthetic resources must have, including lists and various status objects. A resource may have only one of {ObjectMeta, ListMeta}.")
27-
@javax.annotation.Generated(
27+
@jakarta.annotation.Generated(
2828
value = "org.openapitools.codegen.languages.JavaClientCodegen",
2929
date = "2021-07-01T14:30:02.888Z[Etc/UTC]")
3030
public class ListMeta {
@@ -65,7 +65,7 @@ public ListMeta _continue(String _continue) {
6565
*
6666
* @return _continue
6767
*/
68-
@javax.annotation.Nullable
68+
@jakarta.annotation.Nullable
6969
@ApiModelProperty(
7070
value =
7171
"continue may be set if the user set a limit on the number of items returned, and indicates that the server has more data available. The value is opaque and may be used to issue another request to the endpoint that served this list to retrieve the next set of available objects. Continuing a consistent list may not be possible if the server configuration has changed or more than a few minutes have passed. The resourceVersion field returned when using this continue value will be identical to the value in the first response, unless you have received this token from an error message.")
@@ -95,7 +95,7 @@ public ListMeta remainingItemCount(Long remainingItemCount) {
9595
*
9696
* @return remainingItemCount
9797
*/
98-
@javax.annotation.Nullable
98+
@jakarta.annotation.Nullable
9999
@ApiModelProperty(
100100
value =
101101
"remainingItemCount is the number of subsequent items in the list which are not included in this list response. If the list request contained label or field selectors, then the number of remaining items is unknown and the field will be left unset and omitted during serialization. If the list is complete (either because it is not chunking or because this is the last chunk), then there are no more remaining items and this field will be left unset and omitted during serialization. Servers older than v1.15 do not set this field. The intended use of the remainingItemCount is *estimating* the size of a collection. Clients should not rely on the remainingItemCount to be set or to be exact.")
@@ -121,7 +121,7 @@ public ListMeta resourceVersion(String resourceVersion) {
121121
*
122122
* @return resourceVersion
123123
*/
124-
@javax.annotation.Nullable
124+
@jakarta.annotation.Nullable
125125
@ApiModelProperty(
126126
value =
127127
"String that identifies the server's internal version of this object that can be used by clients to determine when objects have changed. Value must be treated as opaque by clients and passed unmodified back to the server. Populated by the system. Read-only. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#concurrency-control-and-consistency")
@@ -146,7 +146,7 @@ public ListMeta selfLink(String selfLink) {
146146
*
147147
* @return selfLink
148148
*/
149-
@javax.annotation.Nullable
149+
@jakarta.annotation.Nullable
150150
@ApiModelProperty(
151151
value =
152152
"selfLink is a URL representing this object. Populated by the system. Read-only. DEPRECATED Kubernetes will stop propagating this field in 1.20 release and the field is planned to be removed in 1.21 release.")

client-java-contrib/admissionreview/src/main/java/io/kubernetes/client/admissionreview/models/Status.java

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919

2020
/** Status is a return value for calls that don&#39;t return other objects. */
2121
@ApiModel(description = "Status is a return value for calls that don't return other objects.")
22-
@javax.annotation.Generated(
22+
@jakarta.annotation.Generated(
2323
value = "org.openapitools.codegen.languages.JavaClientCodegen",
2424
date = "2021-07-01T14:30:02.888Z[Etc/UTC]")
2525
public class Status {
@@ -77,7 +77,7 @@ public Status apiVersion(String apiVersion) {
7777
*
7878
* @return apiVersion
7979
*/
80-
@javax.annotation.Nullable
80+
@jakarta.annotation.Nullable
8181
@ApiModelProperty(
8282
value =
8383
"APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources")
@@ -100,7 +100,7 @@ public Status code(Integer code) {
100100
*
101101
* @return code
102102
*/
103-
@javax.annotation.Nullable
103+
@jakarta.annotation.Nullable
104104
@ApiModelProperty(value = "Suggested HTTP return code for this status, 0 if not set.")
105105
public Integer getCode() {
106106
return code;
@@ -121,7 +121,7 @@ public Status details(StatusDetails details) {
121121
*
122122
* @return details
123123
*/
124-
@javax.annotation.Nullable
124+
@jakarta.annotation.Nullable
125125
@ApiModelProperty(value = "")
126126
public StatusDetails getDetails() {
127127
return details;
@@ -145,7 +145,7 @@ public Status kind(String kind) {
145145
*
146146
* @return kind
147147
*/
148-
@javax.annotation.Nullable
148+
@jakarta.annotation.Nullable
149149
@ApiModelProperty(
150150
value =
151151
"Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds")
@@ -168,7 +168,7 @@ public Status message(String message) {
168168
*
169169
* @return message
170170
*/
171-
@javax.annotation.Nullable
171+
@jakarta.annotation.Nullable
172172
@ApiModelProperty(value = "A human-readable description of the status of this operation.")
173173
public String getMessage() {
174174
return message;
@@ -189,7 +189,7 @@ public Status metadata(ListMeta metadata) {
189189
*
190190
* @return metadata
191191
*/
192-
@javax.annotation.Nullable
192+
@jakarta.annotation.Nullable
193193
@ApiModelProperty(value = "")
194194
public ListMeta getMetadata() {
195195
return metadata;
@@ -212,7 +212,7 @@ public Status reason(String reason) {
212212
*
213213
* @return reason
214214
*/
215-
@javax.annotation.Nullable
215+
@jakarta.annotation.Nullable
216216
@ApiModelProperty(
217217
value =
218218
"A machine-readable description of why this operation is in the \"Failure\" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it.")
@@ -236,7 +236,7 @@ public Status status(String status) {
236236
*
237237
* @return status
238238
*/
239-
@javax.annotation.Nullable
239+
@jakarta.annotation.Nullable
240240
@ApiModelProperty(
241241
value =
242242
"Status of the operation. One of: \"Success\" or \"Failure\". More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status")

client-java-contrib/admissionreview/src/main/java/io/kubernetes/client/admissionreview/models/StatusCause.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@
2424
@ApiModel(
2525
description =
2626
"StatusCause provides more information about an api.Status failure, including cases when multiple errors are encountered.")
27-
@javax.annotation.Generated(
27+
@jakarta.annotation.Generated(
2828
value = "org.openapitools.codegen.languages.JavaClientCodegen",
2929
date = "2021-07-01T14:30:02.888Z[Etc/UTC]")
3030
public class StatusCause {
@@ -59,7 +59,7 @@ public StatusCause field(String field) {
5959
*
6060
* @return field
6161
*/
62-
@javax.annotation.Nullable
62+
@jakarta.annotation.Nullable
6363
@ApiModelProperty(
6464
value =
6565
"The field of the resource that has caused this error, as named by its JSON serialization. May include dot and postfix notation for nested attributes. Arrays are zero-indexed. Fields may appear more than once in an array of causes due to fields having multiple errors. Optional. Examples: \"name\" - the field \"name\" on the current resource \"items[0].name\" - the field \"name\" on the first array entry in \"items\"")
@@ -83,7 +83,7 @@ public StatusCause message(String message) {
8383
*
8484
* @return message
8585
*/
86-
@javax.annotation.Nullable
86+
@jakarta.annotation.Nullable
8787
@ApiModelProperty(
8888
value =
8989
"A human-readable description of the cause of the error. This field may be presented as-is to a reader.")
@@ -107,7 +107,7 @@ public StatusCause reason(String reason) {
107107
*
108108
* @return reason
109109
*/
110-
@javax.annotation.Nullable
110+
@jakarta.annotation.Nullable
111111
@ApiModelProperty(
112112
value =
113113
"A machine-readable description of the cause of the error. If this value is empty there is no information available.")

0 commit comments

Comments
 (0)