Skip to content

Fix the flaky overload check in bin/conformance and the devcell tests - #68

Merged
flavorjones merged 1 commit into
masterfrom
overload-flake-547
Sep 28, 2026
Merged

flavorjones merged 1 commit into
masterfrom
overload-flake-547

Conversation

@flavorjones

@flavorjones flavorjones commented Sep 28, 2026 •

Copy link
Copy Markdown
Member

Motivation

The battery (examples/lib/battery.rb) is the list of checks that rake test:devcell and bin/conformance run against a live cell. Its overload check fills every worker and every queue place with 2-second sleep requests, then sends another request and expects the cell to refuse it with capacity.

On ruby head, this check failed intermittently in CI. The cell refused some of the sleep requests as well, so it never filled, and the check gave up. An operator running bin/conformance against a healthy image could see the same failure.

The supervisor counts a worker as busy until the worker reports idle. The worker reports idle only after it has answered its caller and cleaned up (worker.rb). In the failing runs, the worker that served the previous check was still cleaning up when the overload check started. The cell refused a sleep request because that place was taken. The place freed a moment later, and the cell stayed a place short of full.

Fixes #66

Details

  • The overload check waits for the cell's metrics to report nothing running or queued before it sends the sleep requests.
  • examples/gate runs the overload check against a fake cell that holds a leftover request from an earlier check. Without the wait, the check fails the same way it did in CI.
  • Only the battery changes, so bin/conformance and the devcell tests are affected. The cell's behavior is unchanged.

Copilot AI balanced review requested due to automatic review settings September 28, 2026 19:00

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@flavorjones flavorjones changed the title Wait for an empty cell before the overload check Fix a flaky test: the devcell overload check Sep 28, 2026
@flavorjones
flavorjones force-pushed the overload-flake-547 branch 2 times, most recently from e52abbb to 2f3c0b0 Compare September 28, 2026 19:16
@flavorjones flavorjones changed the title Fix a flaky test: the devcell overload check Fix the flaky overload check in bin/conformance and the devcell tests Sep 28, 2026
The battery is the list of checks that `bin/conformance` and `rake
test:devcell` run against a live cell. Its overload check fills every
worker and queue place with sleep requests, then expects another request
to be refused with `capacity`. It failed intermittently against a
healthy cell: the worker that served the previous check was still
cleaning up and held its place, so the cell refused a sleep request and
never filled.

Wait for the cell to report nothing running or queued before filling it.

[Fix #66]
@flavorjones
flavorjones merged commit d467bbc into master Sep 28, 2026
16 checks passed
@flavorjones
flavorjones deleted the overload-flake-547 branch September 28, 2026 19:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Devcell check "offered overload answers capacity" is flaky on ruby head

2 participants