Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Some use cases have a need to only queue a build if certain conditions are met. This describes the support provided in this area. It is based on querying previous build results to see if there already exists a build that satisfies the conditions. If so, a new build is not required and so will not be queued. This uses the same filtering criteria used in getBuildList.  If getBuildLIst returns at least 1 build matching the filtering conditions, then the build will not be queued as there is an existing build matching the criteria.

The support has been implemented to be expanded in the future as more use cases are identified. Open an issue if you have a new use case.

...

Table plus


FieldFromDescriptionExamples
statebuild resultCompare the state of a build result to the requested value.
--field1field state=SUCCESSFUL 

notState

build resultCompare the state of a build result not being the requested value.
--value SUCCESSFUL field notState=UNKNOWN
startedbuild resultCompare the started date of a build result to the requested value.
--field "started = 2016--field2 started --value204-30" --dateFormat yyyy-MM-dd"
--field "started = ${bamboo.planKey}"
endedBeforebuild resultCompare the ended date of a build result to the requested value.
--field "endedBefore = 2016-04-30" --dateFormat yyyy-MM-dd


Special Values

If you provide a plan or build key for the value of the started or endedBefore field, we will automatically convert that into start or completion (respectively) date of the referenced build (defaulted to latest if not explicitly stated). A good use case is using ${bamboo.planKey} to compare to latest build for a plan where you are running the queueBuild action from.