Commit Graph

231 Commits

Author SHA1 Message Date
Jefftree
8a2bbd0393 Coordinated Leader Election Alpha API
Kubernetes-commit: 3999b98c8840e41acaa19d94e88f46d1fbb0c1b3
2024-07-21 20:02:00 +00:00
carlory
9dea255e12 Promote VolumeAttributesClass to beta
Kubernetes-commit: 0260c7d023551f85621049ca604a4fd5110ba0a9
2024-07-17 15:55:06 +08:00
Patrick Ohly
a7db3ade62 DRA: new API for 1.31
This is a complete revamp of the original API. Some of the key
differences:
- refocused on structured parameters and allocating devices
- support for constraints across devices
- support for allocating "all" or a fixed amount
  of similar devices in a single request
- no class for ResourceClaims, instead individual
  device requests are associated with a mandatory
  DeviceClass

For the sake of simplicity, optional basic types (ints, strings) where the null
value is the default are represented as values in the API types. This makes Go
code simpler because it doesn't have to check for nil (consumers) and values
can be set directly (producers). The effect is that in protobuf, these fields
always get encoded because `opt` only has an effect for pointers.

The roundtrip test data for v1.29.0 and v1.30.0 changes because of the new
"request" field. This is considered acceptable because the entire `claims`
field in the pod spec is still alpha.

The implementation is complete enough to bring up the apiserver.
Adapting other components follows.

Kubernetes-commit: 91d7882e867da25ae8014f679db32b20e35e89b4
2024-06-18 17:47:29 +02:00
Patrick Ohly
91ff2f6ea5 DRA: bump API v1alpha2 -> v1alpha3
This is in preparation for revamping the resource.k8s.io completely. Because
there will be no support for transitioning from v1alpha2 to v1alpha3, the
roundtrip test data for that API in 1.29 and 1.30 gets removed.

Repeating the version in the import name of the API packages is not really
required. It was done for a while to support simpler grepping for usage of
alpha APIs, but there are better ways for that now. So during this transition,
"resourceapi" gets used instead of "resourcev1alpha3" and the version gets
dropped from informer and lister imports. The advantage is that the next bump
to v1beta1 will affect fewer source code lines.

Only source code where the version really matters (like API registration)
retains the versioned import.

Kubernetes-commit: b51d68bb87ba4fa47eb760f8a5e0baf9cf7f5b53
2024-06-14 12:40:48 +02:00
Amir Alavi
eab51c4031 fix: fake clientset ApplyScale subresource from 'status' to 'scale'
Signed-off-by: Amir Alavi <amiralavi7@gmail.com>

Kubernetes-commit: 872c3442501ca479f399d2f9060b72d228234b30
2024-07-13 12:23:02 -04:00
Antonio Ojea
a146a0f353 make update
Kubernetes-commit: bc8bce2ef98b85d642c7e805e8c6d1fd92cbcf53
2024-05-21 11:58:12 +00:00
Joe Betz
c4145a9c20 Generate code
Kubernetes-commit: 7772769d19a82a26aa91181e0804ff2ccbdd843c
2024-06-24 15:58:35 -04:00
Stephen Kitt
b31bc29ea1 Run codegen
Signed-off-by: Stephen Kitt <skitt@redhat.com>

Kubernetes-commit: 08dfd59305dbd1032b1afb49738259d688dda5e3
2024-05-10 16:56:52 +02:00
Stephen Kitt
c834bcc257 Generify client-go
This adds a generic implementation of a clientset, and uses it to
replace the template code in generated clientsets for the default
methods. The templates are preserved as-is (or as close as they can
be) for use in extensions, whether for resources or subresources.

Clientsets with no extensions are reduced to their main getter, their
interface, their specific struct, and their constructor. All method
implementations are provided by the generic implementation. The
dedicated interface is preserved so that each clientset can have its
own set of methods, and the dedicated struct is preserved to allow
extensions and expansions to be defined where necessary.

Instead of handling the variants (with/without namespace, list, apply)
with a complex sequence of if statements, build up an index into an
array containing the various declarations.

The namespaced/non-namespaced distinction matters in the code
templates, but not in the methods themselves, so drop all the
non-namespaced variants and pass in "" explicitly.

Signed-off-by: Stephen Kitt <skitt@redhat.com>

