1
votes

I need to design a workflow with JBPM where at some point the workflow is separated in 3 parallel branches. Each branch has an approval task that can be assigned to a group.

A member of the group can get the ownership of the task and approve or reject. Because for each branch there is a different task, there will be 3 possible approve or reject.

If 2 out of 3 approves the workflow proceeds otherwise is terminated.

Could you suggest how to do it?

Thanks

1

1 Answers

1
votes

You can use fork for creating branches of perticular task.

Refer out of box parallel workflow file to get idea on creating parallel task.

 <action class="org.alfresco.repo.workflow.jbpm.ForEachFork">
   <foreach>
    #{people.getMembers(people.getGroup('GROUP_test'))}
   </foreach>
    <var>reviewer</var>
  </action>

In parallel approval you can use decision node which will keep track of number of approval done so you can transit of approved state when number of approval reaches to two.Out of box parallel review workflow has similar logic where it store percentage approval in one variable and when appropriate value is reached it transit to approved state.