Skip to content

Comments

[release-4.16] OCPBUGS-43964: Fix desired before sync_worker's work is initialized#1096

Closed
openshift-cherrypick-robot wants to merge 5 commits intoopenshift:release-4.16from
openshift-cherrypick-robot:cherry-pick-1081-to-release-4.16
Closed

[release-4.16] OCPBUGS-43964: Fix desired before sync_worker's work is initialized#1096
openshift-cherrypick-robot wants to merge 5 commits intoopenshift:release-4.16from
openshift-cherrypick-robot:cherry-pick-1081-to-release-4.16

Conversation

@openshift-cherrypick-robot

This is an automated cherry-pick of #1081

/assign hongkailiu

If the CVO pod gets restarted after a user sends a cluster
upgrade request with `--to-image`, the desired should not ALWAYS be
taken from `.Spec.DesiredUpdate`, e.g., when the targeting payload is blocked
on some precondition check failure.

The user request will be written to `cv.spec.desiredUpdate` where only
the `image` field is set, i.e., the `Version` field is empty.

If the CVO gets restarted, then

1. The desied [1] from `cv.spec.desiredUpdate` will be used to set
   `w.status.Actual` [2] and then applied to `cv.status.desired`.
2. When the next `optr.sync()` happens, the precondition check may become
   non-blocking [3] as the `Version` field is empty now.
3. CVO will then start an upgrade that should have been blocked.

[1]. https://github.com/openshift/cluster-version-operator/blob/1995380b6d755c29b926b846a64ca0039002c2cf/pkg/cvo/cvo.go#L680
[2]. https://github.com/openshift/cluster-version-operator/blob/1995380b6d755c29b926b846a64ca0039002c2cf/pkg/cvo/sync_worker.go#L502
[3]. https://github.com/openshift/cluster-version-operator/blob/1995380b6d755c29b926b846a64ca0039002c2cf/pkg/payload/precondition/clusterversion/rollback.go#L57
@openshift-ci
Copy link
Contributor

openshift-ci bot commented Oct 29, 2024

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: openshift-cherrypick-robot
Once this PR has been reviewed and has the lgtm label, please assign lalatendumohanty for approval. For more information see the Kubernetes Code Review Process.

The full list of commands accepted by this bot can be found 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-robot
Copy link
Contributor

@openshift-cherrypick-robot: Jira Issue OCPBUGS-35228 has been cloned as Jira Issue OCPBUGS-43964. Will retitle bug to link to clone.
/retitle [release-4.16] OCPBUGS-43964: Fix desired before sync_worker's work is initialized

Details

In response to this:

This is an automated cherry-pick of #1081

/assign hongkailiu

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.16] OCPBUGS-35228: Fix desired before sync_worker's work is initialized [release-4.16] OCPBUGS-43964: Fix desired before sync_worker's work is initialized Oct 29, 2024
@openshift-ci-robot openshift-ci-robot added jira/severity-moderate Referenced Jira bug's severity is moderate for the branch this PR is targeting. 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 Oct 29, 2024
@openshift-ci-robot
Copy link
Contributor

@openshift-cherrypick-robot: This pull request references Jira Issue OCPBUGS-43964, 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-35228 to target a version in 4.17.0, 4.17.z, but it targets "4.18.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 #1081

/assign hongkailiu

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.

@hongkailiu
Copy link
Member

/jira refresh

@openshift-ci-robot
Copy link
Contributor

@hongkailiu: This pull request references Jira Issue OCPBUGS-43964, which is invalid:

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.

@hongkailiu
Copy link
Member

/jira refresh

@openshift-ci-robot
Copy link
Contributor

@hongkailiu: This pull request references Jira Issue OCPBUGS-43964, which is invalid:

  • expected dependent Jira Issue OCPBUGS-42386 to be in one of the following states: VERIFIED, RELEASE PENDING, CLOSED (ERRATA), CLOSED (CURRENT RELEASE), CLOSED (DONE), CLOSED (DONE-ERRATA), but it is POST 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.

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.

@hongkailiu
Copy link
Member

/close

Obsoleted by #1097

@openshift-ci openshift-ci bot closed this Oct 29, 2024
@openshift-ci
Copy link
Contributor

openshift-ci bot commented Oct 29, 2024

@hongkailiu: Closed this PR.

Details

In response to this:

/close

Obsoleted by #1097

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.

@openshift-ci-robot
Copy link
Contributor

@openshift-cherrypick-robot: This pull request references Jira Issue OCPBUGS-43964. The bug has been updated to no longer refer to the pull request using the external bug tracker.

Details

In response to this:

This is an automated cherry-pick of #1081

/assign hongkailiu

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 Oct 29, 2024

@openshift-cherrypick-robot: 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/e2e-agnostic-operator 38c24e4 link true /test e2e-agnostic-operator
ci/prow/e2e-hypershift 38c24e4 link true /test e2e-hypershift
ci/prow/lint 38c24e4 link true /test lint
ci/prow/unit 38c24e4 link true /test unit

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

jira/invalid-bug Indicates that a referenced Jira bug is invalid for the branch this PR is targeting. jira/severity-moderate Referenced Jira bug's severity is moderate for the branch this PR is targeting. jira/valid-reference Indicates that this PR references a valid Jira ticket of any type.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants