-
1. Re: Prematurely completing a workflow in 4.3
rebody May 4, 2010 8:37 PM (in response to matrixpooh)1 of 1 people found this helpfulHi Al,
Maybe you can try EventListener like this.
<process>
<on event="end">
<event-listener class="sample.Listen"/>
</on>
</process>
You could set a EventListener to handle processEndEvent and do what you want.
-
2. Re: Prematurely completing a workflow in 4.3
matrixpooh May 17, 2010 12:10 PM (in response to rebody)Hi HuiSheng,
Thanks a bunch for following up.
I was asking a pretty basic question: how to close processes from an activity handler of another process. ExecutionService::endProcessInstance() all that I needed.
But I ran into another issue doing this call: the processes i need to close are collections of human tasks. All or any of the tasks may be pending at the moment of ending their processes. The call to endProcessInstance() fails with integrity constraint: can't delete "swimlane" records due to "task" child records. Looking into it now. If you have any ideas, would be grately appreciated
-
3. Re: Prematurely completing a workflow in 4.3
matrixpooh May 18, 2010 3:28 PM (in response to matrixpooh)More update: I modifed jbpm.task.hbm.xml to inlcude
{code:xml}
<set name="tasks" cascade="delete-orphan">
<key column="SWIMLANE_" />
<one-to-many />
</set>{code}
and added corresponding Set<Task> tasks with a getter to the SwimlaneImpl.
That fixed the issue and seems to have no effect on opening and updating processes.
-
4. Re: Prematurely completing a workflow in 4.3
rebody May 20, 2010 4:23 AM (in response to matrixpooh)Hi Al,
I am sorry that I cannot understand what you want to do. If you could provide a testcase to us, it will be appreciated. Thank you very much.