com.atlassian.bamboo.upgrade
Interface UpgradeManager

All Known Implementing Classes:
UpgradeManagerImpl

public interface UpgradeManager

Manager to provide upgrade services


Method Summary
 java.util.Collection doUpgrade(boolean partOfSetup)
          Method to fire off the upgrade process
 java.lang.String getBuildNumber()
          This gets the pre-build number
 java.util.SortedMap getUpgrades()
          Gets a map of upgrade tasks which need to run.
 boolean isFullReindexWhenUpgradesFinish()
           
 boolean needUpgrade()
          Determines whether we need to run the upgrade or not.
 void setFullReindexWhenUpgradesFinish(boolean fullReindexWhenUpgradesFinish)
          Marks that the UpgradeManger should do a full reindex when all upgrades have finished successfully
 

Method Detail

needUpgrade

boolean needUpgrade()
Determines whether we need to run the upgrade or not.

Returns:
boolean whether the build was successful or not

doUpgrade

java.util.Collection doUpgrade(boolean partOfSetup)
                               throws java.lang.Exception
Method to fire off the upgrade process

Parameters:
partOfSetup - - whether or not the upgrade is being run as part of the setup
Returns:
Collection a string collection of error messages. Collection not empty denotes error occured on upgrade
Throws:
java.lang.Exception

getBuildNumber

java.lang.String getBuildNumber()
This gets the pre-build number

Returns:
the current build number (in application config file)

getUpgrades

java.util.SortedMap getUpgrades()
Gets a map of upgrade tasks which need to run.

Returns:
SortedMap map of upgrade tasks, keys are the string representations of the build number.

isFullReindexWhenUpgradesFinish

boolean isFullReindexWhenUpgradesFinish()

setFullReindexWhenUpgradesFinish

void setFullReindexWhenUpgradesFinish(boolean fullReindexWhenUpgradesFinish)
Marks that the UpgradeManger should do a full reindex when all upgrades have finished successfully

Parameters:
fullReindexWhenUpgradesFinish -


Copyright © 2009 Atlassian Pty Ltd. All Rights Reserved.