Class V5_0_2014_11_04__Enable_XMLWorkflow_Migration
java.lang.Object
org.flywaydb.core.api.migration.BaseJavaMigration
org.dspace.storage.rdbms.xmlworkflow.V5_0_2014_11_04__Enable_XMLWorkflow_Migration
- All Implemented Interfaces:
org.flywaydb.core.api.migration.JavaMigration
public class V5_0_2014_11_04__Enable_XMLWorkflow_Migration
extends org.flywaydb.core.api.migration.BaseJavaMigration
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 -
Method Summary
Modifier and TypeMethodDescriptionReturn the checksum to be associated with this Migration in the Flyway database table (schema_version).voidmigrate(org.flywaydb.core.api.migration.Context context) Actually migrate the existing databaseMethods inherited from class org.flywaydb.core.api.migration.BaseJavaMigration
canExecuteInTransaction, extractVersionAndDescription, getDescription, getVersion, initMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.flywaydb.core.api.migration.JavaMigration
getResolvedMigration, getType
-
Constructor Details
-
V5_0_2014_11_04__Enable_XMLWorkflow_Migration
public V5_0_2014_11_04__Enable_XMLWorkflow_Migration()
-
-
Method Details
-
migrate
public void migrate(org.flywaydb.core.api.migration.Context context) throws IOException, SQLException Actually migrate the existing database- Parameters:
context- Flyway Migration Context- 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
Return the checksum to be associated with this Migration in the Flyway database table (schema_version).- Specified by:
getChecksumin interfaceorg.flywaydb.core.api.migration.JavaMigration- Overrides:
getChecksumin classorg.flywaydb.core.api.migration.BaseJavaMigration- Returns:
- checksum as an Integer
-