Skip to content

chore: union kubernetes api definition for v1.36 - #6197

Open
koba1t wants to merge 1 commit into
kubernetes-sigs:masterfrom
koba1t:agent/openapi-union-v1-36
Open

chore: union kubernetes api definition for v1.36#6197
koba1t wants to merge 1 commit into
kubernetes-sigs:masterfrom
koba1t:agent/openapi-union-v1-36

Conversation

@koba1t

@koba1t koba1t commented Jul 23, 2026

Copy link
Copy Markdown
Member

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 ./... in kyaml/openapi
  • GOWORK=off go test -race ./openapi/... in kyaml
  • Targeted api/krusty OpenAPI and union integration tests
  • golangci-lint for the changed kyaml/openapi and api/krusty packages
  • Windows amd64 cross-compilation of the bundle compiler tests
  • Byte-for-byte regeneration checks for the bundle and generated scope index

AI disclosure: This PR was written in part with the assistance of generative AI.

@kubernetes-prow

Copy link
Copy Markdown
Contributor

This PR has multiple commits, and the default merge method is: merge.
You can request commits to be squashed using the label: tide/merge-method-squash

Details

Instructions 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.

@kubernetes-prow

Copy link
Copy Markdown
Contributor

Skipping CI for Draft Pull Request.
If you want CI signal for your change, please convert it to an actual PR.
You can still manually trigger a test run with /test all

@kubernetes-prow kubernetes-prow Bot added do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. labels Jul 23, 2026
@kubernetes-prow kubernetes-prow Bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Jul 23, 2026
@koba1t
koba1t force-pushed the agent/openapi-union-v1-36 branch 2 times, most recently from 5fd8eca to fda4fb5 Compare August 3, 2026 05:30
@koba1t
koba1t marked this pull request as ready for review August 3, 2026 05:30
@kubernetes-prow kubernetes-prow Bot removed the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Aug 3, 2026
@koba1t
koba1t force-pushed the agent/openapi-union-v1-36 branch from fda4fb5 to b95ffb2 Compare August 3, 2026 20:09
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.
@koba1t
koba1t force-pushed the agent/openapi-union-v1-36 branch from b95ffb2 to e2e0526 Compare August 4, 2026 01:54

@saitejabandaru-in saitejabandaru-in left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

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.

@kubernetes-prow

Copy link
Copy Markdown
Contributor

[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

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

approved Indicates a PR has been approved by an approver from all required OWNERS files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants