-
Bug
-
Resolution: Done
-
Major
-
jBPM 5.4
-
None
We use jBPM with persistence and setup the environment. We then use createProcessInstance and startProcessInstance to initiate a process.
This process contains a callActivity which contains a (Receive) Task that doesn't immediately call completeWorkItem and thus causes startProcessInstance to return.
In some rare cases we now observe a DB state in which the parent process instance is in state PENDING while the callActivity process instance as well as the workItem are in state ACTIVE. As a result asking the parent process instance for active Nodes returns an empty Collection.
During further investigation we called startProcessInstance with an active transaction which we committed after the method returned. In this case we called getProcessInstance and after that getNodeInstances once before the commit and once in a separate transaction after the commit. The first time we received the instance of the active subprocess the second time we again received an empty Collection. The commit was performed without any Exceptions.