Exclude Bamboo agents from running plans

I'd like to setup a couple of my remote Bamboo agents to exclusively run a particular plan and not be available for any of my other plans. So for example if I have 10 remote agents set up with phpunit then any plan that requires phpunit sees all these 10 agents as potentially available to run on. But I want to set aside 2 of my remote agents to be sort of unavailable to run phpunit type plans unless the plan being executed is specifically "My Important Integration Plan".

I know you can set a required custom variable like "agent_name" should equal "bamboo.agent.8". But this only makes it so that "My Important Integration Plan" now only runs on bamboo.agent.8, but it doesn't prevent any of the other plans from still using bamboo.agent.8". Besides I want "My Important Integration Plan" to run on either bamboo.agent.8 or bamboo.agent.9.

Is there a way I can exclude certain agents from certain plans?

4 answers

1 accepted

Accepted Answer
0 votes

Thanks Przemek. Looks like the plugin "Group Agent" might solve this for me: https://marketplace.atlassian.com/plugins/com.edwardawebb.bamboo-group-agent

0 votes

You'd have to:

  1. add a capability to all agents except for 8/9 and make all plans except for Integration Plan require it, and
  2. Add a requirement to Integration Plan that is only met on agents 8/9

There'll be a better way of doing this with Bamboo 5 (not sure if the UI for this will be exposed, but it will be doable).

How can this be done with Bamboo 5? I've been trialling it and it's a feature I think is sorely missing. The plugin linked in the other comment isn't supported for Bamboo 5.

This capability is really important to our company as we begin to roll out Bamboo to our enterprise. I was looking through the latest APIs and noticed I can add a BuildAgentRequirementFilter to Bamboo via plugin. The API has a strong warning that this is for internal use only and writing these incorrectly can severly impact Bamboo's operation.

Taking that warning in stride:

  1. Is this the mechanism referred to above?
  2. Is there any guidance on writing these?

In some ad-hoc experimentation with this API on a dev instance, I noticed that I can return an empty collection of agents from this filter but the plan is still queued on the default agent -- doesn't run, but blocks the queue from other plans running. I can return a null collection which results in a stack trace in the log, but the plan is not queued. What is the proper way to implement such a filter or is there an alternative API to restrict which plans can run on a given agent?

Thanks!

Unfortunately the Group Agent Plugin isn't available for Bamboo 5.x, is there an alternative?

What's the status of this feature?

Suggest an answer

Log in or Sign up to answer
Community showcase
Published Monday in Jira Ops

Jira Ops Early Access Program Update #1: Announcing our next feature and a new integration

Thanks for signing up for Jira Ops! I’m Matt Ryall, leader for the Jira Ops product team at Atlassian. Since this is a brand new product, we’ll be delivering improvements quickly and sharing updates...

537 views 0 9
Read article

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you