Skip to content

Conversation

@RadekManak
Copy link
Contributor

@RadekManak RadekManak commented Jan 29, 2026

User description

The feature gate CPMSMachineNamePrefix has been enabled by default since 4.21 or prior. It is no longer needed within the product.

Companion PR that removes the usage of the faeturegate from CPMSO: openshift/cluster-control-plane-machine-set-operator#387


PR Type

Enhancement


Description

  • Remove CPMSMachineNamePrefix feature gate definition

  • Convert machineNamePrefix field to always-enabled ungated feature

  • Update CRD manifests to reflect permanent availability

  • Consolidate validation tests into main test file


Diagram Walkthrough

flowchart LR
  A["CPMSMachineNamePrefix<br/>Feature Gate"] -->|Remove| B["Ungated<br/>machineNamePrefix Field"]
  C["Feature-gated<br/>CRD Manifests"] -->|Consolidate| D["Single Ungated<br/>CRD Manifest"]
  E["Feature Gate<br/>Definitions"] -->|Delete| F["Removed from<br/>All Profiles"]
  B --> G["Always Available<br/>in All Versions"]
Loading

File Walkthrough

Relevant files
Enhancement
2 files
features.go
Remove CPMSMachineNamePrefix feature gate definition         
+0/-8     
types_controlplanemachineset.go
Convert machineNamePrefix to ungated with standard validation
+1/-2     
Documentation
1 files
features.md
Remove CPMSMachineNamePrefix from feature matrix documentation
+0/-1     
Tests
2 files
AAA_ungated.yaml
Add machineNamePrefix validation tests to ungated test file
+106/-0 
CPMSMachineNamePrefix.yaml
Delete feature-gated test file for CPMSMachineNamePrefix 
+0/-162 
Configuration changes
12 files
zz_generated.featuregated-crd-manifests.yaml
Remove CPMSMachineNamePrefix from feature gates list         
+0/-1     
AAA_ungated.yaml
Add machineNamePrefix field to ungated CRD manifest           
+23/-0   
CPMSMachineNamePrefix.yaml
Delete feature-gated CRD manifest file                                     
+0/-952 
MachineAPIMigration.yaml
Add machineNamePrefix field to MachineAPIMigration CRD     
+23/-0   
featureGate-Hypershift-Default.yaml
Remove CPMSMachineNamePrefix from enabled features list   
+0/-3     
featureGate-Hypershift-DevPreviewNoUpgrade.yaml
Remove CPMSMachineNamePrefix from enabled features list   
+0/-3     
featureGate-Hypershift-OKD.yaml
Remove CPMSMachineNamePrefix from enabled features list   
+0/-3     
featureGate-Hypershift-TechPreviewNoUpgrade.yaml
Remove CPMSMachineNamePrefix from enabled features list   
+0/-3     
featureGate-SelfManagedHA-Default.yaml
Remove CPMSMachineNamePrefix from enabled features list   
+0/-3     
featureGate-SelfManagedHA-DevPreviewNoUpgrade.yaml
Remove CPMSMachineNamePrefix from enabled features list   
+0/-3     
featureGate-SelfManagedHA-OKD.yaml
Remove CPMSMachineNamePrefix from enabled features list   
+0/-3     
featureGate-SelfManagedHA-TechPreviewNoUpgrade.yaml
Remove CPMSMachineNamePrefix from enabled features list   
+0/-3     

@openshift-ci-robot openshift-ci-robot added jira/valid-reference Indicates that this PR references a valid Jira ticket of any type. jira/valid-bug Indicates that a referenced Jira bug is valid for the branch this PR is targeting. labels Jan 29, 2026
@openshift-ci-robot
Copy link

@RadekManak: This pull request references Jira Issue OCPBUGS-74512, which is valid.

3 validation(s) were run on this bug
  • bug is open, matching expected state (open)
  • bug target version (4.22.0) matches configured target version for branch (4.22.0)
  • bug is in the state POST, which is one of the valid states (NEW, ASSIGNED, POST)

Requesting review from QA contact:
/cc @huali9

The bug has been updated to refer to the pull request using the external bug tracker.

Details

In response to this:

The feature gate CPMSMachineNamePrefix has been enabled by default since 4.21 or prior. It is no longer needed within the product.

