public interface BranchDetectionService
| Modifier and Type | Method and Description |
|---|---|
default PlanKey |
createChainBranch(ImmutableChain chain,
PlanBranchWorkflow planBranchWorkflow,
String branchName,
VcsBranch vcsBranch,
BuildConfiguration buildConfiguration,
PlanCreationService.EnablePlan enablePlan,
boolean enableExpiry)
Given a branch name and (optionally) vcs branch name, creates a plan branch, overriding repository definition.
|
PlanKey |
createChainBranch(ImmutableChain chain,
PlanBranchWorkflow planBranchWorkflow,
String branchName,
VcsBranch vcsBranch,
BuildConfiguration buildConfiguration,
PlanCreationService.EnablePlan enablePlan,
boolean enableExpiry,
Consumer<PlanKey> planBranchConsumer)
/**
Given a branch name and (optionally) vcs branch name, creates a plan branch, overriding repository definition.
|
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 |
createOrEnableChainBranch(ImmutableChain chain,
PlanBranchWorkflow planBranchWorkflow,
VcsBranch vcsBranch,
BuildConfiguration buildConfiguration,
PlanCreationService.EnablePlan enablePlan,
boolean enableExpiry,
Consumer<PlanKey> planBranchConsumer)
Given a branch name and (optionally) vcs branch name, check if branch already exists.
|
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.
|
default Collection<PlanKey> |
createPlanBranches(ImmutableChain chain,
PlanBranchWorkflow planBranchWorkflow,
Collection<VcsBranch> branches,
ErrorCollection errorCollection,
PlanCreationService.EnablePlan enablePlan)
Given a list of branch names, create plan branches for these, with overriding repository definitions.
|
Collection<PlanKey> |
createPlanBranches(ImmutableChain chain,
PlanBranchWorkflow planBranchWorkflow,
Collection<VcsBranch> branches,
ErrorCollection errorCollection,
PlanCreationService.EnablePlan enablePlan,
Consumer<PlanKey> planBranchConsumer)
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.
|
boolean scheduleBranchDetectionForChain(@NotNull
ImmutableChain chain)
chain - boolean scheduleBranchListInitialisation(@NotNull
Chain chain)
chain - void detectBranchesForChain(@NotNull
ImmutableChain chain)
chain - @Nullable List<VcsBranch> getOpenBranches(@NotNull ImmutableChain chain, ErrorCollection errorCollection)
chain - to find branches for.errorCollection - to add any errors to during detection@NotNull Collection<PlanKey> createPlanBranches(@NotNull ImmutableChain chain, @NotNull Collection<VcsBranch> branches, @Nullable ErrorCollection errorCollection)
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 Collection<PlanKey> createPlanBranches(@NotNull ImmutableChain chain, @NotNull Collection<VcsBranch> branches, @Nullable ErrorCollection errorCollection, PlanCreationService.EnablePlan enablePlan)
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@NotNull default Collection<PlanKey> createPlanBranches(@NotNull ImmutableChain chain, @NotNull PlanBranchWorkflow planBranchWorkflow, @NotNull Collection<VcsBranch> branches, @Nullable ErrorCollection errorCollection, @NotNull PlanCreationService.EnablePlan enablePlan)
chain - which chain to create branches underplanBranchWorkflow - which workflow led to creation of these branchesbranches - branches to createerrorCollection - to add errors to, if you don't supply an error collection, they will just get loggedenablePlan - defines whether newly created branches should be enabled or disabled after creation@NotNull Collection<PlanKey> createPlanBranches(@NotNull ImmutableChain chain, @NotNull PlanBranchWorkflow planBranchWorkflow, @NotNull Collection<VcsBranch> branches, @Nullable ErrorCollection errorCollection, @NotNull PlanCreationService.EnablePlan enablePlan, @NotNull Consumer<PlanKey> planBranchConsumer)
chain - which chain to create branches underplanBranchWorkflow - which workflow led to creation of these branchesbranches - branches to createerrorCollection - to add errors to, if you don't supply an error collection, they will just get loggedenablePlan - defines whether newly created branches should be enabled or disabled after creationplanBranchConsumer - code should be executed before triggering events that new plan created@NotNull PlanKey createOrEnableChainBranch(@NotNull ImmutableChain chain, @NotNull PlanBranchWorkflow planBranchWorkflow, @NotNull VcsBranch vcsBranch, @Nullable BuildConfiguration buildConfiguration, @NotNull PlanCreationService.EnablePlan enablePlan, boolean enableExpiry, Consumer<PlanKey> planBranchConsumer) throws PlanCreationDeniedException
chain - to create branches undervcsBranch - 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 detectionPlanCreationDeniedException@NotNull PlanKey createChainBranch(@NotNull ImmutableChain chain, @NotNull String branchName, @Nullable VcsBranch vcsBranch, @Nullable BuildConfiguration buildConfiguration, PlanCreationService.EnablePlan enablePlan, boolean enableExpiry) throws PlanCreationDeniedException
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 detectionPlanCreationException - if validation failsPlanCreationDeniedException@NotNull default PlanKey createChainBranch(@NotNull ImmutableChain chain, @NotNull PlanBranchWorkflow planBranchWorkflow, @NotNull String branchName, @Nullable VcsBranch vcsBranch, @Nullable BuildConfiguration buildConfiguration, @NotNull PlanCreationService.EnablePlan enablePlan, boolean enableExpiry) throws PlanCreationDeniedException
chain - chain to create branches underplanBranchWorkflow - which workflow led to creation of this chain branchbranchName - name of plan branch to createvcsBranch - VCS branch to use when overriding repository definitionbuildConfiguration - 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 detectionPlanCreationDeniedException - if chain branch creation was denied for any reasonPlanKey createChainBranch(@NotNull ImmutableChain chain, @NotNull PlanBranchWorkflow planBranchWorkflow, @NotNull String branchName, @Nullable VcsBranch vcsBranch, @Nullable BuildConfiguration buildConfiguration, @NotNull PlanCreationService.EnablePlan enablePlan, boolean enableExpiry, Consumer<PlanKey> planBranchConsumer) throws PlanCreationDeniedException
chain - chain to create branches underplanBranchWorkflow - which workflow led to creation of this chain branchbranchName - name of plan branch to createvcsBranch - VCS branch to use when overriding repository definitionbuildConfiguration - 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 detectionplanBranchConsumer - code should be executed before triggering events that new plan createdPlanCreationDeniedException - if chain branch creation was denied for any reasonvoid deleteBambooVcsBranch(@NotNull
Iterable<ImmutableChain> chains,
@NotNull
String branchName)
chains - collection of chains/chain branches to search throughbranchName - vcs branch name that was removedvoid disableChainBranch(@NotNull
Iterable<ImmutableChain> chains)
SystemProperty.DISABLE_CLOSED_BRANCH_DETECTION property is enabled.chains - collection of chains/chain branches that should be disabledCopyright © 2019 Atlassian Software Systems Pty Ltd. All rights reserved.