Kubernetes-commit: 3734f5bf9b6ce1e9cf2385f4e4453b32d8f35ab1
2023-10-13 09:56:04 +02:00
Lukasz Szaszkiewicz
cc198ea39d make update
Kubernetes-commit: f62c80f965934eeeb2e028497bede7bcc632995d
2024-06-13 10:25:56 +02:00
Lukasz Szaszkiewicz
9f33e96b6a make update
Kubernetes-commit: 448180db60fc1d62174a18d1dd995d8deb081428
2024-05-27 15:31:15 +02:00
Dan Winship
3d4f98db0e Regenerate fake clients
Kubernetes-commit: 17ab25b121d05355700f39628d5d45ab3da446f8
2024-01-20 10:20:43 -05:00
Nilekh Chaudhari
b0efa42e52 feat: implements Storage Version Migration API in-tree
Signed-off-by: Nilekh Chaudhari <1626598+nilekhc@users.noreply.github.com>

Kubernetes-commit: 91a7708cdcea8cdb1d7db2cc8a27c57741e0cddc
2023-10-10 20:23:08 +00:00
Patrick Ohly
fee411cff2 dra api: rename NodeResourceSlice -> ResourceSlice
While currently those objects only get published by the kubelet for node-local
resources, this could change once we also support network-attached
resources. Dropping the "Node" prefix enables such a future extension.

The NodeName in ResourceSlice and StructuredResourceHandle then becomes
optional. The kubelet still needs to provide one and it must match its own node
name, otherwise it doesn't have permission to access ResourceSlice objects.

Kubernetes-commit: 0b6a0d686a060b5d5ff92cea931aacd4eba85adb
2024-03-07 10:14:11 +01:00
Patrick Ohly
c3231901f2 dra api: add structured parameters
NodeResourceSlice will be used by kubelet to publish resource information on
behalf of DRA drivers on the node. NodeName and DriverName in
NodeResourceSlice must be immutable. This simplifies tracking the different
objects because what they are for cannot change after creation.

The new field in ResourceClass tells scheduler and autoscaler that they are
expected to handle allocation.

ResourceClaimParameters and ResourceClassParameters are new types for telling
in-tree components how to handle claims.