Companion PR that removes the usage of the faeturegate from CPMSO: openshift/cluster-control-plane-machine-set-operator#387

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 openshift-eng/jira-lifecycle-plugin repository.

@openshift-ci
Copy link
Contributor

openshift-ci bot commented Jan 29, 2026

Hello @RadekManak! Some important instructions when contributing to openshift/api:
API design plays an important part in the user experience of OpenShift and as such API PRs are subject to a high level of scrutiny to ensure they follow our best practices. If you haven't already done so, please review the OpenShift API Conventions and ensure that your proposed changes are compliant. Following these conventions will help expedite the api review process for your PR.

@openshift-ci openshift-ci bot requested a review from huali9 January 29, 2026 09:38
@coderabbitai
Copy link

coderabbitai bot commented Jan 29, 2026

📝 Walkthrough

Walkthrough

This pull request removes the CPMSMachineNamePrefix feature gate throughout the codebase. Changes include deleting the feature gate definition from Go source, removing documentation references, and eliminating the feature gate from enabled lists across multiple deployment configuration files for Hypershift and SelfManagedHA profiles. The machineNamePrefix field validation is converted from a feature-gate-aware annotation to a standard kubebuilder XValidation rule, making the field validation permanently available. Test files are reorganized, with the feature-gated test suite removed and new validation tests added to the ungated test configuration.

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly and concisely describes the main change: removing the CPMSMachineNamePrefix feature gate, which is the primary objective across all modified files.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Description check ✅ Passed The pull request description clearly explains the removal of the CPMSMachineNamePrefix feature gate, which has been enabled by default since 4.21, and describes the consolidation of tests and updates to CRD manifests.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing touches
  • 📝 Generate docstrings

Comment @coderabbitai help to get the list of available commands and usage tips.

@qodo-code-review
Copy link

PR Compliance Guide 🔍

Below is a summary of compliance checks for this PR:

Security Compliance
🟢
No security concerns identified No security vulnerabilities detected by AI analysis. Human verification advised for critical code.
Ticket Compliance
🎫 No ticket provided
  • Create ticket/issue
Codebase Duplication Compliance
Codebase context is not defined

Follow the guide to enable codebase context checks.

Custom Compliance
🟢
Generic: Comprehensive Audit Trails

Objective: To create a detailed and reliable record of critical system actions for security analysis
and compliance.

Status: Passed

Learn more about managing compliance generic rules or creating your own custom rules

Generic: Meaningful Naming and Self-Documenting Code

Objective: Ensure all identifiers clearly express their purpose and intent, making code
self-documenting

Status: Passed

Learn more about managing compliance generic rules or creating your own custom rules

Generic: Robust Error Handling and Edge Case Management

Objective: Ensure comprehensive error handling that provides meaningful context and graceful
degradation

Status: Passed

Learn more about managing compliance generic rules or creating your own custom rules

Generic: Secure Error Handling

Objective: To prevent the leakage of sensitive system information through error messages while
providing sufficient detail for internal debugging.

Status: Passed

Learn more about managing compliance generic rules or creating your own custom rules

Generic: Secure Logging Practices

Objective: To ensure logs are useful for debugging and auditing without exposing sensitive
information like PII, PHI, or cardholder data.

Status: Passed

Learn more about managing compliance generic rules or creating your own custom rules

Generic: Security-First Input Validation and Data Handling

Objective: Ensure all data inputs are validated, sanitized, and handled securely to prevent
vulnerabilities

Status: Passed

Learn more about managing compliance generic rules or creating your own custom rules

Compliance status legend 🟢 - Fully Compliant
🟡 - Partial Compliant
🔴 - Not Compliant
⚪ - Requires Further Human Verification
🏷️ - Compliance label

@openshift-ci-robot
Copy link

Pipeline controller notification
This repo is configured to use the pipeline controller. Second-stage tests will be triggered either automatically or after lgtm label is added, depending on the repository configuration. The pipeline controller will automatically detect which contexts are required and will utilize /test Prow commands to trigger the second stage.

For optional jobs, comment /test ? to see a list of all defined jobs. To trigger manually all jobs from second stage use /pipeline required command.

This repository is configured in: LGTM mode

