Migrate ODF 2 project to version 10.2.7
The guide describes steps to migrate an ODF 2-based project from v10.2.6 to v10.2.7.
important
Get acquainted with the following Platform v10.2.7 features. Although these features are not the main concern of the guide, they can significantly change the design of some Business Processes:
Migrate ODF 2 project
To migrate an ODF 2-based project from v10.2.6 to v10.2.7, do as follows:
Open the root
pom.xmlof your project. In the<properties>section, find the<odf2.version>property.Update the ODF 2 version according to the compatibility matrix. Also, update the
<bundle-versions-maven-plugin.version>and<bundle-maven-plugin.version>properties for Bundle version Maven plugin and Bundle Maven plugin accordingly:<properties> <odf2.version>10.2.7.18</odf2.version> <bundle-versions-maven-plugin.version>0.0.27</bundle-versions-maven-plugin.version> <bundle-maven-plugin.version>10.2.7.14</bundle-maven-plugin.version> </properties>Backward-incompatible code changes
If you have custom runners based on
AbstractTransactionConsumingTaskRunneror its child implementations, addSkipBotTaskExecutionServicetosuper(). The service is responsible for the skip logic and is available fromTransactionModule.public abstract class CustomRunner<T extends CustomRunnerTask> extends AbstractTransactionConsumingTaskRunner<T> { protected CustomRunner(TaskInput taskInput, CurrentTransaction currentTransaction, SkipBotTaskExecutionService skipBotTaskExecutionService) { super(taskInput, currentTransaction, skipBotTaskExecutionService); } protected abstract void run(T task, TransactionResult result) { //Some realization }; }
- Build the project with the
mvn clean verifycommand and make sure there are no compilation errors, and all unit tests of your project have passed successfully.
Update project migrations
For related updates, do as follows:
Change the related Data Store schemas:
- Add
skip_untilcolumn to theuc_[code]_transaction_[version]table. To do this, navigate to thetables.xmlfile at[package_module]/src/main/resources/datastore/migrations/versioned/tables.xmland add the following statement:
<addColumn tableName="our_transaction_table"> <column name="skip_until" type="NVARCHAR(256)"/> </addColumn>- Change the data type of
split_status. Now, it has changed the data type from theSplitStatusenum to a simpleString, and you need to increase the string's width. Add the following statement:
<modifyDataType columnName="split_status" newDataType="NVARCHAR(255)" tableName="our_transaction_table"/>It is recommended to keep this modification as a separate Liquibase changeset. In the example, the required changeset looks as follows:
<changeSet author="user" id="odf2_v1_0_0014"> <addColumn tableName="uc_odf2_transaction_v1_0"> <column name="skip_until" type="NVARCHAR(256)"/> </addColumn> <modifyDataType columnName="split_status" newDataType="NVARCHAR(255)" tableName="uc_odf2_transaction_v1_0"/> </changeSet>note
- When working with Liquibase migrations, keep in mind that each table name contains the Digital Worker code and version. Remember to fill the values properly.
- Each new
changeSetrequires theIDattribute. Mind the identifier requirements.
- Add
Build the project with the
mvn clean verifycommand to produce a new bundle with updated migrations.