...
- change parent/version from 2.1.2 to 2.1.3
- change properties/syncope.version from 2.1.2 to 2.1.3
In core/pom.xml , replace
Code Block |
|
<dependency>
<groupId>org.apache.syncope.core</groupId>
<artifactId>syncope-core-workflow-flowable</artifactId>
<version>${syncope.version}</version>
</dependency>
|
with
Code Block |
|
<dependency>
<groupId>org.apache.syncope.ext.flowable</groupId>
<artifactId>syncope-ext-flowable-rest-cxf</artifactId>
<version>${syncope.version}</version>
</dependency>
|
In console/pom.xml , add
Code Block |
|
<dependency>
<groupId>org.apache.syncope.ext.flowable</groupId>
<artifactId>syncope-ext-flowable-client-console</artifactId>
<version>${syncope.version}</version>
</dependency>
|
as first child of the <dependencies> element in the all profile; then remove
Code Block |
|
<dependency>
<groupId>org.flowable</groupId>
<artifactId>flowable-ui-modeler-app</artifactId>
<type>war</type>
<scope>test</scope>
</dependency>
|
and the whole <plugins/> element (including children). Files In the workflow.properties file enabled with Flowable support (it could be core/src/main/resources/workflow.properties , core/src/main/resources/all/workflow.properties or other, depending on your project setup), replace ...
... Files Add
Code Block |
notificationManager=org.apache.syncope.core.
|
...
... with ...
...
java.notification.DefaultNotificationManager
auditManager=org.apache.syncope.core.
|
...
...
...
... to core/src/main/resources/ ... provisioning.properties ... . ...
Code Block |
flowableModelerDirectory=${flowable-modeler.directory}
|
and
Code Block |
page.workflow=org.apache.syncope.client.console.pages.Workflow
|
then add
Code Block |
topology.corePoolSize=10
topology.maxPoolSize=20
topology.queueCapacity=50
|
Replace the following files with their 2.1.2 3 counterparts (re-apply any customization previously made):
Classes
- move all workflow tasks from package
org.apache.syncope.core.workflow.flowable.task to package org.apache.syncope.core.flowable.task
- change parent class from
AbstractFlowableServiceTask to FlowableServiceTask
Internal Storage If not using Flowable Stop the Java EE container running Syncope Core, then execute the following SQL statement:
Code Block |
|
DROP VIEW user_search;
ALTER TABLE SyncopeUser DROP COLUMN workflowId;
CREATE VIEW user_search AS SELECT u.id as any_id, u.* FROM SyncopeUser u;
_null_attr;
DROP VIEW group_search;
ALTER TABLE SyncopeGroup DROP COLUMN workflowId;
CREATE VIEW group_search AS SELECT r.id as any_id, r.* FROM SyncopeGroup r;
_null_attr;
DROP VIEW anyObject_search;
ALTER TABLE AnyObject DROP COLUMN workflowId;
CREATE VIEW anyObject_search AS SELECT a.id as any_id, a.* FROM AnyObject a;
|
Finally start again the Java EE container. If using Flowable Stop the Java EE container running Syncope Core, then follow the instructions to download and extract the upgrade tool, the run it by adding the "-flowable-2.1.2 " switch to the command line as follows:
Code Block |
|
./syncopeupgrade.sh org.postgresql.Driver \
jdbc:postgresql://localhost:5432/syncope syncope syncope postgres \
-flowable-2.1.2 \
upgradeFlowable212.sql
|
Now execute the SQL statements as generated above in the upgradeFlowable212.sql file against the internal storage: in case of errors, apply manual corrections until everything runs clear; consider to restore from the backup taken above if needed, before executing the updated SQL statements again. Finally start again the Java EE container and watch the log files to check for any error. User workflow definition The user workflow must be updated: in the XML definition, replace any occurrence like as follows:
Code Block |
flowable:_expression_="#{create.execute(execution.processInstanceId)}"
|
with
Code Block |
flowable:delegateExpression="${create}"
|
Once the updated definition is set, stop the Java EE container and verify the actual version on the internal storage:
Code Block |
|
SELECT ID_ FROM ACT_RE_PROCDEF ORDER BY VERSION_ DESC LIMIT 1
|
Supposing that the statement above returns userWorkflow:2:12504 , execute the following SQL statements:
Code Block |
|
UPDATE ACT_RU_EXECUTION SET PROC_DEF_ID_ = 'userWorkflow:2:12504' WHERE ID_ IS NOT NULL;
UPDATE ACT_RU_TASK SET PROC_DEF_ID_ = 'userWorkflow:2:12504' WHERE ID_ IS NOT NULL;
|
Finally start again the Java EE container and watch the log files to check for any error.
|