Just a heads up: On March 24, 2025, starting at 4:30pm CDT / 19:30 UTC, the site will be undergoing scheduled maintenance for a few hours. During this time, the site might be unavailable for a short while. Thanks for your patience.

×
Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

Override Concurrent Build Setting At Stage or Job Level

Peter Kahn
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
March 12, 2013

Hi all,

Is it possible to set a plan to allow concurrent exexecution of stages or jobs?

I have a changeset build process (like a gated checkin build but we build after the checkin). At present, we use a bunch of scripts and three plans:

- Process queue for next changeset

- Run Build

- Finalize Results

I'd like to setup one plan and manage the rest inside it. I believe I can only set concurrent build limits at the plan level so I'll need to set this up as follows:

- Process-queue-plan manages incoming queue of changeset to run and starts Run-Build-Plan (concurrent limit = 1)

- Run-Build-Plan builds specific revision in JOB1 and then finalizes in JOB2 (concurrent limit = many)

Please let me know if I'm right in my understanding that concurrency is per plan and not per start or job.

Thanks

Peter

1 answer

0 votes
Marcin Gardias
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
April 4, 2013

It's true that concurrency limit is per plan, but it doesn't mean you can't achieve what you want ;-)

If I understand correctly "Process queue for next changeset" does sth like the following:

- check if there are new commits in source repo(s) (and this needs to be one-at-a-time thing)

- spawn a process that will run 2 build steps. (there can be many of those processes)

Here's the thing: this is exactly what Bamboo can do for you.

Set up a plan, configure "Repository polling"* automatic trigger and add your 2 stages to the plan**. Set up concurrency limit to whatever you want. Done.

Internally, the triggering build logic uses an exclusive lock, so even though Jobs will run in paraller, only one 'triggering process' will run at a time, regardless of concurrency setting.

*) there are other options too ;-)

**) Actually your 2 build scripts might be better mapped to single Bamboo Job with many Tasks rather to 2 Stages, depending on how your scripts interact. For example: are they supposed to run in the same dir? If so, Tasks are better choice. More on this: https://confluence.atlassian.com/display/BAMBOO/Using+stages+in+a+plan

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events