com.atlassian.bamboo.deployments.versions.service
Class DeploymentVersionChainResultDataCollectorImpl

java.lang.Object
  extended by com.atlassian.bamboo.deployments.versions.service.DeploymentVersionChainResultDataCollectorImpl
All Implemented Interfaces:
DeploymentVersionChainResultDataCollector

public class DeploymentVersionChainResultDataCollectorImpl
extends java.lang.Object
implements DeploymentVersionChainResultDataCollector

Helper class used for gathering commits and issues for freshly created Deployment Version.


Constructor Summary
DeploymentVersionChainResultDataCollectorImpl(DeploymentVersionDao deploymentVersionDao, DeploymentVersionVcsChangesetDao deploymentVersionVcsChangesetDao, DeploymentVersionLinkedJiraIssueDao deploymentVersionLinkedJiraIssueDao, ResultsSummaryManager resultsSummaryManager, RepositoryChangesetDao repositoryChangesetDao, LinkedJiraIssueDao linkedJiraIssueDao)
           
 
Method Summary
 void createChangesetsAndJiraIssues(long deploymentProjectId, MutableDeploymentVersion mutableDeploymentVersion, PlanResultKey planResultKey)
          Finds changes between last version (if it exists) and a new version by looking at build results that happened between the 2 versions and saves them to the db.
 Pair<java.util.List<MutableDeploymentVersionVcsChangeset>,java.util.List<InternalLinkedJiraIssue>> findChangesetsAndJiraIssues(long deploymentProjectId, MutableDeploymentVersion newVersion, PlanResultKey planResultKey)
          Finds changes between last version (if it exists) and a new version by looking at build results that happened between the 2 versions.
 Pair<java.util.List<DeploymentVersionVcsChangeset>,java.util.List<InternalLinkedJiraIssue>> findImmutableChangesetsAndJiraIssues(long deploymentProjectId, MutableDeploymentVersion newVersion, PlanResultKey planResultKey)
          Finds changes between last version (if it exists) and a new version by looking at build results that happened between the 2 versions.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DeploymentVersionChainResultDataCollectorImpl

public DeploymentVersionChainResultDataCollectorImpl(DeploymentVersionDao deploymentVersionDao,
                                                     DeploymentVersionVcsChangesetDao deploymentVersionVcsChangesetDao,
                                                     DeploymentVersionLinkedJiraIssueDao deploymentVersionLinkedJiraIssueDao,
                                                     ResultsSummaryManager resultsSummaryManager,
                                                     RepositoryChangesetDao repositoryChangesetDao,
                                                     LinkedJiraIssueDao linkedJiraIssueDao)
Method Detail

createChangesetsAndJiraIssues

public void createChangesetsAndJiraIssues(long deploymentProjectId,
                                          @NotNull
                                          MutableDeploymentVersion mutableDeploymentVersion,
                                          @NotNull
                                          PlanResultKey planResultKey)
Finds changes between last version (if it exists) and a new version by looking at build results that happened between the 2 versions and saves them to the db.

Specified by:
createChangesetsAndJiraIssues in interface DeploymentVersionChainResultDataCollector
Parameters:
deploymentProjectId - id of the Deployment Project version is related to
mutableDeploymentVersion - version being created
planResultKey - the key of build result this version is created from

findChangesetsAndJiraIssues

@NotNull
public Pair<java.util.List<MutableDeploymentVersionVcsChangeset>,java.util.List<InternalLinkedJiraIssue>> findChangesetsAndJiraIssues(long deploymentProjectId,
                                                                                                                                              @Nullable
                                                                                                                                              MutableDeploymentVersion newVersion,
                                                                                                                                              @NotNull
                                                                                                                                              PlanResultKey planResultKey)
Finds changes between last version (if it exists) and a new version by looking at build results that happened between the 2 versions.

Specified by:
findChangesetsAndJiraIssues in interface DeploymentVersionChainResultDataCollector
Parameters:
deploymentProjectId - id of the Deployment Project version is related to
newVersion - version being created - might be null if we don't want to save anything in db
planResultKey - the key of build result this version is created from
Returns:
Pair.getFirst() - list of changesets, Pair.getSecond() - list of JIRA issues

findImmutableChangesetsAndJiraIssues

@NotNull
public Pair<java.util.List<DeploymentVersionVcsChangeset>,java.util.List<InternalLinkedJiraIssue>> findImmutableChangesetsAndJiraIssues(long deploymentProjectId,
                                                                                                                                                @Nullable
                                                                                                                                                MutableDeploymentVersion newVersion,
                                                                                                                                                @NotNull
                                                                                                                                                PlanResultKey planResultKey)
Finds changes between last version (if it exists) and a new version by looking at build results that happened between the 2 versions.

Specified by:
findImmutableChangesetsAndJiraIssues in interface DeploymentVersionChainResultDataCollector
Parameters:
deploymentProjectId - id of the Deployment Project version is related to
newVersion - version being created - might be null if we don't want to save anything in db
planResultKey - the key of build result this version is created from
Returns:
Pair.getFirst() - list of immutable changesets, Pair.getSecond() - list of JIRA issues


Copyright © 2013 Atlassian Software Systems Pty Ltd. All Rights Reserved.