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

test(watch-tool): deflake TestRetryWatcherToFinishWithUnreadEvents #94554

Conversation

knight42
Copy link
Member

@knight42 knight42 commented Sep 5, 2020

Signed-off-by: knight42 anonymousknight96@gmail.com

What type of PR is this?

/kind flake

What this PR does / why we need it:

https://prow.k8s.io/view/gcs/kubernetes-jenkins/logs/periodic-kubernetes-bazel-test-master/1302148076210753536

=== RUN   TestRetryWatcherToFinishWithUnreadEvents
I0905 08:00:46.207132  188302 retrywatcher.go:275] Stopping RetryWatcher.
    retrywatcher_test.go:594: Failed to close the watcher
--- FAIL: TestRetryWatcherToFinishWithUnreadEvents (0.04s)

The current timeout seems to be too tight, when I tested locally, the time cost to stop the watcher could be:

16.398244ms
10.165828ms
10.182775ms
10.197831ms

I think 20ms is a more reasonable timeout.

Which issue(s) this PR fixes:

Part of #94528

Special notes for your reviewer:

Does this PR introduce a user-facing change?:

NONE

Additional documentation e.g., KEPs (Kubernetes Enhancement Proposals), usage docs, etc.:


@k8s-ci-robot k8s-ci-robot added release-note-none Denotes a PR that doesn't merit a release note. kind/flake Categorizes issue or PR as related to a flaky test. size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. needs-sig Indicates an issue or PR lacks a `sig/foo` label and requires one. needs-priority Indicates a PR lacks a `priority/foo` label and requires one. labels Sep 5, 2020
@knight42
Copy link
Member Author

knight42 commented Sep 5, 2020

/cc @liggitt

@k8s-ci-robot k8s-ci-robot added sig/api-machinery Categorizes an issue or PR as relevant to SIG API Machinery. and removed needs-sig Indicates an issue or PR lacks a `sig/foo` label and requires one. labels Sep 5, 2020
select {
case <-watcher.Done():
break
case <-time.After(10 * time.Millisecond):
Copy link
Member

Choose a reason for hiding this comment

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

make this a whole second… this isn't a performance test

Copy link
Member Author

Choose a reason for hiding this comment

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

Fixed

Signed-off-by: knight42 <anonymousknight96@gmail.com>
@knight42 knight42 force-pushed the fix/TestRetryWatcherToFinishWithUnreadEvents branch from 674a15e to 1d92314 Compare September 5, 2020 16:06
@liggitt
Copy link
Member

liggitt commented Sep 5, 2020

/lgtm
/approve
/milestone v1.20
/priority important-soon

@k8s-ci-robot k8s-ci-robot added the priority/important-soon Must be staffed and worked on either currently, or very soon, ideally in time for the next release. label Sep 5, 2020
@k8s-ci-robot k8s-ci-robot added this to the v1.20 milestone Sep 5, 2020
@k8s-ci-robot k8s-ci-robot removed the needs-priority Indicates a PR lacks a `priority/foo` label and requires one. label Sep 5, 2020
@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Sep 5, 2020
@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: knight42, liggitt

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

@k8s-ci-robot k8s-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Sep 5, 2020
@k8s-ci-robot k8s-ci-robot merged commit 74053d5 into kubernetes:master Sep 5, 2020
@knight42 knight42 deleted the fix/TestRetryWatcherToFinishWithUnreadEvents branch September 5, 2020 17:16
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. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. kind/flake Categorizes issue or PR as related to a flaky test. lgtm "Looks good to me", indicates that a PR is ready to be merged. priority/important-soon Must be staffed and worked on either currently, or very soon, ideally in time for the next release. release-note-none Denotes a PR that doesn't merit a release note. sig/api-machinery Categorizes an issue or PR as relevant to SIG API Machinery. size/XS Denotes a PR that changes 0-9 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants