Class V5_0_2014_11_04__Enable_XMLWorkflow_Migration
- java.lang.Object
-
- org.dspace.storage.rdbms.xmlworkflow.V5_0_2014_11_04__Enable_XMLWorkflow_Migration
-
- All Implemented Interfaces:
org.flywaydb.core.api.migration.jdbc.JdbcMigration,org.flywaydb.core.api.migration.MigrationChecksumProvider
public class V5_0_2014_11_04__Enable_XMLWorkflow_Migration extends Object implements org.flywaydb.core.api.migration.jdbc.JdbcMigration, org.flywaydb.core.api.migration.MigrationChecksumProvider
This class automatically migrates your DSpace Database to use the XML-based Configurable Workflow system whenever it is enabled. (i.e. workflow.framework=xmlworkflow in workflow.cfg)Because XML-based Configurable Workflow existed prior to our migration, this class first checks for the existence of the "cwf_workflowitem" table before running any migrations.
This class represents a Flyway DB Java Migration http://flywaydb.org/documentation/migration/java.html
It can upgrade a 5.0 version of DSpace to use the XMLWorkflow.
- Author:
- Tim Donohue
-
-
Constructor Summary
Constructors Constructor Description V5_0_2014_11_04__Enable_XMLWorkflow_Migration()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description IntegergetChecksum()Return the checksum to be associated with this Migration in the Flyway database table (schema_version).voidmigrate(Connection connection)Actually migrate the existing database
-
-
-
Method Detail
-
migrate
public void migrate(Connection connection) throws IOException, SQLException
Actually migrate the existing database- Specified by:
migratein interfaceorg.flywaydb.core.api.migration.jdbc.JdbcMigration- Parameters:
connection- SQL Connection object- Throws:
IOException- A general class of exceptions produced by failed or interrupted I/O operations.SQLException- An exception that provides information on a database access error or other errors.
-
getChecksum
public Integer getChecksum()
Return the checksum to be associated with this Migration in the Flyway database table (schema_version).- Specified by:
getChecksumin interfaceorg.flywaydb.core.api.migration.MigrationChecksumProvider- Returns:
- checksum as an Integer
-
-