Package com.atlassian.bamboo.plan
Class PlanExecutionLaunchControlImpl
java.lang.Object
com.atlassian.bamboo.plan.PlanExecutionLaunchControlImpl
- All Implemented Interfaces:
PlanExecutionLaunchControl
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionprotected static classprotected static classprotected static classprotected classManages the release of locks associated with repository cache keys.Nested classes/interfaces inherited from interface com.atlassian.bamboo.plan.PlanExecutionLaunchControl
PlanExecutionLaunchControl.ReleaseLocksActions -
Field Summary
Fields inherited from interface com.atlassian.bamboo.plan.PlanExecutionLaunchControl
NO_OP_RELEASE_LOCKS_ACTION -
Constructor Summary
ConstructorsConstructorDescriptionPlanExecutionLaunchControlImpl(GitConfigurationProvider gitConfigurationProvider, CustomVariableContext customVariableContext) -
Method Summary
Modifier and TypeMethodDescriptionvoidclear()Clears the whole internal state of the launch control object by removing the tracking of currently acquired locks.createReleaseLocksObject(@NotNull Map<Long, String> idsToCacheKeysMapping) protected voidreleaseLock(@NotNull String cacheKey) voidschedule(@NotNull TriggerableInternalKey triggerableInternalKey, @Nullable BuildDetectionAction buildDetectionAction, @NotNull Consumer<PlanExecutionLaunchControl.ReleaseLocksActions> runnableBody) Scheduling theTriggerableInternalKeyto execute.protected booleanshouldBeRunImmediately(@Nullable BuildDetectionAction buildDetectionAction)
-
Constructor Details
-
PlanExecutionLaunchControlImpl
@Inject public PlanExecutionLaunchControlImpl(GitConfigurationProvider gitConfigurationProvider, CustomVariableContext customVariableContext)
-
-
Method Details
-
schedule
public void schedule(@NotNull @NotNull TriggerableInternalKey triggerableInternalKey, @Nullable @Nullable BuildDetectionAction buildDetectionAction, @NotNull @NotNull Consumer<PlanExecutionLaunchControl.ReleaseLocksActions> runnableBody) Description copied from interface:PlanExecutionLaunchControlScheduling theTriggerableInternalKeyto execute. The launch control will execute the request once it is the most effective. All scheduled actions will be eventually executed.- Specified by:
schedulein interfacePlanExecutionLaunchControl- Parameters:
triggerableInternalKey- key of the triggerable that asked for executionbuildDetectionAction- action in which context the execution will be maderunnableBody- the side effect that will be executed once the launch control decides it is the best time to do so
-
clear
public void clear()Description copied from interface:PlanExecutionLaunchControlClears the whole internal state of the launch control object by removing the tracking of currently acquired locks.- Specified by:
clearin interfacePlanExecutionLaunchControl
-
releaseLock
-
shouldBeRunImmediately
protected boolean shouldBeRunImmediately(@Nullable @Nullable BuildDetectionAction buildDetectionAction) -
createReleaseLocksObject
protected PlanExecutionLaunchControl.ReleaseLocksActions createReleaseLocksObject(@NotNull @NotNull Map<Long, String> idsToCacheKeysMapping)
-