Bug 1993159 - [Azure] Instead of updating the spec actuator updates status twice
Summary: [Azure] Instead of updating the spec actuator updates status twice
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: OpenShift Container Platform
Classification: Red Hat
Component: Cloud Compute
Version: 4.9
Hardware: Unspecified
OS: Unspecified
low
low
Target Milestone: ---
: 4.9.0
Assignee: Mike Fedosin
QA Contact: sunzhaohua
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2021-08-12 13:46 UTC by Mike Fedosin
Modified: 2021-10-18 17:46 UTC (History)
0 users

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2021-10-18 17:46:09 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Github openshift cluster-api-provider-azure pull 229 0 None None None 2021-08-12 14:45:55 UTC
Red Hat Product Errata RHSA-2021:3759 0 None None None 2021-10-18 17:46:23 UTC

Description Mike Fedosin 2021-08-12 13:46:08 UTC
Description of problem:
Currently, if we want to update a machine, the actuator patches its status twice instead of updating just spec and status:

https://github.com/openshift/cluster-api-provider-azure/blob/master/pkg/cloud/azure/actuators/machine_scope.go#L195-L201

There we need to update the spec first

Comment 2 sunzhaohua 2021-08-19 02:42:52 UTC
verified
clusterversion: 4.9.0-0.nightly-2021-08-18-144658

change log level to --v=4, edit machine, check machine-controller logs:
I0819 02:21:00.255042       1 controller.go:174] zhsun-819-vqzbk-worker-centralus3-xhghl: reconciling Machine
I0819 02:21:00.257068       1 actuator.go:208] zhsun-819-vqzbk-worker-centralus3-xhghl: actuator checking if machine exists
I0819 02:21:00.257090       1 machine_scope.go:226] Decoding ProviderConfig from Value
I0819 02:21:00.574763       1 reconciler.go:394] Provisioning state is 'Succeeded' for machine zhsun-819-vqzbk-worker-centralus3-xhghl
I0819 02:21:00.574794       1 controller.go:297] zhsun-819-vqzbk-worker-centralus3-xhghl: reconciling machine triggers idempotent update
I0819 02:21:00.574803       1 actuator.go:168] Updating machine zhsun-819-vqzbk-worker-centralus3-xhghl
I0819 02:21:00.574812       1 machine_scope.go:226] Decoding ProviderConfig from Value
I0819 02:21:00.755327       1 machine_scope.go:156] zhsun-819-vqzbk-worker-centralus3-xhghl: status unchanged
I0819 02:21:00.755446       1 machine_scope.go:148] Storing machine spec for "zhsun-819-vqzbk-worker-centralus3-xhghl", resourceVersion: 43840, generation: 4
I0819 02:21:00.755460       1 machine_scope.go:172] zhsun-819-vqzbk-worker-centralus3-xhghl: patching machine

Comment 5 errata-xmlrpc 2021-10-18 17:46:09 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory (Moderate: OpenShift Container Platform 4.9.0 bug fix and security update), and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHSA-2021:3759


Note You need to log in before you can comment on or make changes to this bug.