perf: optimize high-concurrency Docker orchestration - #3109
Merged
Conversation
numnx
marked this pull request as ready for review
July 14, 2026 03:43
Merged
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 join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
What changed
Why
Under concurrent provider and CI workloads, the runtime amplified host pressure through repeated Docker inventory/inspection commands, full transcript rereads and reparses, recurring SQLite rewrites, per-launch cache verification, serial dispatch, repeated short-lived Git helpers, and startup-time database maintenance. Concurrent CI-fix and task-merge publishers could also race on the same feature ref. These changes make warm launch work proportional to new data, keep independent work parallel, stop background maintenance from competing with active providers, and prevent a late writer from discarding already-published task history.
User and developer impact
Validation
pnpm run cipnpm run test:e2e: 67/67 Playwright tests passed in 3.6 minutesgit diff --checkpassed after the publication hardeningRisk and rollback
The main risk is scheduling/admission behavior under host-specific pressure and one-time deferred migration/index convergence. SQLite remains the atomic claim authority, unique correctness indexes stay synchronous, maintenance is skipped while providers run, and destructive Docker recovery requires a fresh inventory. Feature-ref publication uses bounded compare-and-swap retries rather than a global branch lock. Revert this PR to restore the previous orchestration behavior.