Class PlanVcsRevisionHistoryManagerImpl
java.lang.Object
com.atlassian.bamboo.plan.vcsRevision.PlanVcsRevisionHistoryManagerImpl
- All Implemented Interfaces:
PlanVcsRevisionHistoryManager
public class PlanVcsRevisionHistoryManagerImpl
extends Object
implements PlanVcsRevisionHistoryManager
-
Constructor Summary
ConstructorsConstructorDescriptionPlanVcsRevisionHistoryManagerImpl(PlanVcsRevisionHistoryDao planVcsRevisionHistoryDao) -
Method Summary
Modifier and TypeMethodDescriptionvoidcleanupUnusedEntriesForPlan(@NotNull PlanKey planKey) Removes history entries that are not used in change detection process.voidclearRevisionHistoryForPlanNewTx(@NotNull PlanKey planKey) Removes all history entries for the plan.@NotNull Map<Long, PlanVcsRevisionData> getLastVcsRevisionKeys(@NotNull PlanKey planKey) Return the mapping between repository ids and strings representing the vcs revisions which were result of last performed change detection.@NotNull Map<Long, PlanVcsRevisionData> getLastVcsRevisionKeysBeforeBuildNumber(@NotNull PlanKey planKey, int buildNumber) Return the mapping between repository ids and strings representing the vcs revisions which were result of last change detection performed before given build.voidmarkBuildStartedNewTx(@NotNull BuildContext buildContext) Saves the information on started build in the plan's vcs revision history.voidmarkChangeDetectionCompletedNewTx(@NotNull PlanKey planKey, int buildNumber, @NotNull PlanVcsRevisionData planVcsRevisionData, long repositoryId) Saves the information on change detection result in the plan's vcs revision history.voidmoveRevisionHistoryForPlan(@NotNull PlanKey oldPlanKey, @NotNull PlanKey newPlanKey)
-
Constructor Details
-
PlanVcsRevisionHistoryManagerImpl
-
-
Method Details
-
getLastVcsRevisionKeys
@NotNull public @NotNull Map<Long,PlanVcsRevisionData> getLastVcsRevisionKeys(@NotNull @NotNull PlanKey planKey) Description copied from interface:PlanVcsRevisionHistoryManagerReturn the mapping between repository ids and strings representing the vcs revisions which were result of last performed change detection. Will be empty if nothing has been built. The values are parseable by the individual repositories.- Specified by:
getLastVcsRevisionKeysin interfacePlanVcsRevisionHistoryManager- Returns:
- mapping between repository id and corresponding revision key.
-
getLastVcsRevisionKeysBeforeBuildNumber
@NotNull public @NotNull Map<Long,PlanVcsRevisionData> getLastVcsRevisionKeysBeforeBuildNumber(@NotNull @NotNull PlanKey planKey, int buildNumber) Description copied from interface:PlanVcsRevisionHistoryManagerReturn the mapping between repository ids and strings representing the vcs revisions which were result of last change detection performed before given build. The value is parseable by the individual repositories.- Specified by:
getLastVcsRevisionKeysBeforeBuildNumberin interfacePlanVcsRevisionHistoryManager- Returns:
- mapping between repository id and corresponding revision key.
-
markBuildStartedNewTx
Description copied from interface:PlanVcsRevisionHistoryManagerSaves the information on started build in the plan's vcs revision history. Enforces new transaction. Updates previousVcsRevisionKey inBuildContext- Specified by:
markBuildStartedNewTxin interfacePlanVcsRevisionHistoryManager- Parameters:
buildContext-
-
markChangeDetectionCompletedNewTx
public void markChangeDetectionCompletedNewTx(@NotNull @NotNull PlanKey planKey, int buildNumber, @NotNull @NotNull PlanVcsRevisionData planVcsRevisionData, long repositoryId) Description copied from interface:PlanVcsRevisionHistoryManagerSaves the information on change detection result in the plan's vcs revision history. Enforces new transaction.- Specified by:
markChangeDetectionCompletedNewTxin interfacePlanVcsRevisionHistoryManager- Parameters:
planKey-buildNumber-planVcsRevisionData-
-
clearRevisionHistoryForPlanNewTx
Description copied from interface:PlanVcsRevisionHistoryManagerRemoves all history entries for the plan. In effect the next build will behave similar to initial build. Enforces new transaction.- Specified by:
clearRevisionHistoryForPlanNewTxin interfacePlanVcsRevisionHistoryManager- Parameters:
planKey-
-
cleanupUnusedEntriesForPlan
Description copied from interface:PlanVcsRevisionHistoryManagerRemoves history entries that are not used in change detection process.- Specified by:
cleanupUnusedEntriesForPlanin interfacePlanVcsRevisionHistoryManager- Parameters:
planKey-
-
moveRevisionHistoryForPlan
public void moveRevisionHistoryForPlan(@NotNull @NotNull PlanKey oldPlanKey, @NotNull @NotNull PlanKey newPlanKey) - Specified by:
moveRevisionHistoryForPlanin interfacePlanVcsRevisionHistoryManager
-