Skip to content

fix(roadmap): a stop of the Service is not a failed round - #2756

Merged
dan-petty merged 7 commits into
mainfrom
fix/2753-shutdown-not-failure
Oct 30, 2026
Merged

dan-petty merged 7 commits into
mainfrom
fix/2753-shutdown-not-failure

Conversation

@dan-petty

Copy link
Copy Markdown
Owner

A roll-out of the Service stops its request budget. A request that the stopped budget refuses now raises ServiceStoppingError. A round that this error ends is not a failed round: it leaves the count of its job as it was. Before, three roll-outs in a row could suspend a job that had no fault.

  • ended_by_stop reads the error, an exception group, and the __cause__ chain. A group that holds a real failure is a failure.
  • The log line that suspends a job names the cause of each of the failed rounds.
  • service-failures.json keeps its format, so a rollback to the running version still starts. A round that an earlier process counted has the cause unknown.
  • The stage job and the refine job end the run at a stop. Items that failed for a real reason before the stop still fail the round, so a stop does not hide a recurring failure.
  • k8s/README.md and the roadmap-service-limits spec say how a stop counts.

The comment of a person on an item of a suspended row does not start the row again. That is the follow-up #2754.

Closes #2753

The request budget raises ServiceStoppingError when the Service is stopping. A round that ends with it leaves the count of its job as it was, so releases and rollouts no longer suspend a row. The stage job lets the error pass. The ledger keeps the cause of each failed round in memory, and the line that suspends a job names the causes. service-failures.json keeps its format.
The tests no longer name the new class at import, so they fail in the call phase on the base.
…nd (#2753)

A stop in the write phase of the stage or refine job threw away the items that failed for a real reason in the same round, so the round counted as no failure. The jobs now fail the round with those items first.
@dan-petty

Copy link
Copy Markdown
Owner Author

Test results and review notes.

Review findings fixed:

  • Major (ledger): a stop in the write phase of the stage job threw away the items that failed for a real reason, in the plan or in an earlier write. apply_stage and the refine adapter now call raise_for_failed (raise_for_failed_items) first, so the round counts. New tests cover a stop after a failed write, a stop after a failure of the plan, and the same in the refine job.

Review findings not fixed:

  • Minor (spec): the causes of failed rounds live in memory, so rounds that an earlier process counted read unknown. Declined. A second state file adds a record to keep and to read for a log line (see the design, Rejected alternatives). A stop no longer counts, so a restart by itself adds no counted round. The limit is in the design.
  • Refine loses the count of items it set Ready in a round that a stop ends. The next round reads the items again, so no state is lost.

@dan-petty
dan-petty marked this pull request as ready for review October 30, 2026 03:55
@dan-petty
dan-petty merged commit 0b7e190 into main Oct 30, 2026
18 checks passed
@dan-petty
dan-petty deleted the fix/2753-shutdown-not-failure branch October 30, 2026 08:20
dan-petty pushed a commit that referenced this pull request Oct 30, 2026
🤖 I have created a release *beep* *boop*
---


##
[0.22.1](v0.22.0...v0.22.1)
(2026-10-30)


### Bug Fixes

* **github:** ask no traffic endpoint as the App
([#2759](#2759))
([692c15f](692c15f)),
closes [#2752](#2752)
* **roadmap:** a stop of the Service is not a failed round
([#2756](#2756))
([0b7e190](0b7e190)),
closes [#2753](#2753)
* **roadmap:** say why an implement step stopped
([#2762](#2762))
([cd56ce4](cd56ce4)),
closes [#2758](#2758)
* **service:** render and alert on the hourly request budget
([#2760](#2760))
([809d85b](809d85b)),
closes [#2755](#2755)
* **service:** run the implement row on the status lane
([#2763](#2763))
([cd94f2c](cd94f2c)),
closes [#2757](#2757)


### Performance Improvements

* **ci:** cut test job time and guard its mean
([#2764](#2764))
([e76f656](e76f656)),
closes [#2699](#2699)

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).

Co-authored-by: dan-petty-release[bot] <346998822+dan-petty-release[bot]@users.noreply.github.com>
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.

fix(service): a round that ends because the Service is stopping counts as a failure and three of them suspend a row

1 participant