cancel
Showing results for 
Search instead for 
Did you mean: 

Synchronous calling and waiting for finished usertasks

werners
Champ in-the-making
Champ in-the-making
Hi all,
goal is to add a dynamic  approval steps to a static process definition which is deployed to the repository.
Process “global”
Start –> servicetask1 –> servicetask2 –> end
Process “approval”
Start -> servicetask3 –> usertas 4 -> end

Servicetask1 is implemented with java class.

Depending on the content, servicetask1 should call/start synchronous one dynamic chosen approval-process  with  “runtime.startProcessInstancebyKey”(“approval”) .
Only when the approval process is completely finished  (including the manual usertask) the process should continue on next line in the javaclass from servicetask1 to use the results from approval process.

For sure, the servicetask2 should only get started when the servicetask1 with javacode inside was done completely.
Now, it seems that servicetask1 starts the approval-process. But when usertask 4 is reached, the process global continues with servicetask2, while usertask 4 is still untouched.

Can someone give me some advice how I can implement the desired behavior?

Thanks.
Werner
2 REPLIES 2

trademak
Star Contributor
Star Contributor
Hi Werner,

A possible way to do this is, is to add a call activity after service task 1. In case you start the approval sub process you go to this call activity, otherwise you continue directly with service task 2.

Best regards,

werners
Champ in-the-making
Champ in-the-making
Many thanks, problem is solved.

Werner
Getting started

Tags


Find what you came for

We want to make your experience in Hyland Connect as valuable as possible, so we put together some helpful links.