Package com.atlassian.bamboo.upgrade
Class BootstrapUpgradeManagerImpl
java.lang.Object
com.atlassian.bamboo.upgrade.AbstractUpgradeManager
com.atlassian.bamboo.upgrade.BootstrapUpgradeManagerImpl
- All Implemented Interfaces:
BootstrapUpgradeManager
,UpgradeManager
,org.springframework.beans.factory.Aware
,org.springframework.context.ApplicationContextAware
public class BootstrapUpgradeManagerImpl
extends AbstractUpgradeManager
implements BootstrapUpgradeManager, org.springframework.context.ApplicationContextAware
-
Field Summary
Fields inherited from class com.atlassian.bamboo.upgrade.AbstractUpgradeManager
applicationConfig, bootstrapManager, buildNumberComparator, fileName, newBuildNumber, oldBuildNumber, textProvider, upgradeTasks, upgradeUtilityBean, xPathExpression
-
Constructor Summary
ModifierConstructorDescriptionprotected
BootstrapUpgradeManagerImpl
(@NotNull com.atlassian.config.ApplicationConfiguration applicationConfig, @NotNull BootstrapUpgradeHelper bootstrapUpgradeHelper, @NotNull BootstrapManager bootstrapManager, @NotNull String newBuildNumber, @NotNull String fileName) BootstrapUpgradeManagerImpl
(@NotNull com.atlassian.config.ApplicationConfiguration applicationConfig, @NotNull BootstrapUpgradeHelper bootstrapUpgradeHelper, BootstrapManager bootstrapManager, @NotNull String fileName) -
Method Summary
Modifier and TypeMethodDescriptioncreateUpgradeTask
(String className) doUpgrade
(boolean partOfSetup) Method to fire off the upgrade processRun upgrade task that have to be run after hot swap import or setup-with-import.Runs validation tests defined in upgrades.xmlvoid
setApplicationContext
(org.springframework.context.ApplicationContext appContext) Methods inherited from class com.atlassian.bamboo.upgrade.AbstractUpgradeManager
classifyUpgradeTask, createTasks, forEachTask, getBuildNumber, getDescription, getOldBuildNumber, getUpgradeDocument, getUpgradeTasks, needUpgrade, populateRelevantUpgrades, runUpgradeTask, setTextProvider, setUpgradeUtilityBean, shouldRunTask
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface com.atlassian.bamboo.upgrade.UpgradeManager
getBuildNumber, getOldBuildNumber, needUpgrade
-
Constructor Details
-
BootstrapUpgradeManagerImpl
public BootstrapUpgradeManagerImpl(@NotNull @NotNull com.atlassian.config.ApplicationConfiguration applicationConfig, @NotNull @NotNull BootstrapUpgradeHelper bootstrapUpgradeHelper, BootstrapManager bootstrapManager, @NotNull @NotNull String fileName) -
BootstrapUpgradeManagerImpl
protected BootstrapUpgradeManagerImpl(@NotNull @NotNull com.atlassian.config.ApplicationConfiguration applicationConfig, @NotNull @NotNull BootstrapUpgradeHelper bootstrapUpgradeHelper, @NotNull @NotNull BootstrapManager bootstrapManager, @NotNull @NotNull String newBuildNumber, @NotNull @NotNull String fileName)
-
-
Method Details
-
runUpgradesForHotswapImport
Description copied from interface:BootstrapUpgradeManager
Run upgrade task that have to be run after hot swap import or setup-with-import.- Specified by:
runUpgradesForHotswapImport
in interfaceBootstrapUpgradeManager
- Throws:
Exception
-
doUpgrade
Description copied from interface:UpgradeManager
Method to fire off the upgrade process- Specified by:
doUpgrade
in interfaceUpgradeManager
- Parameters:
partOfSetup
- - whether or not the upgrade is being run as part of the setup- Returns:
- collection of error messages, not empty collection denotes error occurred on upgrade
- Throws:
Exception
-
runValidationTasks
Description copied from interface:BootstrapUpgradeManager
Runs validation tests defined in upgrades.xml- Specified by:
runValidationTasks
in interfaceBootstrapUpgradeManager
- Returns:
List
a string list of error messages. Not empty list denotes error occurred in validation- Throws:
ValidationException
- when a critical error occurred and validation has been aborted
-
createUpgradeTask
- Overrides:
createUpgradeTask
in classAbstractUpgradeManager
- Throws:
UpgradeException
-
setApplicationContext
public void setApplicationContext(org.springframework.context.ApplicationContext appContext) throws org.springframework.beans.BeansException - Specified by:
setApplicationContext
in interfaceorg.springframework.context.ApplicationContextAware
- Throws:
org.springframework.beans.BeansException
-