Build Trigger Condition Module


Bamboo 3.0 and later

On this page:


The buildTriggerCondition module provides the ability to gate whether a build should be triggered or not. It uses a preference system so multiple trigger condition plugins can be used to determine the desired result. A build which fails the trigger condition will not be executed, there will be no trace of the existence of this build.

The following ExecutionPreferences are available (in order of priority - highest first)

  • NONE

SHOULD_RUN is the default used by Bamboo. Please carefully consider which preference you use, to allow for better integration with future plugins. For example you could have

  • Plugin A: Only will build if another build is green, will return SHOULD_STOP as its preference (if the other build is red)
  • Plugin B: Ensures that there is always a build once a day so can over-ride Plugin A by return MUST_RUN
  • Plugin C: Checks for resource availability and therefore can return MUST_STOP when a resource is not available, and override any other plugins which might want the plan to run.


Build Trigger Condition modules must implement the interface.

Sample Module Descriptor Element

 <buildTriggerCondition key="plansGreenCondition" name="Plans Green Condition"
    <description>Checks that a given list of plans is green before triggering a build.</description>
    <resource type="freemarker" name="edit" location="editPlansGreenCondition.ftl"/>
    <resource type="freemarker" name="view" location="viewPlansGreenCondition.ftl"/>
Was this page helpful?

Have a question about this article?

See questions about this article

Powered by Confluence and Scroll Viewport