-
1. Re: jBPM 5.4 : forwarding task PermissionDeniedException when user is actualOwner but not in potential owners
gonzalad Feb 19, 2013 9:36 AM (in response to gonzalad)For now, I'm adding actualOwner to potentialOwner as a temporary solution just before calling forward.
// add actualOwner to potentialOwners Task task = taskService.getTask(taskId); org.jbpm.task.User actualOwner = task.getTaskData().getActualOwner(); if (actualOwner != null) { PeopleAssignments peopleAssignments = task.getPeopleAssignments(); if (! peopleAssignments.getPotentialOwners().contains(actualOwner)) { peopleAssignments.getPotentialOwners().add(actualOwner); } } taskService.forward(taskSummary.getId(), username, targetGroupname);
-
3. Re: jBPM 5.4 : forwarding task PermissionDeniedException when user is actualOwner but not in potential owners
gonzalad Feb 19, 2013 2:17 PM (in response to gonzalad)Also, a similar case is produced I think (I musy verify it tomorrow) when user belongs to a group and task.potentialOwner contains only the group, not the user.
Perhaps, changing userIsExplicitPotentialOwner is needed to also check if user belongs to one of the groups contained in task.potentialOwner.
I'll do some more tests tomorrow for this and update my temporary solution.
-
4. Re: jBPM 5.4 : forwarding task PermissionDeniedException when user is actualOwner but not in potential owners
gonzalad Feb 20, 2013 6:07 AM (in response to gonzalad)Also, a similar case is produced I think (I musy verify it tomorrow) when user belongs to a group and task.potentialOwner contains only the group, not the user.
Confirmed, but after reading WS-HumanTask 1.0 spec (http://incubator.apache.org/hise/WS-HumanTask_v1.pdf), chapter 4.7.3 Delegating or Forwarding a Human Task :
Forwarding is possible if the task has a set of individually assigned potential owners, not if its potential owners are assigned using one or many groups.
So, this scenario isn't possible per the spec ;(
I'm deviating the original subject, so I should open another thread about how to forward / reassign / delegate / whatever a task to a group.