I'm trying to implement the failover strategy when executing jbpm6 processes. My setup is the following:
- I'm using jbpm6.2.0-Final (latest stable release) with persistence enabled
- I'm constructing an instance of
org.kie.spring.factorybeans.RuntimeManagerFactoryBean
with typeSINGLETON
to getKSession
to start/abort processes and complete/abort work items - all beans are wired by Spring 3.2
- DB2 is used a database engine
- I use Tomcat 7.0.27
In the positive scenario everything is working as I expect. But I would like to know how to resume the process in the case of server crash. To reproduce it I started my process (described as BPMN2 file), got at some middle step and killed the Tomcat process. After that I see uncompleted process instance in the PROCESS_INSTANCE_INFO table and uncompleted work item in the WORK_ITEM_INFO table. Also there is a session in the SESSION_INFO table.
My question is: could you show me the example of code which would take that remaining process and resume it starting from the last node (if it is possible).
Update I forgot to mention that i'm not using jbpm-console, but I'm embedding jbpm into my javaee application.