Skip to content

[release-4.22] OCPBUGS-87153: E2E: Refactor OVS affinity tests into shared helpers and add new workload-partitioning and control-plane reboot test cases.#1537

Merged
openshift-merge-bot[bot] merged 8 commits into
openshift:release-4.22from
openshift-cherrypick-robot:cherry-pick-1509-to-release-4.22
Jul 9, 2026
Merged

[release-4.22] OCPBUGS-87153: E2E: Refactor OVS affinity tests into shared helpers and add new workload-partitioning and control-plane reboot test cases.#1537
openshift-merge-bot[bot] merged 8 commits into
openshift:release-4.22from
openshift-cherrypick-robot:cherry-pick-1509-to-release-4.22

Conversation

@openshift-cherrypick-robot

Copy link
Copy Markdown

This is an automated cherry-pick of #1509

/assign mrniranjan

Extract reusable helper functions (getOvnContainerAffinity,
getOvsAffinities, verifyOvsAffinity, verifyOvsMatchesExpected,
createGuPod, waitForDeploymentReady, expectedOvsAffinity,
getGuPodCPUs, collectGuCPUsFromPodList) to eliminate repeated
patterns across OVS dynamic CPU affinity test cases.

Add cluster.IsWorkloadPartitioningEnabled() to the shared cluster
utility package, querying Infrastructure.Status.CPUPartitioning.

Refactor test_id:64100, 64101, 64102, 64103, 75257 to use the new
helpers, add WP-aware assertion branching, fix indentation
inconsistencies, and reduce overall test noise.

AIA Human-AI blend, Content edits, Human-initiated, claude-4.6-opus-high-thinking v1.0

Signed-off-by: Niranjan M.R <mniranja@redhat.com>
Add new test cases for OVS dynamic CPU affinity under workload
partitioning and control plane reboot scenarios:

- Skip test suite early when workerRTNode is a non-schedulable
  control plane node

- Add control plane reboot test: verifies OVS affinity is not
  restricted to reserved CPUs before and after rebooting a control
  plane node with dynamic pinning enabled

- Add workload partitioning test context with four tests:
  - OVN pod restricted to reserved CPUs
  - OVS affinity wider than OVN pod
  - Reserved CPUs always included in OVS affinity (with/without GU pods)
  - OVS falls to reserved-only when all isolated CPUs are exhausted

AIA Human-AI blend, Content edits, Human-initiated, claude-4.6-opus-high-thinking v1.0

Signed-off-by: Niranjan M.R <mniranja@redhat.com>
- Add GinkgoHelper() to all test helper functions that perform
  assertions, so failures report the caller location
- Use cpuset.Equals() for cpuset comparisons instead of struct equality
- Refactor CP reboot test to assert against online CPUs directly,
  avoiding dependency on worker profile's reservedCPUSet which may
  not apply to the CP node on MNO clusters
- Fix exhaustion test: rename to reflect it verifies GU pod exclusion
  (not full exhaustion), compute exact expected affinity using
  expectedOvsAffinity, and assert equality instead of weak subset check
- Simplify expectedOvsAffinity to onlineCPUs.Difference(guPodCPUs)
- Fix indentation to match surrounding test blocks
Verify ovs affinity map is not empty

Signed-off-by: Niranjan M.R <mniranja@redhat.com>
…lated

Signed-off-by: Niranjan M.R <mniranja@redhat.com>
Add polarion test case id for test cases
related to workload partitioning

Signed-off-by: Niranjan M.R <mniranja@redhat.com>
* use existing runtime client instead of initializing a new client
everytime for fetching cluster objects
* Use Eventually instead of fixed sleep
* merge verifyOvsMatchesExpectedWP and verifyOvsMatchesExpected
  functions
* Check OVNAffinity which should be reserved + isolated
* return map in parseProfileCPUSets
* deduct GU pods from ovs affinity

Signed-off-by: Niranjan M.R <mniranja@redhat.com>
@coderabbitai

coderabbitai Bot commented Jun 4, 2026

Copy link
Copy Markdown

Important

Review skipped

Auto reviews are disabled on base/target branches other than the default branch.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: Repository: openshift/coderabbit/.coderabbit.yaml

Review profile: CHILL

Plan: Enterprise

Run ID: 64cd509e-e47f-46aa-986a-503343656e91

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

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

@openshift-ci openshift-ci Bot requested review from Tal-or and jmencak June 4, 2026 12:42
@openshift-ci-robot

Copy link
Copy Markdown
Contributor

@openshift-cherrypick-robot: Jira Issue OCPBUGS-86480 has been cloned as Jira Issue OCPBUGS-87153. Will retitle bug to link to clone.
/retitle [release-4.22] OCPBUGS-87153: E2E: Refactor OVS affinity tests into shared helpers and add new workload-partitioning and control-plane reboot test cases.

Details

In response to this:

This is an automated cherry-pick of #1509

/assign mrniranjan

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 openshift-ci Bot changed the title [release-4.22] OCPBUGS-86480: E2E: Refactor OVS affinity tests into shared helpers and add new workload-partitioning and control-plane reboot test cases. [release-4.22] OCPBUGS-87153: E2E: Refactor OVS affinity tests into shared helpers and add new workload-partitioning and control-plane reboot test cases. Jun 4, 2026
@openshift-ci-robot openshift-ci-robot added jira/valid-reference Indicates that this PR references a valid Jira ticket of any type. jira/invalid-bug Indicates that a referenced Jira bug is invalid for the branch this PR is targeting. labels Jun 4, 2026
@openshift-ci-robot

