Skip to content

Conversation

@damdo
Copy link
Member

@damdo damdo commented Jul 2, 2025

This PR:

  1. Reintroduces/Un-reverts OCPCLOUD-2986,OCPBUGS-56849: fix: controllers: guard on empty .status.authoritativeAPI #1380 (originally reverted by OCPBUGS-58230: Revert: fix: controllers: guard on empty .status.authoritativeAPI #1383) (first commit)
  2. It fixes the original issue which prevented non-AWS TechPreview clusters to not be able to reconcile MAPI resources when .status.authoritativeAPI was empty/not set by implementing defaulting of the Authoritative API from spec to status (when not set) for MAPI Machines/MachineSets (which was something we were ought to do anyway https://issues.redhat.com/browse/OCPCLOUD-2985). For this we took a slight different approach than the agreed MutatingAdmissionPolicy, as we found out that it wouldn't work on CREATE for status subresource (context: https://redhat-internal.slack.com/archives/GE2HQ9QP4/p1751450680311659) (second commit)

@openshift-ci openshift-ci bot added the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Jul 2, 2025
@openshift-ci
Copy link
Contributor

openshift-ci bot commented Jul 2, 2025

Skipping CI for Draft Pull Request.
If you want CI signal for your change, please convert it to an actual PR.
You can still manually trigger a test run with /test all

@damdo
Copy link
Member Author

damdo commented Jul 2, 2025

/test ?

@openshift-ci
Copy link
Contributor

openshift-ci bot commented Jul 2, 2025

@damdo: The following commands are available to trigger required jobs:

/test e2e-aws-operator
/test e2e-aws-ovn
/test e2e-aws-ovn-upgrade
/test goimports
/test golint
/test govet
/test images
/test security
/test unit
/test verify-crds-sync
/test verify-deps

The following commands are available to trigger optional jobs:

/test e2e-aws-operator-techpreview
/test e2e-azure-manual-oidc
/test e2e-azure-operator
/test e2e-azure-ovn
/test e2e-gcp-operator
/test e2e-gcp-ovn
/test e2e-metal-ipi
/test e2e-metal-ipi-ovn-dualstack
/test e2e-metal-ipi-ovn-ipv6
/test e2e-metal-ipi-upgrade
/test e2e-metal-ipi-virtualmedia
/test e2e-nutanix
/test e2e-openstack
/test e2e-vsphere-host-groups-ovn
/test e2e-vsphere-operator
/test e2e-vsphere-ovn
/test e2e-vsphere-ovn-multi-vcenter
/test e2e-vsphere-ovn-serial
/test e2e-vsphere-ovn-techpreview
/test e2e-vsphere-ovn-techpreview-serial
/test e2e-vsphere-ovn-upgrade
/test e2e-vsphere-static-ovn
/test okd-scos-e2e-aws-ovn
/test okd-scos-images
/test regression-clusterinfra-aws-ipi-mapi

Use /test all to run the following jobs that were automatically triggered:

pull-ci-openshift-machine-api-operator-main-e2e-aws-operator
pull-ci-openshift-machine-api-operator-main-e2e-aws-operator-techpreview
pull-ci-openshift-machine-api-operator-main-e2e-aws-ovn
pull-ci-openshift-machine-api-operator-main-e2e-aws-ovn-upgrade
pull-ci-openshift-machine-api-operator-main-e2e-azure-operator
pull-ci-openshift-machine-api-operator-main-e2e-azure-ovn
pull-ci-openshift-machine-api-operator-main-e2e-gcp-operator
pull-ci-openshift-machine-api-operator-main-e2e-gcp-ovn
pull-ci-openshift-machine-api-operator-main-e2e-metal-ipi
pull-ci-openshift-machine-api-operator-main-e2e-metal-ipi-ovn-dualstack
pull-ci-openshift-machine-api-operator-main-e2e-metal-ipi-ovn-ipv6
pull-ci-openshift-machine-api-operator-main-e2e-metal-ipi-upgrade
pull-ci-openshift-machine-api-operator-main-e2e-metal-ipi-virtualmedia
pull-ci-openshift-machine-api-operator-main-e2e-nutanix
pull-ci-openshift-machine-api-operator-main-e2e-openstack
pull-ci-openshift-machine-api-operator-main-e2e-vsphere-host-groups-ovn
pull-ci-openshift-machine-api-operator-main-e2e-vsphere-operator
pull-ci-openshift-machine-api-operator-main-e2e-vsphere-ovn
pull-ci-openshift-machine-api-operator-main-e2e-vsphere-ovn-multi-vcenter
pull-ci-openshift-machine-api-operator-main-e2e-vsphere-ovn-serial
pull-ci-openshift-machine-api-operator-main-e2e-vsphere-ovn-techpreview
pull-ci-openshift-machine-api-operator-main-e2e-vsphere-ovn-techpreview-serial
pull-ci-openshift-machine-api-operator-main-e2e-vsphere-ovn-upgrade
pull-ci-openshift-machine-api-operator-main-e2e-vsphere-static-ovn
pull-ci-openshift-machine-api-operator-main-goimports
pull-ci-openshift-machine-api-operator-main-golint
pull-ci-openshift-machine-api-operator-main-govet
pull-ci-openshift-machine-api-operator-main-images
pull-ci-openshift-machine-api-operator-main-okd-scos-e2e-aws-ovn
pull-ci-openshift-machine-api-operator-main-security
pull-ci-openshift-machine-api-operator-main-unit
pull-ci-openshift-machine-api-operator-main-verify-crds-sync
pull-ci-openshift-machine-api-operator-main-verify-deps
Details

In response to this:

/test ?

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.

@damdo
Copy link
Member Author

damdo commented Jul 2, 2025

/test e2e-vsphere-ovn-techpreview
/test e2e-aws-operator-techpreview

@damdo damdo changed the title Fix controllers guard on empty status authoritative api take2 OCPCLOUD-2986,OCPCLOUD-2985: Fix controllers guard on empty status authoritative api take2 Jul 2, 2025
@openshift-ci-robot
Copy link
Contributor

openshift-ci-robot commented Jul 2, 2025

@damdo: This pull request references OCPCLOUD-2986 which is a valid jira issue.

This pull request references OCPCLOUD-2985 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 story to target the "4.20.0" version, but no target version was set.

Details

In 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.

@openshift-ci-robot openshift-ci-robot added the jira/valid-reference Indicates that this PR references a valid Jira ticket of any type. label Jul 2, 2025
@damdo damdo force-pushed the fix-controllers-guard-on-empty-status-authoritativeAPI-take2 branch from 1aeb26e to 4421b2c Compare July 2, 2025 16:01
@damdo damdo marked this pull request as ready for review July 2, 2025 19:59
@openshift-ci openshift-ci bot removed the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Jul 2, 2025
@openshift-ci openshift-ci bot requested review from JoelSpeed and RadekManak July 2, 2025 20:00
@damdo
Copy link
Member Author

damdo commented Jul 3, 2025

/retest

@damdo
Copy link
Member Author

damdo commented Jul 3, 2025

/assign @JoelSpeed @mdbooth

As you reviewed the previous one

@openshift-ci-robot
Copy link
Contributor

openshift-ci-robot commented Jul 3, 2025

@damdo: This pull request references OCPCLOUD-2986 which is a valid jira issue.

This pull request references OCPCLOUD-2985 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 story to target the "4.20.0" version, but no target version was set.

Details

In response to this:

This PR:

  1. Reintroduces OCPCLOUD-2986,OCPBUGS-56849: fix: controllers: guard on empty .status.authoritativeAPI #1380 (originally reverted by (OCPBUGS-58230: Revert: fix: controllers: guard on empty .status.authoritativeAPI #1383) (first commit)
  2. It fixes the original issue which prevented non-AWS TechPreview clusters to not be able to reconcile MAPI resources when .status.authoritativeAPI was empty/not set by implementing defaulting of the Authoritative API from spec to status (when not set) for MAPI Machines/MachineSets (which was something we were ought to do anyway https://issues.redhat.com/browse/OCPCLOUD-2985). For this we took a slight different approach than the agreed MutatingAdmissionPolicy, as we found out that it wouldn't work on CREATE for status subresource (context: https://redhat-internal.slack.com/archives/GE2HQ9QP4/p1751450680311659) (second commit)

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-robot
Copy link
Contributor

openshift-ci-robot commented Jul 3, 2025

@damdo: This pull request references OCPCLOUD-2986 which is a valid jira issue.

This pull request references OCPCLOUD-2985 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 story to target the "4.20.0" version, but no target version was set.

Details

In response to this:

This PR:

  1. Reintroduces OCPCLOUD-2986,OCPBUGS-56849: fix: controllers: guard on empty .status.authoritativeAPI #1380 (originally reverted by (OCPBUGS-58230: Revert: fix: controllers: guard on empty .status.authoritativeAPI #1383) (first commit)
  2. It fixes the original issue which prevented non-AWS TechPreview clusters to not be able to reconcile MAPI resources when .status.authoritativeAPI was empty/not set by implementing defaulting of the Authoritative API from spec to status (when not set) for MAPI Machines/MachineSets (which was something we were ought to do anyway https://issues.redhat.com/browse/OCPCLOUD-2985). For this we took a slight different approach than the agreed MutatingAdmissionPolicy, as we found out that it wouldn't work on CREATE for status subresource (context: https://redhat-internal.slack.com/archives/GE2HQ9QP4/p1751450680311659) (second commit)

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.

@damdo damdo changed the title OCPCLOUD-2986,OCPCLOUD-2985: Fix controllers guard on empty status authoritative api take2 OCPCLOUD-2986,OCPCLOUD-2985,OCPBUGS-56849: Fix controllers guard on empty status authoritative api take2 Jul 3, 2025
@openshift-ci-robot openshift-ci-robot added jira/severity-low Referenced Jira bug's severity is low for the branch this PR is targeting. jira/valid-bug Indicates that a referenced Jira bug is valid for the branch this PR is targeting. labels Jul 3, 2025
@openshift-ci-robot
Copy link
Contributor

openshift-ci-robot commented Jul 3, 2025

@damdo: This pull request references OCPCLOUD-2986 which is a valid jira issue.

This pull request references OCPCLOUD-2985 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 story to target the "4.20.0" version, but no target version was set.

This pull request references Jira Issue OCPBUGS-56849, which is valid.

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

Requesting review from QA contact:
/cc @sunzhaohua2

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

Details

In response to this:

This PR:

  1. Reintroduces OCPCLOUD-2986,OCPBUGS-56849: fix: controllers: guard on empty .status.authoritativeAPI #1380 (originally reverted by (OCPBUGS-58230: Revert: fix: controllers: guard on empty .status.authoritativeAPI #1383) (first commit)
  2. It fixes the original issue which prevented non-AWS TechPreview clusters to not be able to reconcile MAPI resources when .status.authoritativeAPI was empty/not set by implementing defaulting of the Authoritative API from spec to status (when not set) for MAPI Machines/MachineSets (which was something we were ought to do anyway https://issues.redhat.com/browse/OCPCLOUD-2985). For this we took a slight different approach than the agreed MutatingAdmissionPolicy, as we found out that it wouldn't work on CREATE for status subresource (context: https://redhat-internal.slack.com/archives/GE2HQ9QP4/p1751450680311659) (second commit)

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-robot
Copy link
Contributor

openshift-ci-robot commented Jul 3, 2025

@damdo: This pull request references OCPCLOUD-2986 which is a valid jira issue.

This pull request references OCPCLOUD-2985 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 story to target the "4.20.0" version, but no target version was set.

This pull request references Jira Issue OCPBUGS-56849, which is valid.

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

Requesting review from QA contact:
/cc @sunzhaohua2

Details

In response to this:

This PR:

  1. Reintroduces/Un-reverts OCPCLOUD-2986,OCPBUGS-56849: fix: controllers: guard on empty .status.authoritativeAPI #1380 (originally reverted by (OCPBUGS-58230: Revert: fix: controllers: guard on empty .status.authoritativeAPI #1383) (first commit)
  2. It fixes the original issue which prevented non-AWS TechPreview clusters to not be able to reconcile MAPI resources when .status.authoritativeAPI was empty/not set by implementing defaulting of the Authoritative API from spec to status (when not set) for MAPI Machines/MachineSets (which was something we were ought to do anyway https://issues.redhat.com/browse/OCPCLOUD-2985). For this we took a slight different approach than the agreed MutatingAdmissionPolicy, as we found out that it wouldn't work on CREATE for status subresource (context: https://redhat-internal.slack.com/archives/GE2HQ9QP4/p1751450680311659) (second commit)

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-robot
Copy link
Contributor

openshift-ci-robot commented Jul 3, 2025

@damdo: This pull request references OCPCLOUD-2986 which is a valid jira issue.

This pull request references OCPCLOUD-2985 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 story to target the "4.20.0" version, but no target version was set.

This pull request references Jira Issue OCPBUGS-56849, which is valid.

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

Requesting review from QA contact:
/cc @sunzhaohua2

Details

In response to this:

This PR:

  1. Reintroduces/Un-reverts OCPCLOUD-2986,OCPBUGS-56849: fix: controllers: guard on empty .status.authoritativeAPI #1380 (originally reverted by OCPBUGS-58230: Revert: fix: controllers: guard on empty .status.authoritativeAPI #1383) (first commit)
  2. It fixes the original issue which prevented non-AWS TechPreview clusters to not be able to reconcile MAPI resources when .status.authoritativeAPI was empty/not set by implementing defaulting of the Authoritative API from spec to status (when not set) for MAPI Machines/MachineSets (which was something we were ought to do anyway https://issues.redhat.com/browse/OCPCLOUD-2985). For this we took a slight different approach than the agreed MutatingAdmissionPolicy, as we found out that it wouldn't work on CREATE for status subresource (context: https://redhat-internal.slack.com/archives/GE2HQ9QP4/p1751450680311659) (second commit)

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.

@damdo
Copy link
Member Author

damdo commented Jul 3, 2025

/test e2e-vsphere-ovn

@damdo
Copy link
Member Author

damdo commented Jul 3, 2025

/hold

For pre-merge testing

@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 Jul 3, 2025
@damdo
Copy link
Member Author

damdo commented Jul 3, 2025

/retest

@damdo damdo requested a review from mdbooth July 3, 2025 11:58
@openshift-ci
Copy link
Contributor

openshift-ci bot commented Jul 3, 2025

@damdo: 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/okd-scos-e2e-aws-ovn 4421b2c link false /test okd-scos-e2e-aws-ovn
ci/prow/e2e-vsphere-ovn-techpreview-serial 4421b2c link false /test e2e-vsphere-ovn-techpreview-serial

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.

@JoelSpeed
Copy link
Contributor

/approve
/lgtm

@openshift-ci openshift-ci bot added the lgtm Indicates that a PR is ready to be merged. label Jul 3, 2025
@openshift-ci
Copy link
Contributor

openshift-ci bot commented Jul 3, 2025

[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 Jul 3, 2025
@mdbooth
Copy link
Contributor

mdbooth commented Jul 3, 2025

Also
/lgtm

@damdo
Copy link
Member Author

damdo commented Jul 3, 2025

Thanks both! @sunzhaohua2 please do let us know when the testing is done and if we can unhold it.

@sunzhaohua2
Copy link
Contributor

@damdo I tested this pr. clusterversion 4.20.0-0-2025-07-03-082252-test-ci-ln-ms6z3bb-latest
In AWS, I still see this issue https://issues.redhat.com//browse/OCPBUGS-56849, mapi machine stuck in Provisioning.

aws/ $ oc get machine.m
zhsunaws72-7vbxd-worker1-hz72d             Provisioning                                         24s
zhsunaws72-7vbxd-worker1-k6x9f             Provisioning                                         24m

In non-AWS, I tested on gcp, machineset's .status.authoritativeAPI are defaulting and setting it to .spec.authoritativeAPI.
but there are no .status.authoritativeAPI for machines, is this expected? If machineset spec.authoritativeAPI is ClusterAPI, no mapi machine is created.
I created 2 standalone machines with authoritativeAPI:MachineAPI and authoritativeAPI:ClusterAPI, both have mapi machines running.

$ oc get machineset.m            
NAME                        DESIRED   CURRENT   READY   AVAILABLE   AGE
zhsungcp73-67kb9-worker-a   1         1         1       1           5h6m
zhsungcp73-67kb9-worker-b   1         1         1       1           5h6m
zhsungcp73-67kb9-worker-c   1         1         1       1           5h6m
zhsungcp73-67kb9-worker-f   0         0                             5h6m
zhsungcp73-67kb9-worker1    1                                       43m

$ oc get machineset.m zhsungcp73-67kb9-worker-c -o yaml
status:
  authoritativeAPI: MachineAPI
  availableReplicas: 1
  conditions:
  - lastTransitionTime: "2025-07-03T08:50:08Z"
    message: The AuthoritativeAPI status is set to 'MachineAPI'
    reason: AuthoritativeAPIMachineAPI
    severity: Info
    status: "False"
    type: Paused
  fullyLabeledReplicas: 1
  observedGeneration: 1
  readyReplicas: 1
  replicas: 1

$ oc get machineset.m zhsungcp73-67kb9-worker1 -o yaml
status:
  authoritativeAPI: ClusterAPI
  conditions:
  - lastTransitionTime: "2025-07-03T13:05:48Z"
    message: The AuthoritativeAPI status is set to 'ClusterAPI'
    reason: AuthoritativeAPINotMachineAPI
    status: "True"
    type: Paused
  observedGeneration: 1

zhsun:gcp/ $ oc get machine.m | grep zhsungcp73-67kb9-worker1              
zhsun:gcp/ $

zhsun:gcp/ $ oc get machineset.c -n openshift-cluster-api        
No resources found in openshift-cluster-api namespace.
zhsun:gcp/ $ oc get machines.cluster.x-k8s.io -n openshift-cluster-api           
No resources found in openshift-cluster-api namespace.
zhsun:gcp/ $ oc get gcpmachinetemplate -n openshift-cluster-api      
No resources found in openshift-cluster-api namespace.

$ oc get machine.m zhsungcp73-67kb9-worker-c-75m9p -o yaml
status:
  addresses:
  - address: 10.0.128.2
    type: InternalIP
  - address: zhsungcp73-67kb9-worker-c-75m9p.us-central1-c.c.openshift-qe.internal
    type: InternalDNS
  - address: zhsungcp73-67kb9-worker-c-75m9p.c.openshift-qe.internal
    type: InternalDNS
  - address: zhsungcp73-67kb9-worker-c-75m9p
    type: InternalDNS
  conditions:
  - lastTransitionTime: "2025-07-03T08:50:20Z"
    status: "True"
    type: Drainable
  - lastTransitionTime: "2025-07-03T08:51:12Z"
    status: "True"
    type: InstanceExists
  - lastTransitionTime: "2025-07-03T08:50:20Z"
    message: The AuthoritativeAPI is not set
    reason: AuthoritativeAPIMachineAPI
    severity: Info
    status: "False"
    type: Paused
  - lastTransitionTime: "2025-07-03T08:50:20Z"
    status: "True"
    type: Terminable


$ oc get machine.m       
NAME                              PHASE     TYPE            REGION        ZONE            AGE
zhsungcp73-67kb9-worker-c1        Running   n2-standard-4   us-central1   us-central1-c   18m
zhsungcp73-67kb9-worker-c2        Running   n2-standard-4   us-central1   us-central1-c   18m

zhsun:gcp/ $ oc get machine.m zhsungcp73-67kb9-worker-c1 -o yaml| grep authoritativeAPI      
  authoritativeAPI: MachineAPI
zhsun:gcp/ $ oc get machine.m zhsungcp73-67kb9-worker-c2 -o yaml| grep authoritativeAPI        
  authoritativeAPI: ClusterAPI

@damdo
Copy link
Member Author

damdo commented Jul 4, 2025

More context on the above issue reported here, the further testing done and the measures that were taken:
https://redhat-internal.slack.com/archives/GE2HQ9QP4/p1751450680311659

We can proceed with merging this.

@sunzhaohua2
Copy link
Contributor

Tested with image build 4.20,openshift/machine-api-operator#1386,openshift/machine-api-provider-aws#134

In aws, work as expected, https://issues.redhat.com//browse/OCPBUGS-56849 is fixed.

In non-aws, I tried on gcp, results are same with before. we need to create machine-api-provider PRs for that non-aws platform that bumps MAO with the machine-controller change, like pr openshift/machine-api-provider-aws#134

/label qe-approved

@openshift-ci openshift-ci bot added the qe-approved Signifies that QE has signed off on this PR label Jul 4, 2025
@openshift-ci-robot
Copy link
Contributor

openshift-ci-robot commented Jul 4, 2025

@damdo: This pull request references OCPCLOUD-2986 which is a valid jira issue.

This pull request references OCPCLOUD-2985 which is a valid jira issue.

This pull request references Jira Issue OCPBUGS-56849, which is valid.

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

Requesting review from QA contact:
/cc @sunzhaohua2

Details

In response to this:

This PR:

  1. Reintroduces/Un-reverts OCPCLOUD-2986,OCPBUGS-56849: fix: controllers: guard on empty .status.authoritativeAPI #1380 (originally reverted by OCPBUGS-58230: Revert: fix: controllers: guard on empty .status.authoritativeAPI #1383) (first commit)
  2. It fixes the original issue which prevented non-AWS TechPreview clusters to not be able to reconcile MAPI resources when .status.authoritativeAPI was empty/not set by implementing defaulting of the Authoritative API from spec to status (when not set) for MAPI Machines/MachineSets (which was something we were ought to do anyway https://issues.redhat.com/browse/OCPCLOUD-2985). For this we took a slight different approach than the agreed MutatingAdmissionPolicy, as we found out that it wouldn't work on CREATE for status subresource (context: https://redhat-internal.slack.com/archives/GE2HQ9QP4/p1751450680311659) (second commit)

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.

@damdo
Copy link
Member Author

damdo commented Jul 4, 2025

Thanks a lot @sunzhaohua2

/unhold

@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 4, 2025
@openshift-merge-bot openshift-merge-bot bot merged commit 81d86b5 into openshift:main Jul 4, 2025
32 of 34 checks passed
@openshift-ci-robot
Copy link
Contributor

@damdo: Jira Issue OCPBUGS-56849: Some pull requests linked via external trackers have merged:

The following pull requests linked via external trackers have not merged:

These pull request must merge or be unlinked from the Jira bug in order for it to move to the next state. Once unlinked, request a bug refresh with /jira refresh.

Jira Issue OCPBUGS-56849 has not been moved to the MODIFIED state.

Details

In response to this:

This PR:

  1. Reintroduces/Un-reverts OCPCLOUD-2986,OCPBUGS-56849: fix: controllers: guard on empty .status.authoritativeAPI #1380 (originally reverted by OCPBUGS-58230: Revert: fix: controllers: guard on empty .status.authoritativeAPI #1383) (first commit)
  2. It fixes the original issue which prevented non-AWS TechPreview clusters to not be able to reconcile MAPI resources when .status.authoritativeAPI was empty/not set by implementing defaulting of the Authoritative API from spec to status (when not set) for MAPI Machines/MachineSets (which was something we were ought to do anyway https://issues.redhat.com/browse/OCPCLOUD-2985). For this we took a slight different approach than the agreed MutatingAdmissionPolicy, as we found out that it wouldn't work on CREATE for status subresource (context: https://redhat-internal.slack.com/archives/GE2HQ9QP4/p1751450680311659) (second commit)

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-bot
Copy link
Contributor

[ART PR BUILD NOTIFIER]

Distgit: ose-machine-api-operator
This PR has been included in build ose-machine-api-operator-container-v4.20.0-202507040913.p0.g81d86b5.assembly.stream.el9.
All builds following this will include this PR.

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/severity-low Referenced Jira bug's severity is low for the branch this PR is targeting. 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. qe-approved Signifies that QE has signed off on this PR

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants