Skip to content

Conversation

@henrybear327
Copy link
Contributor

@henrybear327 henrybear327 commented Jan 3, 2026

Implement RunWatchLoop in Kubernetes traffic.

Please read https://github.com/etcd-io/etcd/blob/main/CONTRIBUTING.md#contribution-flow.

@henrybear327 henrybear327 requested a review from serathius January 3, 2026 06:35
@k8s-ci-robot
Copy link

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: henrybear327
Once this PR has been reviewed and has the lgtm label, please assign jmhbnz for approval. For more information see the 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

@henrybear327 henrybear327 self-assigned this Jan 3, 2026
@henrybear327 henrybear327 changed the title robustness: implement RunWatchLoop for kubernetes traffic [Robustness test] Implement RunWatchLoop for kubernetes traffic Jan 3, 2026
@codecov
Copy link

codecov bot commented Jan 3, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 68.44%. Comparing base (142c534) to head (4e2e557).

Additional details and impacted files

see 18 files with indirect coverage changes

@@            Coverage Diff             @@
##             main   #21076      +/-   ##
==========================================
- Coverage   68.46%   68.44%   -0.03%     
==========================================
  Files         429      429              
  Lines       35242    35242              
==========================================
- Hits        24130    24120      -10     
- Misses       9723     9735      +12     
+ Partials     1389     1387       -2     

Continue to review full report in Codecov by Sentry.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 142c534...4e2e557. Read the comment docs.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@henrybear327 henrybear327 changed the title [Robustness test] Implement RunWatchLoop for kubernetes traffic [Robustness test] Implement RunWatchLoop for kubernetes traffic (part 3) Jan 3, 2026
@henrybear327 henrybear327 force-pushed the robustness/watch-refactor-pr2-kubernetes branch 7 times, most recently from 323812d to 39f0369 Compare January 4, 2026 07:25
@henrybear327 henrybear327 changed the title [Robustness test] Implement RunWatchLoop for kubernetes traffic (part 3) [Robustness test] Implement RunWatchLoop for kubernetes traffic (part 4) Jan 4, 2026
@henrybear327 henrybear327 force-pushed the robustness/watch-refactor-pr2-kubernetes branch from 39f0369 to 14a04c4 Compare January 6, 2026 07:33
@henrybear327 henrybear327 changed the title [Robustness test] Implement RunWatchLoop for kubernetes traffic (part 4) [Robustness test] Implement RunWatchLoop for kubernetes traffic (part 3) Jan 6, 2026
@henrybear327 henrybear327 force-pushed the robustness/watch-refactor-pr2-kubernetes branch from 14a04c4 to dd8fd43 Compare January 7, 2026 02:13
@henrybear327 henrybear327 marked this pull request as draft January 7, 2026 02:15
@henrybear327 henrybear327 force-pushed the robustness/watch-refactor-pr2-kubernetes branch 5 times, most recently from 2ae113d to 79a420e Compare January 13, 2026 18:39
@henrybear327 henrybear327 marked this pull request as ready for review January 13, 2026 18:42
@henrybear327 henrybear327 marked this pull request as draft January 13, 2026 18:52
@henrybear327 henrybear327 force-pushed the robustness/watch-refactor-pr2-kubernetes branch from 79a420e to c4ec9fa Compare January 14, 2026 12:49
@henrybear327 henrybear327 force-pushed the robustness/watch-refactor-pr2-kubernetes branch from c4ec9fa to af5f435 Compare January 14, 2026 12:51
@henrybear327 henrybear327 marked this pull request as ready for review January 14, 2026 12:52
@henrybear327
Copy link
Contributor Author

Moving it out of the draft state to fix the CI error. Will ping @serathius when the PR is ready for a review pass!

@serathius
Copy link
Member

Please fix tests

@henrybear327
Copy link
Contributor Author

/retest

@henrybear327 henrybear327 force-pushed the robustness/watch-refactor-pr2-kubernetes branch from 2a58fff to af5f435 Compare January 15, 2026 10:00
@henrybear327 henrybear327 force-pushed the robustness/watch-refactor-pr2-kubernetes branch from b40b98b to 08bbf4d Compare January 15, 2026 14:47
@henrybear327 henrybear327 force-pushed the robustness/watch-refactor-pr2-kubernetes branch from 08bbf4d to 41de3b0 Compare January 15, 2026 15:41
@henrybear327 henrybear327 force-pushed the robustness/watch-refactor-pr2-kubernetes branch from 41de3b0 to 7cd2844 Compare January 15, 2026 15:57
Root cause: `RunWatchLoop()` spawned detached goroutines that were not
tracked by the main `sync.WaitGroup`.

When the parent `SimulateTraffic` is about to exit and calls
`wg.Done()`, it will unblocked immediately, allowing Reports() to read
from the history while detached goroutines were still writing to it
since not all of them have been terminated.

Signed-off-by: Chun-Hung Tseng <[email protected]>
Signed-off-by: Marek Siarkowicz <[email protected]>
Signed-off-by: Chun-Hung Tseng <[email protected]>
@serathius
Copy link
Member

Does this need to depend on #21139 ?

@henrybear327 henrybear327 force-pushed the robustness/watch-refactor-pr2-kubernetes branch from 7cd2844 to 4e2e557 Compare January 15, 2026 16:32
@henrybear327
Copy link
Contributor Author

Does this need to depend on #21139 ?

actually yes, because of the RunWatchLoop would need to use the WaitGroup field, too. Please see https://github.com/etcd-io/etcd/pull/21076/changes#diff-d4d457da0a9114653db44aafe71d7888c5b0f7b7fce4a5d146c48783e14dc1bcR152

@k8s-ci-robot
Copy link

k8s-ci-robot commented Jan 15, 2026

@henrybear327: 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
pull-etcd-robustness-amd64 4e2e557 link true /test pull-etcd-robustness-amd64
pull-etcd-robustness-arm64 4e2e557 link true /test pull-etcd-robustness-arm64

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.

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

Development

Successfully merging this pull request may close these issues.

3 participants