Push selected functions in parallel - #1801
Merged
Merged
Conversation
Contributor
Greptile SummaryThis PR makes multi-function pushes concurrent while preserving sequential behavior for sites and single-function pushes.
Confidence Score: 5/5The PR appears safe to merge. No blocking failure remains; the previously unbounded deployment worker count is now capped at four and covered by a concurrency-limit regression test. Important Files Changed
Reviews (2): Last reviewed commit: "address greptile review feedback (greplo..." | Re-trigger Greptile |
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.
Closes #1794.
Summary
Implementation
The function push now sends every selected entry through the parallel worker while keeping sites and single-function pushes on the existing sequential path:
A four-worker pool bounds nested packaging and chunk-upload pressure. Each entry owns a summary, and results are merged in config order after all deployments finish:
Concurrent output is serialized. Hiding the underlying terminal also makes multi-function pushes use plain progress lines instead of multiple spinners redrawing the same row:
Production verification
Built
examples/cli/appwriteand pushed two disposable Node functions toMain Projectin the SGP production region. The output shows both function pushes and deployment requests in flight together:The API recorded both deployments in the same second:
Both deployments reached
ready. Both executions completed with HTTP 200 and returned their expected JSON responses:{"function":"e2e-1794-first-221334","ok":true} {"function":"e2e-1794-second-221334","ok":true}The test functions and their proxy rules were deleted afterward.
Test plan
php example.php clicd examples/cli && go mod tidy && go build ./... && go vet ./... && go test ./...cd examples/cli && go test -race ./internal/cmd ./internal/outputvendor/bin/phpunit tests/e2e/CLIGo126Test.phpcomposer lint-twigcomposer refactor:check