Repository navigation
Track app-server running turns incrementally - #49084
Merged
copyberry[bot] merged 1 commit intoSep 28, 2026
Merged
copyberry[bot] merged 1 commit into
copyberry[bot] merged 1 commit into
Conversation
## Why Every thread state mutation scanned all tracked runtimes to recount running turns while holding the state lock. This count supports graceful restart draining introduced in #12517. ## What changed Maintain `running_turn_count` in `ThreadWatchState`, adjusting it when a runtime's `running` flag changes or a running thread is removed. Publish the cached count while preserving notifications only when the count changes. ## Testing Extend the running-turn watch test to cover duplicate starts, two simultaneous running threads, and removal of a running thread, with counts checked against the runtime map. GitOrigin-RevId: e7d7ebb33b9ff4d24dc70d8f01ae981378fed5f8
copyberry
Bot
force-pushed
the
copyberry/codex-internal-to-codex-oss/e7d7ebb33b9ff4d24dc70d8f01ae981378fed5f8
branch
from
September 28, 2026 21:33
86bad91 to
88e9a83
Compare
copyberry
Bot
deleted the
copyberry/codex-internal-to-codex-oss/e7d7ebb33b9ff4d24dc70d8f01ae981378fed5f8
branch
September 28, 2026 21:33
Damanotra
temporarily deployed
to
issue-triage
September 28, 2026 22:07 — with
GitHub Actions
Inactive
Damanotra
temporarily deployed
to
issue-triage
September 28, 2026 22:07 — with
GitHub Actions
Inactive
Damanotra
temporarily deployed
to
issue-triage
September 28, 2026 22:07 — with
GitHub Actions
Inactive
Damanotra
temporarily deployed
to
issue-triage
September 28, 2026 22:08 — with
GitHub Actions
Inactive
the-spiral-alchemist
temporarily deployed
to
issue-triage
September 28, 2026 22:18 — with
GitHub Actions
Inactive
the-spiral-alchemist
temporarily deployed
to
issue-triage
September 28, 2026 22:18 — with
GitHub Actions
Inactive
the-spiral-alchemist
temporarily deployed
to
issue-triage
September 28, 2026 22:18 — with
GitHub Actions
Inactive
bvolpato
temporarily deployed
to
issue-triage
September 28, 2026 22:19 — with
GitHub Actions
Inactive
bvolpato
temporarily deployed
to
issue-triage
September 28, 2026 22:19 — with
GitHub Actions
Inactive
bvolpato
temporarily deployed
to
issue-triage
September 28, 2026 22:19 — with
GitHub Actions
Inactive
the-spiral-alchemist
temporarily deployed
to
issue-triage
September 28, 2026 22:20 — with
GitHub Actions
Inactive
This branch was previously deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Track app-server running turns incrementally
Why
Every thread state mutation scanned all tracked runtimes to recount running turns while holding the state lock. This count supports graceful restart draining introduced in #12517.
What changed
Maintain
running_turn_countinThreadWatchState, adjusting it when a runtime'srunningflag changes or a running thread is removed. Publish the cached count while preserving notifications only when the count changes.Testing
Extend the running-turn watch test to cover duplicate starts, two simultaneous running threads, and removal of a running thread, with counts checked against the runtime map.