12-21-2018 10:02 AM
Hello All.
Maybe it is the known issue - I have multiple service tasks in process, which are supposed to be called one by one. The issue is, that some of them are called multiple times. To be more presize - I have 3 service tasks, first one is called 1 time, second one is called 3 times, third task is called 2 times(I can see it in debug). Simplified process looks so:
<process id="simple-test" name="simple-test">
<startEvent id="start"/>
<sequenceFlow sourceRef="start" targetRef="firstServiceTask" />
<serviceTask id="firstServiceTask" name="First Service Task"
flowable:delegateExpression="${firstJavaDelegateSpringBean}" />
<sequenceFlow sourceRef="firstServiceTask" targetRef="secondServiceTask" />
<serviceTask id="secondServiceTask" name="Second Service Task"
flowable:delegateExpression="${secondJavaDelegateSpringBean}"/>
<sequenceFlow sourceRef="secondServiceTask" targetRef="thirdServiceTask"/>
<serviceTask id="thirdServiceTask" name="Schedule Auction Specification Event Action"
flowable:delegateExpression="${thirdJavaDelegateSpringBean}"/>
<sequenceFlow sourceRef="thirdServiceTask" targetRef="end"/>
<endEvent id="end"/>
</process>
Have you ever faced similar behavior? how did you solve it for yourself?
12-27-2018 06:59 AM
These 3 service tasks are executed in the same transaction.
If there is an uncatched exception in the third task, all tasks are re-executed. In this case, it's strange that you see that the first task is executed one time only.
Explore our Alfresco products with the links below. Use labels to filter content by product module.