Kubernetes-commit: 39bbcedbcae84bf716923b3f9464968ca70b42e7
2024-02-14 14:38:42 +01:00
cici37
4ceeb096c4 Auto updates
Kubernetes-commit: 5d83282823d5ee728d610befb389e3732b4503c3
2024-02-01 01:00:24 +00:00
José Carlos Chávez
76174b8af8 chore: adds consistent vanity import to files and provides tooling for verifying and updating them. (#120642)
* chore: drops update vanity imports from script.

* chore: changes copyright year to 2024.

* chore: makes lint happy.

Kubernetes-commit: 6d6398ef9266abce3518a4c9a3d4e4d8feeffdc1
2024-02-08 13:38:07 +00:00
Antonio Ojea
824910b3a9 make update
Change-Id: I4007d4f6dda24b5c74f602d35191556f315de222

Kubernetes-commit: 8182c4d9ec8c254d7291f7b451bfe47aadc1c691
2023-10-18 00:37:58 +00:00
carlory
6278c99b77 generated changes
Kubernetes-commit: 56ab6c5942171cd1e598fc7c25a21f5aa457f36f
2023-10-31 10:13:04 +08:00
Abu Kashem
20fd67fa15 apiserver: generate code for apf flowcontrol v1 API
run:
- hack/update-codegen.sh
- hack/update-openapi-spec.sh

Kubernetes-commit: 5972037ffd6c1aea0f1c99ed430d1d78204a48a0
2023-10-10 13:49:38 -04:00
Antonio Ojea
656ec39ea1 remove ClusterCIDR
KEP-2593 proposed to expand the existing node-ipam controller
to be configurable via a ClusterCIDR objects, however, there
were reasonable doubts on the SIG about the feature and after
several months of dicussions we decided to not move forward
with the KEP intree, hence, we are going to remove the existing
code, that is still in alpha.

https://groups.google.com/g/kubernetes-sig-network/c/nts1xEZ--gQ/m/2aTOUNFFAAAJ

Change-Id: Ieaf2007b0b23c296cde333247bfb672441fe6dfc

Kubernetes-commit: c2d473f0d438cedab2f1831d23457d24961e0f4e
2023-10-13 21:31:29 +00:00
SataQiu
def2075eac apf: remove v1alpha1 API
Kubernetes-commit: 2825519da2c176ac81d2ec6b1500ef8e68377db1
2023-08-30 17:20:29 +08:00
Monis Khan
1e11b3a8ca Delete PSP API types and generated clients
Signed-off-by: Monis Khan <mok@microsoft.com>

Kubernetes-commit: 10fe3da87dbc354ea528d65f1e544614ee980987
2023-08-07 16:15:13 -04:00
Alexander Zielenski
d7acd85d1b update codegen
Kubernetes-commit: d6479587445a5a6fa736ee7fb3012a29f4e6e5e7
2023-07-19 16:21:22 -07:00
m.nabokikh
8009187f26 KEP-3325: Promote SelfSubjectReview to GA
Signed-off-by: m.nabokikh <maksim.nabokikh@flant.com>

Kubernetes-commit: 40de26dcff80f29380a4ba90a93ce3ece7482b78
2023-05-02 01:26:20 +02:00
Ricardo Katz
224050a5b5 Generated files for NetworkPolicyStatus removal
Kubernetes-commit: ec997d5433afc09e79376e35936a027dc2ba8713
2023-02-16 14:31:49 -03:00
Taahir Ahmed
4c5879adb0 ClusterTrustBundles: make update
Kubernetes-commit: 2e4b637bf8f304c5264b93cced659c2bcbb66733
2022-11-07 11:45:53 -08:00
Antonio Ojea
568393e257 make update
Change-Id: I19e12ca05d977dca63043cb07ecf8a90e0e525c5

Kubernetes-commit: ba42ed9a49345f8a182829e72c7013ea3ff0d224
2023-03-12 13:50:02 +00:00
Patrick Ohly
76262aa83e api: generated files for PodSchedulingContext
Kubernetes-commit: 2b8a4e809710f1b5eb3846a2964431a0266f287e
2023-03-13 23:16:18 +01:00
Patrick Ohly
324f43b974 api: resource.k8s.io v1alpha1 -> v1alpha2
For Kubernetes 1.27, we intend to make some breaking API changes:
- rename PodScheduling -> PodSchedulingHints (https://github.com/kubernetes/kubernetes/issues/114283)
- extend ResourceClaimStatus (https://github.com/kubernetes/enhancements/pull/3802)

We need to switch from v1alpha1 to v1alpha2 for that.

Kubernetes-commit: 29941b8d3e7928244f48b05bf5bd453221fe7a9d
2023-03-06 12:43:58 +01:00
Jiahui Feng
8dcee0c630 generated: ./hack/update-codegen.sh && ./hack/update-openapi-spec.sh
Kubernetes-commit: deb467261ca23ca5decfdb6b67bef3591d4cb842
2023-03-13 19:44:28 -07:00
Maksim Nabokikh
64e2c7ff16 KEP-3325: Promote SelfSubjectReview to Beta (#116274)
* Promote SelfSubjectReview to Beta

Signed-off-by: m.nabokikh <maksim.nabokikh@flant.com>

* Fix whoami API

Signed-off-by: m.nabokikh <maksim.nabokikh@flant.com>

* Fixes according to code review

Signed-off-by: m.nabokikh <maksim.nabokikh@flant.com>

---------

Signed-off-by: m.nabokikh <maksim.nabokikh@flant.com>

Kubernetes-commit: c1431af4f83b2b06a581f23806ee12a0663fed3b
2023-03-09 03:35:44 +00:00
Tim Hockin
1d637ff29e Don't generate clientset/doc.go in client-gen
It seems valuable to be able to provide hand-written docs for these
first-level directories, and if don't want them, the generated doc.go
files are not actually very helpful.

This commit also adds new doc.go files for client-go listers/ and
informers/.

Kubernetes-commit: 95bf7b0afe9dd6a0f00125b1d290514a23e778e2
2023-01-12 09:51:33 -08:00
Paco Xu
be1f5d4ebb client-go: remove extensions psp only
Kubernetes-commit: e41b1bff5853c616f7872ccf36fbefa480f72892
2022-11-03 10:12:16 +08:00
Steve Kuznetsov
9bcbb56a27 code-generator: refer to the API package for GV{R,K}
There should only be one source of truth for the API group's name and
version.

Signed-off-by: Steve Kuznetsov <skuznets@redhat.com>

Kubernetes-commit: e13198ec6f52c4a6405388e90053954dc7656a31
2022-11-06 07:05:42 -07:00
Jordan Liggitt
422fe1f61e Fix indentation/spacing in comments to render correctly in godoc
Kubernetes-commit: 78cb3862f11225135afdf76f3424e2d7b33104c7
2022-12-17 17:31:05 -05:00
Patrick Ohly
522eaa15ef api: generated files
Kubernetes-commit: 9683c60c05491a9e9cafd3419c150caf7355bf49
2022-11-10 20:22:42 +01:00
Cici Huang
3a430a4884 API - make update
API - Auto update

API - make update

API - make update

Kubernetes-commit: 19b2df871560816c3eb29fbb271953afab1e39c8
2022-10-03 17:17:45 +00:00
Abu Kashem
9bac803bd8 apiserver: generate for apf v1beta3
Kubernetes-commit: 6ac0e879790ddaf62942ea101d6edb24b0c57cbd
2022-09-08 10:53:38 -04:00
Steve Kuznetsov
956c1ce5e8 clients: clarify a misleading comment
It's clear that client-sets contain many versions of one group, so this
comment just seems to be out-dated.

Signed-off-by: Steve Kuznetsov <skuznets@redhat.com>

Kubernetes-commit: 588f016c3bc04ea2da85d7077643677028a8cb1b
2022-09-23 12:25:52 -06:00
m.nabokikh
b2b55e607d Add auth API to get self subject attributes
Signed-off-by: m.nabokikh <maksim.nabokikh@flant.com>

Kubernetes-commit: 00dfba473b08528f0a21f7bd3b921f5dd35b013a
2022-07-22 04:01:52 +04:00
inosato
27de641f75 Remove ioutil from client-go
Signed-off-by: inosato <si17_21@yahoo.co.jp>

Kubernetes-commit: 88dfa51b6003c90e8f0a0508939a1d79950a40df
2022-07-30 20:54:41 +09:00
Sarvesh Rangnekar
76884cd2d8 Auto generate code for ClusterCIDR API
Kubernetes-commit: 299724d099f87d66b7a196d5acb545eb4dd78b9a
2022-08-02 02:09:07 +00:00
Davanum Srinivas
2a6c116e40 Generate and format files
- Run hack/update-codegen.sh
- Run hack/update-generated-device-plugin.sh
- Run hack/update-generated-protobuf.sh
- Run hack/update-generated-runtime.sh
- Run hack/update-generated-swagger-docs.sh
- Run hack/update-openapi-spec.sh
- Run hack/update-gofmt.sh

Signed-off-by: Davanum Srinivas <davanum@gmail.com>

Kubernetes-commit: a9593d634c6a053848413e600dadbf974627515f
2022-07-19 20:54:13 -04:00
Harsha Narayana
e2ef40870b GIT-110335: address namespace defaulting for events
Kubernetes-commit: 85e74aa3122114ac7e82c3044f387d03661063e4
2022-06-18 21:52:50 +05:30
LY-today
9ac8bfecbb fix: list pod err after an pod evicted
Signed-off-by: LY-today <724102053@qq.com>

Kubernetes-commit: f299494e7977a935511208eb91001508b4b629ce
2022-06-22 23:30:40 +08:00
James Laverack
f9fdccdfc3 Revert "Introduce APIs to support multiple ClusterCIDRs (#108290)"
This reverts commit b9792a9daef4d978c5c30b6d10cbcdfa77a9b6ac.

Kubernetes-commit: 7d57d5c70d04f652b431d2b86b8af40e119cd66a
2022-04-12 16:00:35 +01:00
Sarvesh Rangnekar
092a109b2b Introduce APIs to support multiple ClusterCIDRs (#108290)
* Introduce networking/v1alpha1 api, ClusterCIDRConfig type

Introduce networking/v1alpha1 api group.

Add `ClusterCIDRConfig` type to networking/v1alpha1 api group, this type
will enable the NodeIPAM controller to support multiple ClusterCIDRs.

* Change ClusterCIDRConfig.NodeSelector type in api

* Fix review comments for API

* Update ClusterCIDRConfig API Spec

Introduce PerNodeHostBits field, remove PerNodeMaskSize

Kubernetes-commit: b9792a9daef4d978c5c30b6d10cbcdfa77a9b6ac
2022-03-31 05:16:43 +00:00
Ricardo Katz
94a1081faf Implementation on Network Policy Status (#107963)
* Implement status subresource in NetworkPolicy

* add NetworkPolicyStatus generated files

* Fix comments in netpol status review

Kubernetes-commit: 42a12010829962c6e87cee8e4bc217d39d7a8043
2022-03-29 09:13:14 +00:00
Patrick Ohly
6ece0de2d5 storage capacity: generated files
Kubernetes-commit: b1aefb9b90094ec4625ef2eefab7185fe4db9368
2022-03-02 07:43:19 +01:00