|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.atlassian.bamboo.plan.branch.BranchDetectionServiceImpl
public class BranchDetectionServiceImpl
Constructor Summary | |
---|---|
BranchDetectionServiceImpl(PlanManager planManager,
ChainBranchCreationService chainBranchCreationService,
RepositoryManager repositoryManager,
VcsBranchManager vcsBranchManager,
RepositoryCachingFacade repositoryCachingFacade,
ErrorHandler errorHandler,
ScopedExclusionService scopedExclusionService,
com.atlassian.event.api.EventPublisher eventPublisher,
JiraBranchLinkingService jiraBranchLinkingService,
VariableDefinitionManager variableDefinitionManager,
CustomVariableContext customVariableContext,
org.springframework.orm.hibernate3.HibernateTemplate hibernateTemplate,
CachedPlanManager cachedPlanManager,
com.atlassian.struts.TextProvider textProvider,
ChainBranchManager chainBranchManager)
|
Method Summary | |
---|---|
PlanKey |
createChainBranch(ImmutableChain chain,
String branchName,
VcsBranch vcsBranch,
BuildConfiguration buildConfiguration,
PlanCreationService.EnablePlan enablePlan,
boolean enableExpiry)
Given a branch name and (optionally) vcs branch name, create Plan Branches with overriding repository definitions. |
PlanKey |
createChainBranch(ImmutableChain chain,
String branchName,
VcsBranch vcsBranch,
PlanCreationService.EnablePlan enablePlan,
boolean enableExpiry)
Given a branch name and (optionally) vcs branch name, create Plan Branches with overriding repository definitions. |
protected void |
createNewBranchesForChainNoLock(ImmutableChain chain,
RepositoryDefinition defaultRepositoryDefinition)
|
Collection<PlanKey> |
createPlanBranches(ImmutableChain chain,
Collection<VcsBranch> branches,
ErrorCollection errorCollection)
Given a list of branch names, create Plan Branches for these, with overriding repository definitions. |
Collection<PlanKey> |
createPlanBranches(ImmutableChain chain,
Collection<VcsBranch> branches,
ErrorCollection errorCollection,
PlanCreationService.EnablePlan enablePlan)
Given a list of branch names, create Plan Branches for these, with overriding repository definitions. |
void |
deleteBambooVcsBranch(Iterable<ImmutableChain> chains,
String branchName)
Deletes vcs branch from table |
void |
detectBranchesForChain(ImmutableChain chain)
Immediately executes the detection for a given Chain and creates new plan branches if new branches found in the plan's default repository. |
void |
disableChainBranch(Iterable<ImmutableChain> chains)
Disables bamboo branches from given chain branches (or chains if it's default branch). |
List<VcsBranch> |
getOpenBranches(ImmutableChain chain,
ErrorCollection errorCollection)
Returns a list of currently open branches for the chain's default repository List ordering determined by underlying repository (preference is for native ordering e.g. |
boolean |
scheduleBranchDetectionForChain(ImmutableChain chain)
Registers branch detection request for a given Chain. |
boolean |
scheduleBranchListInitialisation(Chain chain)
Schedules initialisation of existing vcs branch list. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public BranchDetectionServiceImpl(PlanManager planManager, ChainBranchCreationService chainBranchCreationService, RepositoryManager repositoryManager, VcsBranchManager vcsBranchManager, RepositoryCachingFacade repositoryCachingFacade, ErrorHandler errorHandler, ScopedExclusionService scopedExclusionService, com.atlassian.event.api.EventPublisher eventPublisher, JiraBranchLinkingService jiraBranchLinkingService, VariableDefinitionManager variableDefinitionManager, CustomVariableContext customVariableContext, org.springframework.orm.hibernate3.HibernateTemplate hibernateTemplate, CachedPlanManager cachedPlanManager, com.atlassian.struts.TextProvider textProvider, ChainBranchManager chainBranchManager)
Method Detail |
---|
public boolean scheduleBranchListInitialisation(@NotNull Chain chain)
BranchDetectionService
scheduleBranchListInitialisation
in interface BranchDetectionService
public boolean scheduleBranchDetectionForChain(@NotNull ImmutableChain chain)
BranchDetectionService
scheduleBranchDetectionForChain
in interface BranchDetectionService
public void detectBranchesForChain(@NotNull ImmutableChain chain)
BranchDetectionService
detectBranchesForChain
in interface BranchDetectionService
protected void createNewBranchesForChainNoLock(@NotNull ImmutableChain chain, @NotNull RepositoryDefinition defaultRepositoryDefinition)
@NotNull public Collection<PlanKey> createPlanBranches(@NotNull ImmutableChain chain, @NotNull Collection<VcsBranch> branches, @Nullable ErrorCollection errorCollection)
BranchDetectionService
createPlanBranches
in interface BranchDetectionService
chain
- to create branches underbranches
- to create.errorCollection
- - to add errors to, if you don't supply an error collection, they will just get logged.
@NotNull public Collection<PlanKey> createPlanBranches(@NotNull ImmutableChain chain, @NotNull Collection<VcsBranch> branches, @Nullable ErrorCollection errorCollection, PlanCreationService.EnablePlan enablePlan)
BranchDetectionService
createPlanBranches
in interface BranchDetectionService
chain
- to create branches underbranches
- to create.errorCollection
- - to add errors to, if you don't supply an error collection, they will just get logged.enablePlan
- - defines whether newly created branches should be enabled or disabled after creation
@Nullable public List<VcsBranch> getOpenBranches(@NotNull ImmutableChain chain, ErrorCollection errorCollection)
BranchDetectionService
getOpenBranches
in interface BranchDetectionService
chain
- to find branches for.errorCollection
- to add any errors to during detection
public PlanKey createChainBranch(@NotNull ImmutableChain chain, @NotNull String branchName, @Nullable VcsBranch vcsBranch, PlanCreationService.EnablePlan enablePlan, boolean enableExpiry) throws PlanCreationDeniedException
BranchDetectionService
createChainBranch
in interface BranchDetectionService
chain
- to create branches underbranchName
- to create.vcsBranch
- to use when overriding repository definition.enablePlan
- - defines whether newly created branches should be enabled or disabled after creationenableExpiry
- - defines whether created branch can be removed due to branch expiration detection
PlanCreationDeniedException
public PlanKey createChainBranch(@NotNull ImmutableChain chain, @NotNull String branchName, @Nullable VcsBranch vcsBranch, @Nullable BuildConfiguration buildConfiguration, PlanCreationService.EnablePlan enablePlan, boolean enableExpiry) throws PlanCreationDeniedException
BranchDetectionService
createChainBranch
in interface BranchDetectionService
chain
- to create branches underbranchName
- to create.vcsBranch
- to use when overriding repository definition.buildConfiguration
- - a default fragment of configuration to create the chain branch withenablePlan
- - defines whether newly created branches should be enabled or disabled after creationenableExpiry
- - defines whether created branch can be removed due to branch expiration detection
PlanCreationDeniedException
public void deleteBambooVcsBranch(@NotNull Iterable<ImmutableChain> chains, @NotNull String branchName)
BranchDetectionService
deleteBambooVcsBranch
in interface BranchDetectionService
chains
- collection of chains/chain branches to search throughbranchName
- vcs branch name that was removedpublic void disableChainBranch(@NotNull Iterable<ImmutableChain> chains)
BranchDetectionService
SystemProperty.DISABLE_CLOSED_BRANCH_DETECTION
property is enabled.
disableChainBranch
in interface BranchDetectionService
chains
- collection of chains/chain branches that should be disabled
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |