chore: union kubernetes api definition for v1.36 - #6197
Conversation
|
This PR has multiple commits, and the default merge method is: merge. DetailsInstructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. |
|
Skipping CI for Draft Pull Request. |
5fd8eca to
fda4fb5
Compare
fda4fb5 to
b95ffb2
Compare
Synthesize openapi to integrate multiple kubernetes api definitions. Makes it possible to use a single union definition that combines API definitions that existed up to kubernetes v1.21-v1.36, making it possible to handle APIs that could not be handled correctly until now. Also, this will remove fields that existed in openapi but were not needed for kustomize, reducing the final binary size.
b95ffb2 to
e2e0526
Compare
saitejabandaru-in
left a comment
There was a problem hiding this comment.
LGTM! This is a massive and extremely welcome improvement to how Kustomize handles OpenAPI schemas. The union approach is the perfect solution to preserving backward compatibility for removed APIs while taking advantage of the latest schemas and types from the newest Kubernetes releases. The generator logic and caching mechanism both look very robust.
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: koba1t, saitejabandaru-in The full list of commands accepted by this bot can be found here. The pull request process is described here DetailsNeeds approval from an approver in each of these files:
Approvers can indicate their approval by writing |
Synthesize openapi to integrate multiple kubernetes api definitions. Makes it possible to use a single union definition that combines API definitions that existed up to kubernetes v1.21-v1.36, making it possible to handle APIs that could not be handled correctly until now. Also, this will remove fields that existed in openapi but were not needed for kustomize, reducing the final binary size.
Related to #5016.
Validation
GOWORK=off go test ./...inkyaml/openapiGOWORK=off go test -race ./openapi/...inkyamlapi/krustyOpenAPI and union integration testsgolangci-lintfor the changedkyaml/openapiandapi/krustypackagesAI disclosure: This PR was written in part with the assistance of generative AI.