@openshift-ci openshift-ci bot added the size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. label Jan 29, 2026
@openshift-ci openshift-ci bot requested review from everettraven and mandre January 29, 2026 09:39
@qodo-code-review
Copy link

PR Code Suggestions ✨

Explore these optional code suggestions:

CategorySuggestion                                                                                                                                    Impact
General
Use standard format validation marker

Replace the custom CEL XValidation rule for MachineNamePrefix with the standard
+kubebuilder:validation:Format=dns1123Subdomain marker for better compatibility
and clarity.

machine/v1/types_controlplanemachineset.go [56-60]

-	// +kubebuilder:validation:XValidation:rule="!format.dns1123Subdomain().validate(self).hasValue()",message="a lowercase RFC 1123 subdomain must consist of lowercase alphanumeric characters, hyphens ('-'), and periods ('.'). Each block, separated by periods, must start and end with an alphanumeric character. Hyphens are not allowed at the start or end of a block, and consecutive periods are not permitted."
+	// +kubebuilder:validation:Format=dns1123Subdomain
 	// +kubebuilder:validation:MinLength=1
 	// +kubebuilder:validation:MaxLength=245
 	// +optional
 	MachineNamePrefix string `json:"machineNamePrefix,omitempty"`
  • Apply / Chat
Suggestion importance[1-10]: 7

__

Why: The suggestion correctly identifies a non-standard and likely buggy validation rule and proposes replacing it with the standard +kubebuilder:validation:Format, which improves correctness, readability, and maintainability.

Medium
  • More

@JoelSpeed
Copy link
Contributor

/lgtm

@openshift-ci openshift-ci bot added the lgtm Indicates that a PR is ready to be merged. label Jan 29, 2026
@openshift-ci-robot
Copy link

Scheduling tests matching the pipeline_run_if_changed or not excluded by pipeline_skip_if_only_changed parameters:
/test e2e-aws-ovn
/test e2e-aws-ovn-hypershift
/test e2e-aws-ovn-hypershift-conformance
/test e2e-aws-ovn-techpreview
/test e2e-aws-serial-1of2
/test e2e-aws-serial-2of2
/test e2e-aws-serial-techpreview-1of2
/test e2e-aws-serial-techpreview-2of2
/test e2e-azure
/test e2e-gcp
/test e2e-upgrade
/test e2e-upgrade-out-of-change

@openshift-ci
Copy link
Contributor

openshift-ci bot commented Jan 29, 2026

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: JoelSpeed

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

@openshift-ci openshift-ci bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Jan 29, 2026
@openshift-ci
Copy link
Contributor

openshift-ci bot commented Jan 29, 2026

@RadekManak: 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/minor-e2e-upgrade-minor 9f951e9 link true /test minor-e2e-upgrade-minor
ci/prow/e2e-aws-serial-2of2 9f951e9 link true /test e2e-aws-serial-2of2
ci/prow/e2e-aws-serial-techpreview-2of2 9f951e9 link true /test e2e-aws-serial-techpreview-2of2
ci/prow/e2e-azure 9f951e9 link true /test e2e-azure
ci/prow/e2e-aws-ovn-hypershift-conformance 9f951e9 link true /test e2e-aws-ovn-hypershift-conformance
ci/prow/e2e-gcp 9f951e9 link true /test e2e-gcp
ci/prow/e2e-upgrade-out-of-change 9f951e9 link true /test e2e-upgrade-out-of-change
ci/prow/e2e-upgrade 9f951e9 link true /test e2e-upgrade
ci/prow/images 9f951e9 link true /test images
ci/prow/e2e-aws-ovn 9f951e9 link true /test e2e-aws-ovn
ci/prow/e2e-aws-ovn-techpreview 9f951e9 link true /test e2e-aws-ovn-techpreview
ci/prow/minor-images 9f951e9 link true /test minor-images
ci/prow/e2e-aws-serial-techpreview-1of2 9f951e9 link true /test e2e-aws-serial-techpreview-1of2
ci/prow/e2e-aws-serial-1of2 9f951e9 link true /test e2e-aws-serial-1of2

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.

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. jira/valid-bug Indicates that a referenced Jira bug is valid for the branch this PR is targeting. jira/valid-reference Indicates that this PR references a valid Jira ticket of any type. lgtm Indicates that a PR is ready to be merged. Review effort 2/5 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