OCPCLOUD-3570: e2e skip Cluster API authoritative MachineSets in GetFirstMAPIMachineSet#610
OCPCLOUD-3570: e2e skip Cluster API authoritative MachineSets in GetFirstMAPIMachineSet#610pmeida wants to merge 1 commit into
Conversation
|
Pipeline controller notification For optional jobs, comment This repository is configured in: LGTM mode |
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Repository YAML (base), Central YAML (inherited) Review profile: CHILL Plan: Enterprise Run ID: 📒 Files selected for processing (1)
🚧 Files skipped from review as they are similar to previous changes (1)
Walkthrough
ChangesMachineSet selection
Estimated review effort🎯 2 (Simple) | ⏱️ ~5–15 minutes Suggested labels
Suggested reviewers
🚥 Pre-merge checks | ✅ 15✅ Passed checks (15 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
@pmeida: This pull request references OCPCLOUD-3570 which is a valid jira issue. Warning: The referenced jira issue has an invalid target version for the target branch this PR targets: expected the bug to target the "5.0.0" version, but no target version was set. DetailsIn response to this:
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. |
|
/test e2e-aws-capi-techpreview |
damdo
left a comment
There was a problem hiding this comment.
Thanks!!
One style nit
/approve
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: damdo The full list of commands accepted by this bot can be found here. The pull request process is described here DetailsNeeds approval from an approver in each of these files:
Approvers can indicate their approval by writing |
…eSet When migration tests run, the machine sync controller creates genuine mapiv1beta1.MachineSet objects in the MAPI namespace as mirrors of CAPI-authoritative MachineSets. These synced mirrors have names (e.g. capi-ms-auth-capi-*) that sort before native worker MachineSets, causing GetFirstMAPIMachineSet to return one of them. getMAPICreatedInstance then fails to find MAPI Machine objects for it because the machines are provisioned by CAPI, not MAPI. Filter to skip MachineSets where Spec.AuthoritativeAPI == ClusterAPI. Spec is used instead of Status because the status is set by the migration controller after reconciliation and may be empty on freshly created objects. Co-Authored-By: Claude Sonnet 4.6 (1M context) <noreply@anthropic.com>
b92961d to
cf9bc23
Compare
|
/test e2e-aws-capi-techpreview |
|
/lgtm |
|
/verified by ci |
|
Tests from second stage were triggered manually. Pipeline can be controlled only manually, until HEAD changes. Use command to trigger second stage. |
|
@damdo: This PR has been marked as verified by DetailsIn response to this:
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. |
|
/pipeline ? |
|
/pipeline required |
|
Scheduling tests matching the |
|
/retest |
1 similar comment
|
/retest |
|
@pmeida: The following tests failed, say
Full PR test history. Your PR dashboard. DetailsInstructions 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. |
Summary
GetFirstMAPIMachineSetsorts allmapiv1beta1.MachineSetobjects inopenshift-machine-apialphabetically and returns the first. When migration tests run, the machine sync controller creates genuine MAPI MachineSet objects as mirrors of CAPI-authoritative MachineSets (e.g.capi-ms-auth-capi-*). These names sort before native worker MachineSets, causing the function to return a synced mirror.getMAPICreatedInstancethen fails to find MAPI Machine objects for it because the machines are provisioned by CAPI, not MAPI.Filter to skip MachineSets where
Spec.AuthoritativeAPI == ClusterAPI.Specis used instead ofStatusbecause the status is set by the migration controller after reconciliation and may be empty on freshly created objects.Observed failure:
This proves that function
GetFirstMAPIMachineSetreturned a MachineSet namedcapi-ms-auth-capi-wqbkl. The name itself (capi-msprefix,auth-capi= CAPI authoritative) is self-documenting - it's a CAPI-synced mirror that was picked up from the MAPI namespaceExample run: pull-ci-openshift-cluster-capi-operator-main-e2e-aws-capi-techpreview #2070173165606146048
Test plan
e2e-aws-capi-techpreviewpasses without the flakeSummary by CodeRabbit