Skip to content

Conversation

@mimowo
Copy link
Contributor

@mimowo mimowo commented Oct 17, 2025

What type of PR is this?

/kind api-change

What this PR does / why we need it:

Which issue(s) this PR fixes:

Part of #7113

Special notes for your reviewer:

For now there is no difference between v1beta1 and v1beta2.

I plan to update the API and add conversion webhooks in follow ups PRs for the ease of reviewing, and working on the changes.

I created the copy with the following commands (note that storageversion marked is removed):

mkdir -p apis/kueue/v1beta2 && cp apis/kueue/v1beta1/* apis/kueue/v1beta2
grep -Rl 'package v1beta' apis/kueue/v1beta2 | xargs sed -i 's/v1beta1/v1beta2/g'
find "apis/kueue/v1beta2" -type f -exec sed -i '/\/\/ +kubebuilder:storageversion/d' {} +
make generate-code
make manifests 
make update-helm

Also:

  • registered v1beta2 in the main.go
  • added a sanity e2e test using v1beta2

Does this PR introduce a user-facing change?

v1beta2: Expose the v1beta2 API for CRD serving. 

V1beta1 remains supported in this release and used as storage, but please plan for migration.

ACTION REQUIRED:
We would highly recommend preparing the Kueue CustomResources API version upgrade (v1beta1 -> v1beta2)
since we plan to use v1beta2 for storage in 0.16, and discontinue the support for v1beta1 in 0.17.

@k8s-ci-robot k8s-ci-robot added release-note Denotes a PR that will be considered when it comes time to generate release notes. do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. kind/api-change Categorizes issue or PR as related to adding, removing, or otherwise changing an API cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. labels Oct 17, 2025
@k8s-ci-robot k8s-ci-robot added approved Indicates a PR has been approved by an approver from all required OWNERS files. size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. labels Oct 17, 2025
@netlify
Copy link

netlify bot commented Oct 17, 2025

Deploy Preview for kubernetes-sigs-kueue canceled.

Name Link
🔨 Latest commit 842a15e
🔍 Latest deploy log https://app.netlify.com/projects/kubernetes-sigs-kueue/deploys/68f1fdf875021e0008db0d76

@mimowo
Copy link
Contributor Author

mimowo commented Oct 17, 2025

/retest

@mimowo mimowo force-pushed the v1beta2-crds-with-e2e-test branch from 8c068ff to 9fe179c Compare October 17, 2025 08:02
@mimowo mimowo force-pushed the v1beta2-crds-with-e2e-test branch from 9fe179c to 842a15e Compare October 17, 2025 08:27
@mimowo mimowo changed the title WIP: Copy v1beta1 as v1beta2 Copy v1beta1 as v1beta2 Oct 17, 2025
@k8s-ci-robot k8s-ci-robot removed the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Oct 17, 2025
@mimowo
Copy link
Contributor Author

mimowo commented Oct 17, 2025

This is ready to review. PTAL @tenzen-y
cc @PBundyra

Copy link
Member

Choose a reason for hiding this comment

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

Shouldn't we put this on pkg/util/testing/wrappers.go, then use this wrapper everwhere?
And we can add v1beta1 dedicated tests to verify the coversion webhooks behavior.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I thought we discussed this on the previous PR that we split in the transition period Kueue specific wrappers for v1beta1 and v1beta2?

We don't have conversion webhooks yet. I will add them in the following PRs, but this is the only way I can see for me to make the PRs reviewable.

Copy link
Member

Choose a reason for hiding this comment

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

I indicated having API version-specific wrappers only for v1beta1. Then, all current wrapper usages are replaced with v1beta2.

Additionally, we have conversion check tests, while we keep supporting both API versions.

We don't have conversion webhooks yet. I will add them in the following PRs, but this is the only way I can see for me to make the PRs reviewable.

Do you say that using v1beta2 API everwhere requires conversion webhooks? I thouhght that we do not need that.
Could you share the conversion webhook direction?

My thought is the conversion webhook converts v1beta1 API to v1beta2. Is this correct?

Copy link
Contributor Author

@mimowo mimowo Oct 17, 2025

Choose a reason for hiding this comment

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

I indicated having API version-specific wrappers only for v1beta1. Then, all current wrapper usages are replaced with v1beta2.

Sure, but this PR is not replacing yet fully with v1beta2, we are not ready for that. I listed in the other comment the plan #7304 (comment). This PR is already 165 files or so, so I prefer to move gradually. Also, I want to apply the changes to the API on top of this API, then we will see the diff nicely.

If I tried to apply v1beta2 changes to this PR it will all get scrumbled, so for now this is just a copy.

Do you say that using v1beta2 API everwhere requires conversion webhooks? I thouhght that we do not need that.
Could you share the conversion webhook direction?

IIUC we need conversion only for LocalQueue, ClusterQueue and Workload.

My thought is the conversion webhook converts v1beta1 API to v1beta2. Is this correct?

Yes, they will work both ways actually.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

(because this is just a copy for now then conversion webhooks aren't introduced in this PR yet)

Copy link
Member

Choose a reason for hiding this comment

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

IIUC we need conversion only for LocalQueue, ClusterQueue and Workload.

Ah, I see. In that case, we need to work on some more efforts, then it sould be done in another follow-up PR.
I'm fine with this PR.
Thank you.

/lgtm
/approve

Copy link
Member

Choose a reason for hiding this comment

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

As I mentioned in another thread, instead of specializing v1beta2, we should specialize v1beta1.
So, this should be for v1beta1, test/e2e/singlecluster/e2e_v1beta1_test.go

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I want to do that in follow up PRs when we conclude the transition. This PR isn't changing the logic, it is still using v1beta1, and is already massive in size.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

So, this should be for v1beta1, test/e2e/singlecluster/e2e_v1beta1_test.go

Yes, this is my end goal after a couple more PRs planned for next week:

  • conversion webhooks
  • API changes
  • migration of tests and logic
  • clearing up on transition period wrappers, and keeping only a small subset of them for e2e_v1beta1_test.go

Copy link
Member

Choose a reason for hiding this comment

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

Alright, SGTM

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Oct 17, 2025
@k8s-ci-robot
Copy link
Contributor

LGTM label has been added.

Git tree hash: 7e8e74475d9450b8785929ec6dea6c124f5d8db2

@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: mimowo, tenzen-y

The full list of commands accepted by this bot can be found here.

The pull request process is described here

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

@k8s-ci-robot k8s-ci-robot merged commit d6b73af into kubernetes-sigs:main Oct 17, 2025
23 checks passed
@k8s-ci-robot k8s-ci-robot added this to the v0.15 milestone Oct 17, 2025
@mimowo
Copy link
Contributor Author

mimowo commented Nov 28, 2025

/release-note-edit

v1beta2: Expose the v1beta2 API for CRD serving. V1beta1 remains as storage.

@mimowo
Copy link
Contributor Author

mimowo commented Nov 28, 2025

/release-note-edit

v1beta2: Expose the v1beta2 API for CRD serving. V1beta1 remains supported in this release and used as storage, but
please plan for migration.

@mimowo
Copy link
Contributor Author

mimowo commented Nov 28, 2025

/release-note-edit

NONE

@tenzen-y
Copy link
Member

/release-note-edit

v1beta2: Expose the v1beta2 API for CRD serving. 

V1beta1 remains supported in this release and used as storage, but please plan for migration.

ACTION REQUIRED:
We would highly recommend preparing the Kueue CustomResources API version upgrade (v1beta1 -> v1beta2)
since we plan to use v1beta2 for storage in 0.16, and discontinue the support for v1beta1 in 0.17.

@k8s-ci-robot k8s-ci-robot added the release-note-action-required Denotes a PR that introduces potentially breaking changes that require user action. label Nov 28, 2025
@k8s-ci-robot k8s-ci-robot removed the release-note Denotes a PR that will be considered when it comes time to generate release notes. label Nov 28, 2025
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. kind/api-change Categorizes issue or PR as related to adding, removing, or otherwise changing an API lgtm "Looks good to me", indicates that a PR is ready to be merged. release-note-action-required Denotes a PR that introduces potentially breaking changes that require user action. 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.

3 participants