com.atlassian.bamboo.upgrade.tasks
Class AbstractPreparedStatementUpgradeTask
java.lang.Object
com.atlassian.bamboo.upgrade.AbstractUpgradeTask
com.atlassian.bamboo.upgrade.tasks.AbstractInHibernateTransactionUpgradeTask
com.atlassian.bamboo.upgrade.tasks.AbstractPreparedStatementUpgradeTask
- All Implemented Interfaces:
- UpgradeTask
- Direct Known Subclasses:
- UpgradeTask1307SetDefaultElasticImageConfiguration, UpgradeTask1309DefaultEnabledForElasticSchedule, UpgradeTask2404SetUniqueIdForAllRequirements, UpgradeTask2411DeleteAllScriptCapabilities, UpgradeTask2412DeleteAllNAntScriptCapabilities, UpgradeTask2502SetDefaultOptionalStageValue, UpgradeTask2503SetDefaultOptionalStageResultValue, UpgradeTask2504SetDefaultRestartCountValue
public abstract class AbstractPreparedStatementUpgradeTask
- extends AbstractInHibernateTransactionUpgradeTask
A base upgrade task for simple single PreparedStatement
upgrades
Method Summary |
void |
doUpgrade(java.sql.Connection connection)
|
protected abstract java.lang.String |
getPreparedStatementSql()
Returns the SQL that will be used to init a PreparedStatement |
protected abstract boolean |
isShouldRunUpgrade(java.sql.Statement statement)
Whether or not the upgrade task should actually run |
protected abstract void |
prepareStatement(java.sql.PreparedStatement statement)
Sets the various values in a PreparedStatement |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
AbstractPreparedStatementUpgradeTask
protected AbstractPreparedStatementUpgradeTask(@NotNull
java.lang.String buildNumber,
@NotNull
java.lang.String shortDescription)
doUpgrade
public void doUpgrade(@NotNull
java.sql.Connection connection)
throws java.sql.SQLException
- Specified by:
doUpgrade
in class AbstractInHibernateTransactionUpgradeTask
- Throws:
java.sql.SQLException
getPreparedStatementSql
protected abstract java.lang.String getPreparedStatementSql()
- Returns the SQL that will be used to init a
PreparedStatement
- Returns:
prepareStatement
protected abstract void prepareStatement(java.sql.PreparedStatement statement)
throws java.sql.SQLException
- Sets the various values in a
PreparedStatement
- Parameters:
statement
-
- Throws:
java.sql.SQLException
isShouldRunUpgrade
protected abstract boolean isShouldRunUpgrade(@NotNull
java.sql.Statement statement)
- Whether or not the upgrade task should actually run
- Parameters:
statement
-
- Returns:
Copyright © 2011 Atlassian. All Rights Reserved.