Is there any way to assign Camunda tasks to users round robin? Or any automatic pattern?
1 Answers
You can use an expression with a process variable in the task assignment attribute. The value of the process variable can then be determined dynamically before the user task is reached. You can for instance call a service to get the desired assignee or use DMN. Here is an example: https://camunda.com/blog/2020/05/camunda-bpm-user-task-assignment-based-on-a-dmn-decision-table/
I would not recommend assigning work to individuals by default. It is not required in most scenarios. Instead assign the tasks to a group/role and let people take the tasks from the group worklist when they are free. Round-robin seems like a scenario where you want to ensure equal task distribution. However, in real-world scenarios people do not always have the same capacity, go on leave, etc. Then you will have to deal with monitoring and reassigning the task in these cases. The audit trail and Optimize provide transparency and can create reports of task completion volumes. One can get people to complete the appropriate amount of work items without fixed task assignment to an individual.

- 7,059
- 39
- 54
-
1All fine and vote up, just a comment: I personally try to avoid storing the assignee in a process variable, as it couples two tasks in the process and won't (simply) work with multi-instance scenarios. I prefer to have an assignee expression in the bpmn or a taskCreateListener that determines the assignee during task creation. But ... of course this only works with platform 7 where you can execute code that lives together with your process engine ... not with camunda 8 – Jan Galinski Jun 13 '22 at 09:59