public class JiraBranchLinkingServiceImpl extends Object implements JiraBranchLinkingService
Constructor and Description |
---|
JiraBranchLinkingServiceImpl(PlanManager planManager,
JiraRemoteIssueManager jiraRemoteIssueManager,
JiraRestService jiraRestService,
JiraApplinksService jiraApplinksService,
JiraIssueUtils jiraIssueUtils,
ImpersonationService impersonationService,
ImmutablePlanCacheService immutablePlanCacheService) |
Modifier and Type | Method and Description |
---|---|
JiraIssueDetails |
createRemoteLinkToBranch(ImmutableChainBranch branch,
String issueKey)
Creates a remote link from the issue to the branch.
|
String |
findIssueKeyToLink(ImmutableChainBranch branch)
Looks for an issue key in plan branch name or vcs branch name.
|
void |
linkBranchToIssueIfRequiredAsync(PlanKey planKey,
String username)
Looks for an issue key in the branch name.
|
public JiraBranchLinkingServiceImpl(PlanManager planManager, JiraRemoteIssueManager jiraRemoteIssueManager, JiraRestService jiraRestService, JiraApplinksService jiraApplinksService, JiraIssueUtils jiraIssueUtils, ImpersonationService impersonationService, ImmutablePlanCacheService immutablePlanCacheService)
public void linkBranchToIssueIfRequiredAsync(@NotNull PlanKey planKey, @Nullable String username)
JiraBranchLinkingService
ChainBranchIdentifier.isRemoteJiraLinkRequired()
to see if remote link succeeded.linkBranchToIssueIfRequiredAsync
in interface JiraBranchLinkingService
planKey
- of branch to linkusername
- (optional) to use for authentication if possible/required@NotNull public JiraIssueDetails createRemoteLinkToBranch(@NotNull ImmutableChainBranch branch, @NotNull String issueKey) throws RemoteLinkCreationFailedException, CredentialsRequiredContextException
JiraBranchLinkingService
createRemoteLinkToBranch
in interface JiraBranchLinkingService
branch
- to linkissueKey
- of the issue to linkRemoteLinkCreationFailedException
- if creation of the remote link in jira failsCredentialsRequiredContextException
- if authentication is required to create the remote link in JIRA.@Nullable public String findIssueKeyToLink(@NotNull ImmutableChainBranch branch)
JiraBranchLinkingService
findIssueKeyToLink
in interface JiraBranchLinkingService
branch
- to find the issue forCopyright © 2021 Atlassian Software Systems Pty Ltd. All rights reserved.