Copy link
Copy Markdown
Contributor

@openshift-cherrypick-robot: This pull request references Jira Issue OCPBUGS-87153, which is invalid:

  • release note text must be set and not match the template OR release note type must be set to "Release Note Not Required". For more information you can reference the OpenShift Bug Process.
  • expected dependent Jira Issue OCPBUGS-86480 to target a version in 5.0.0, but it targets "5.0" instead

Comment /jira refresh to re-evaluate validity if changes to the Jira bug are made, or edit the title of this pull request to link to a different bug.

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

Details

In response to this:

This is an automated cherry-pick of #1509

/assign mrniranjan

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.

@mrniranjan

Copy link
Copy Markdown
Contributor

/jira refresh

@openshift-ci-robot

Copy link
Copy Markdown
Contributor

@mrniranjan: This pull request references Jira Issue OCPBUGS-87153, which is invalid:

  • release note text must be set and not match the template OR release note type must be set to "Release Note Not Required". For more information you can reference the OpenShift Bug Process.

Comment /jira refresh to re-evaluate validity if changes to the Jira bug are made, or edit the title of this pull request to link to a different bug.

Details

In response to this:

/jira refresh

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.

@mrniranjan

Copy link
Copy Markdown
Contributor

/jira refresh

@openshift-ci-robot openshift-ci-robot added jira/valid-bug Indicates that a referenced Jira bug is valid for the branch this PR is targeting. and removed jira/invalid-bug Indicates that a referenced Jira bug is invalid for the branch this PR is targeting. labels Jun 4, 2026
@openshift-ci-robot

Copy link
Copy Markdown
Contributor

@mrniranjan: This pull request references Jira Issue OCPBUGS-87153, which is valid. The bug has been moved to the POST state.

7 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 New, which is one of the valid states (NEW, ASSIGNED, POST)
  • release note type set to "Release Note Not Required"
  • dependent bug Jira Issue OCPBUGS-86480 is in the state Verified, which is one of the valid states (MODIFIED, ON_QA, VERIFIED)
  • dependent Jira Issue OCPBUGS-86480 targets the "5.0.0" version, which is one of the valid target versions: 5.0.0
  • bug has dependents
Details

In response to this:

/jira refresh

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.

@jmencak

jmencak commented Jun 4, 2026

Copy link
Copy Markdown
Contributor

/lgtm
/approve
/label backport-risk-assessed

@openshift-ci openshift-ci Bot added the backport-risk-assessed Indicates a PR to a release branch has been evaluated and considered safe to accept. label Jun 4, 2026
@jmencak

jmencak commented Jun 4, 2026

Copy link
Copy Markdown
Contributor

/hold
to give a chance to other reviewers to comment. Feel free to unhold.

@openshift-ci openshift-ci Bot added the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Jun 4, 2026
@openshift-ci openshift-ci Bot added the lgtm Indicates that a PR is ready to be merged. label Jun 4, 2026
@openshift-ci

openshift-ci Bot commented Jun 4, 2026

Copy link
Copy Markdown
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: jmencak, openshift-cherrypick-robot

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 Jun 4, 2026
@mrniranjan

Copy link
Copy Markdown
Contributor

/retest

@mrniranjan

Copy link
Copy Markdown
Contributor

/verified by @mrniranjan

@openshift-ci-robot openshift-ci-robot added the verified Signifies that the PR passed pre-merge verification criteria label Jul 6, 2026
@openshift-ci-robot

Copy link
Copy Markdown
Contributor

@mrniranjan: This PR has been marked as verified by @mrniranjan.

Details

In response to this:

/verified by @mrniranjan

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.

@mrniranjan

Copy link
Copy Markdown
Contributor

/hold cancel

@openshift-ci openshift-ci Bot removed the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Jul 6, 2026
@Tal-or

Tal-or commented Jul 9, 2026

Copy link
Copy Markdown
Contributor

/retest

@openshift-ci

openshift-ci Bot commented Jul 9, 2026

Copy link
Copy Markdown
Contributor

@openshift-cherrypick-robot: all tests passed!

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.

@openshift-merge-bot openshift-merge-bot Bot merged commit c3b66c7 into openshift:release-4.22 Jul 9, 2026
18 checks passed
@openshift-ci-robot

Copy link
Copy Markdown
Contributor

@openshift-cherrypick-robot: Jira Issue Verification Checks: Jira Issue OCPBUGS-87153
✔️ This pull request was pre-merge verified.
✔️ All associated pull requests have merged.
✔️ All associated, merged pull requests were pre-merge verified.

Jira Issue OCPBUGS-87153 has been moved to the MODIFIED state and will move to the VERIFIED state when the change is available in an accepted nightly payload. 🕓

Details

In response to this:

This is an automated cherry-pick of #1509

/assign mrniranjan

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.

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. backport-risk-assessed Indicates a PR to a release branch has been evaluated and considered safe to accept. 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. verified Signifies that the PR passed pre-merge verification criteria

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants