Repository navigation
perf(server): run batches of different installations at once - #185
Merged
Merged
Conversation
The server ran one installation's batch at a time behind a single engine lock, though each installation has its own rate limits. `server.workers` (4 by default, read at start) queue workers now claim batches side by side: `claim_batch` skips an installation whose batch is still running, and each installation's engine has its own lock, so a remote run waits only for its own installation.
The first worker error dropped the JoinSet and cancelled every other installation's batch mid-run. A stop or a failure now halts the workers once their current batches finish, and the first failure is returned. Report file names carry a counter, so two batches that finish in the same instant cannot collide.
This was referenced Nov 4, 2026
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.
Finding #5 from the speed survey.
patchula servehad one worker and one engine lock, so installations waited in one queue even though each has its own GitHub rate limits.server.workerssetting (default 4, 1 to 64, read at start): that many queue workers claim batches side by side.claim_batchnever claims an installation whose earlier batch is still running, so each installation still runs one batch at a time.Slot); the map lock is held only to find the slot. A remote run takes its installation's lock, so it still never races that installation's queued batch.workers.Test: a running installation is skipped while another is claimed, and its queued work is claimed once it finishes.