@ThreadSafe public interface BuildExecutionManager
Modifier and Type | Method and Description |
---|---|
void |
detachBuildFromAgent(long agentId)
Detaches runnin build (if any) from an agent that was assigned to it.
|
void |
execute(BuildContext buildContext)
Executes the given
BuildContext
At this point a BuildResultsSummary exists that matches the given BuildContext |
void |
finishBuild(PlanResultKey planResultKey,
boolean updateFollowingBuilds)
Calls removeCurrentlyBuilding and finishProcess
|
void |
finishBuildWithCleanState(PlanResultKey planResultKey,
BuildContext buildContext)
Calls removeCurrentlyBuilding and finishProcess.
|
CurrentlyBuilding |
getBuildRunningOnAgent(Long buildAgentId) |
List<CurrentlyBuilding> |
getCurrentlyBuilding(Key key) |
CurrentlyBuilding |
getCurrentlyBuildingByBuildResult(BuildIdentifier buildIdentifier)
Returns
CurrentlyBuilding instance for build identifier (or BuildContext ). |
CurrentlyBuilding |
getCurrentlyBuildingByPlanResultKey(ResultKey resultKey)
Returns
CurrentlyBuilding instance for build identified by buildResultKey. |
Iterable<CurrentlyBuilding> |
getCurrentlyExecuting()
Retrieves a all builds being executed (i.e not just queued).
|
Iterable<CurrentlyBuilding> |
getCurrentlyExecuting(PlanKey planKey) |
CurrentlyBuilding |
removeCurrentlyBuilding(ResultKey resultKey) |
void |
setCurrentlyBuilding(BuildContext buildContext,
Collection<BuildAgent> executableAgents,
Collection<ElasticImageConfiguration> executableImages)
Denotes that the passed build context is beginning the build process.
|
@NotNull Iterable<CurrentlyBuilding> getCurrentlyExecuting()
Iterable<CurrentlyBuilding> getCurrentlyExecuting(PlanKey planKey)
@NotNull List<CurrentlyBuilding> getCurrentlyBuilding(@NotNull Key key)
@Nullable CurrentlyBuilding removeCurrentlyBuilding(@NotNull ResultKey resultKey)
void setCurrentlyBuilding(@NotNull BuildContext buildContext, @NotNull Collection<BuildAgent> executableAgents, @NotNull Collection<ElasticImageConfiguration> executableImages)
buildContext
- -executableAgents
- - a list of agents on which this build can be run.executableImages
- - a list of images on which the build can be run.@Nullable CurrentlyBuilding getBuildRunningOnAgent(@NotNull Long buildAgentId)
void finishBuildWithCleanState(@NotNull PlanResultKey planResultKey, @NotNull BuildContext buildContext)
#finishBuild(PlanResultKey)
instead.planResultKey
- identifies plan resultvoid finishBuild(@NotNull PlanResultKey planResultKey, boolean updateFollowingBuilds)
planResultKey
- identifies plan resultupdateFollowingBuilds
- void detachBuildFromAgent(long agentId)
void execute(@NotNull BuildContext buildContext)
BuildContext
At this point a BuildResultsSummary
exists that matches the given BuildContext
buildContext
- @Nullable CurrentlyBuilding getCurrentlyBuildingByPlanResultKey(@NotNull ResultKey resultKey)
CurrentlyBuilding
instance for build identified by buildResultKey.
Should be used only if BuildIdentifier
is not available - basically in actionsresultKey
- @Nullable CurrentlyBuilding getCurrentlyBuildingByBuildResult(@NotNull BuildIdentifier buildIdentifier)
CurrentlyBuilding
instance for build identifier (or BuildContext
).buildIdentifier
- Copyright © 2021 Atlassian Software Systems Pty Ltd. All rights reserved.