com.atlassian.confluence.upgrade
Interface UpgradeGate

All Known Implementing Classes:
DefaultUpgradeGate

public interface UpgradeGate

Gate the upgrade progress across nodes so that only one node will perform plugin dependent upgrades. You should not that the mechanism for exclusion for non-plugin dependent upgrades is unchanged and still represented in the DefaultUpgradeManager.


Method Summary
 boolean isPluginDependentUpgradeCompleteWithWait()
          Check is the plugin dependent upgrades have been completed.
 boolean isUpgradeRequiredWithWait()
          Check the upgrade status set via setUpgradeRequired(boolean).
 void setPluginDependentUpgradeComplete(boolean complete)
           
 void setUpgradeRequired(boolean required)
           
 

Method Detail

setUpgradeRequired

void setUpgradeRequired(boolean required)
Parameters:
required - if true then an upgrade is required.

setPluginDependentUpgradeComplete

void setPluginDependentUpgradeComplete(boolean complete)
Parameters:
complete - if true then the plugin dependent upgrade is finished, otherwise it is not yet complete.

isUpgradeRequiredWithWait

boolean isUpgradeRequiredWithWait()
Check the upgrade status set via setUpgradeRequired(boolean). If it has not been set yet then the caller will keep trying for #UPGRADE_REQUIRED_CHECK_ATTEMPTS * #UPGRADE_REQUIRED_CHECK_SLEEP milliseconds before returning a default value of false.

Returns:
true if an upgrade is required; false if timeout or it is not required.

isPluginDependentUpgradeCompleteWithWait

boolean isPluginDependentUpgradeCompleteWithWait()
Check is the plugin dependent upgrades have been completed. If this is not yet true (indicating another node is performing the upgrades) then the caller will keep trying for #WAIT_FOR_OTHER_NODE_UPGRADE_ATTEMPTS * #WAIT_FOR_OTHER_NODE_UPGRADE_SLEEP milliseconds before returning a default value of false.

Returns:
true if the plugin dependent upgrades are complete; false if the waiting times out.


Copyright © 2003-2012 Atlassian. All Rights Reserved.