Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix: reduce “Waiting on concurrency group” #8

Merged
merged 3 commits into from
Sep 1, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions pipeline.go
Original file line number Diff line number Diff line change
Expand Up @@ -230,6 +230,9 @@ func lowerStep(step Step, context *Context, stepContext *StepContext) (Step, err
step["concurrency"] == nil && step["concurrency_group"] == nil {
step["concurrency_group"] = fmt.Sprintf("%s/%s", stepContext.EnvironmentName, context.BuildkitePipelineSlug)
step["concurrency"] = 1
if step["concurrency_method"] == nil {
step["concurrency_method"] = "eager"
}
}

return step, nil
Expand Down
4 changes: 4 additions & 0 deletions testdata/basic_master.out.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ steps:
command: deploy
concurrency: 1
concurrency_group: dev/myrepo
concurrency_method: eager
env:
ENVIRONMENT: dev
JOBSWORTH_CAUTIOUS: "0"
Expand Down Expand Up @@ -60,6 +61,7 @@ steps:
command: integrationtest
concurrency: 1
concurrency_group: dev/myrepo
concurrency_method: eager
env:
JOBSWORTH_CAUTIOUS: "0"
JOBSWORTH_CODE_VERSION: ""
Expand All @@ -74,6 +76,7 @@ steps:
command: deploy
concurrency: 1
concurrency_group: prod/myrepo
concurrency_method: eager
env:
ENVIRONMENT: prod
JOBSWORTH_CAUTIOUS: "1"
Expand Down Expand Up @@ -104,6 +107,7 @@ steps:
command: integrationtest
concurrency: 1
concurrency_group: prod/myrepo
concurrency_method: eager
env:
JOBSWORTH_CAUTIOUS: "0"
JOBSWORTH_CODE_VERSION: ""
Expand Down