Skip to content

Stop defaulting version ID on control plane creation.#4217

Closed
deads2k wants to merge 3 commits intomainfrom
no-default
Closed

Stop defaulting version ID on control plane creation.#4217
deads2k wants to merge 3 commits intomainfrom
no-default

Conversation

@deads2k
Copy link
Collaborator

@deads2k deads2k commented Feb 25, 2026

We have previously confirmed our desire to eliminate defaulting. It's time. This will probably break some e2es that we will find and fix, but pain to day is better than mistakes tomorrow. We'll finish filling in reality from cluster-service later.

We have previously confirmed our desire to eliminate defaulting. It's
time.  This will probably break some e2es that we will find and fix, but
pain to day is better than mistakes tomorrow.  We'll finish filling in
reality from cluster-service later.
@openshift-ci openshift-ci bot requested review from geoberle and mbarnes February 25, 2026 23:00
@openshift-ci
Copy link

openshift-ci bot commented Feb 25, 2026

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: deads2k

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

// Version should be immutable once is created
// additional validations may depend on the subscription, hence they will be done in the admission package
// ID string `json:"id,omitempty"
errs = append(errs, validate.ImmutableByCompare(ctx, op, fldPath.Child("id"), &newObj.ID, safe.Field(oldObj, toVersionID))...)
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Place behind AFEC until testing done? I'm open to it.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

/hold

this at least needs logic to prevent moving backwards.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

fixed

/hold cancel

}

// ChannelGroup string `json:"channelGroup,omitempty"`
errs = append(errs, validate.ImmutableByCompare(ctx, op, fldPath.Child("channelGroup"), &newObj.ChannelGroup, safe.Field(oldObj, toChannelGroup))...)
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

we allow this in our controller logic and should allow it in general.


// Version ID is required for non-stable channel groups
if newObj.ChannelGroup != "stable" {
errs = append(errs, validate.RequiredValue(ctx, op, fldPath.Child("id"), &newObj.ID, nil)...)
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

now always required.

@deads2k deads2k changed the title Sto defaulting version ID on control plane creation. Stop defaulting version ID on control plane creation. Feb 25, 2026
@deads2k
Copy link
Collaborator Author

deads2k commented Feb 26, 2026

/hold

thinking this through, when we allow version.ID to change we need to ensure it doesn't move past the most recent 4.y+1. I'm going to make it immutable again after the AFEC PR so we can test #4218

@openshift-ci
Copy link

openshift-ci bot commented Feb 26, 2026

@deads2k: The following tests failed, say /retest to rerun all failed tests or /retest-required to rerun all mandatory failed tests:

Test name Commit Details Required Rerun command
ci/prow/test-unit 9cc1144 link true /test test-unit
ci/prow/e2e-parallel 9cc1144 link true /test e2e-parallel

Full PR test history. Your PR dashboard.

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. I understand the commands that are listed here.

@deads2k
Copy link
Collaborator Author

deads2k commented Feb 26, 2026

replaced by #4218

@deads2k deads2k closed this Feb 26, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants