Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bug 1824943: check minimum available time in waitForDeploymentRollout #561

Merged
merged 2 commits into from Apr 21, 2020

Conversation

enxebre
Copy link
Member

@enxebre enxebre commented Apr 20, 2020

There might be scenarios where the operator flips between degraded false/true.
E.g the managed deployment rolls out successfully. A particular business logic path makes one container to panic consistently. Go to 1.

https://github.com/openshift/api/blob/2ea89d203c53704f1fcfeb55c13ededab14fd020/config/v1/types_cluster_operator.go#L168
This results in a lower quality of service and Degraded should not oscillate but rather should remain true until the persistent observation of the problematic condition is fixed.

This PR cover this scenario by raising the expectation for the managed deployments to be available for a minimum duration, i.e 3 min.

@openshift-ci-robot openshift-ci-robot added bugzilla/medium bugzilla/valid-bug Indicates that a referenced Bugzilla bug is valid for the branch this PR is targeting. labels Apr 20, 2020
@openshift-ci-robot
Copy link
Contributor

@enxebre: This pull request references Bugzilla bug 1824943, which is valid. The bug has been moved to the POST state. The bug has been updated to refer to the pull request using the external bug tracker.

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

In response to this:

Bug 1824943: check minimum available time in waitForDeploymentRollout

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/test-infra repository.

Copy link
Contributor

@alexander-demicev alexander-demicev left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/approve

@openshift-ci-robot openshift-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Apr 20, 2020
@enxebre
Copy link
Member Author

enxebre commented Apr 20, 2020

/retest

Copy link
Contributor

@JoelSpeed JoelSpeed left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added a couple of comments, don't feel particularly strongly about either, otherwise looks sane

@@ -25,6 +25,7 @@ import (
fakedynamic "k8s.io/client-go/dynamic/fake"
"k8s.io/client-go/informers"
fakekube "k8s.io/client-go/kubernetes/fake"
clientgoscheme "k8s.io/client-go/kubernetes/scheme"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit non-blocking: isn't this normally just imported as scheme? Don't think it clashes so could leave as scheme?

}

return nil
}

func (optr *Operator) waitForDeploymentRollout(resource *appsv1.Deployment) error {
func (optr *Operator) waitForDeploymentRollout(resource *appsv1.Deployment, deploymentRolloutPollInterval, deploymentRolloutTimeout time.Duration) error {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These names don't need to be so long/descriptive while they're in this method, could shorten them + then they don't shadow the package level consts

Suggested change
func (optr *Operator) waitForDeploymentRollout(resource *appsv1.Deployment, deploymentRolloutPollInterval, deploymentRolloutTimeout time.Duration) error {
func (optr *Operator) waitForDeploymentRollout(resource *appsv1.Deployment, pollInterval, timeout time.Duration) error {

@openshift-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: alexander-demichev

The full list of commands accepted by this bot can be found here.

The pull request process is described here

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

@enxebre: The following tests failed, say /retest to rerun all failed tests:

Test name Commit Details Rerun command
ci/prow/e2e-azure b73936e link /test e2e-azure
ci/prow/e2e-azure-operator b73936e link /test e2e-azure-operator
ci/prow/e2e-aws-scaleup-rhel7 b73936e link /test e2e-aws-scaleup-rhel7

Full PR test history. Your PR dashboard. Please help us cut down on flakes by linking to an open issue when you hit one in your PR.

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/test-infra repository. I understand the commands that are listed here.

Copy link
Contributor

@JoelSpeed JoelSpeed left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/lgtm

@openshift-ci-robot openshift-ci-robot added the lgtm Indicates that a PR is ready to be merged. label Apr 21, 2020
@openshift-merge-robot openshift-merge-robot merged commit 241a19c into openshift:master Apr 21, 2020
@openshift-ci-robot
Copy link
Contributor

@enxebre: All pull requests linked via external trackers have merged: openshift/machine-api-operator#561. Bugzilla bug 1824943 has been moved to the MODIFIED state.

In response to this:

Bug 1824943: check minimum available time in waitForDeploymentRollout

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/test-infra 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. bugzilla/valid-bug Indicates that a referenced Bugzilla bug is valid for the branch this PR is targeting. lgtm Indicates that a PR is ready to be merged.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants