Rahul Agrawal [
https://community.jboss.org/people/rahulamt] created the discussion
"Release task in LocalTaskService in jBPM5.2"
To view the discussion, visit:
https://community.jboss.org/message/759580#759580
--------------------------------------------------------------
Hi all,
This is my use case: A task is pending with a Role. Some user with that role claims the
task. Now the user do not want to work on that task. He want to release that task to role
pool.
The above action can be achieved through org.jbpm.task.TaskService.release(taskId, idRef).
But unfortunately this API is not working.
So I dug dip into the code details ,I could find the following in the LocalTaskService
public void release(long taskId, String userId) {
taskServiceSession.taskOperation(Operation.Release, taskId, userId, null, null,
null);
}
and in the TaskServiceSession for this taskOperation
switch (operation) {
case Claim: {
taskClaimOperation(task);
break;
}
case Complete: {
taskCompleteOperation(task, data);
break;
}
case Fail: {
taskFailOperation(task, data);
break;
}
case Skip: {
taskSkipOperation(task, userId);
break;
}
case Remove: {
taskRemoveOperation(task, user);
break;
}
case Register: {
taskRegisterOperation(task, user);
break;
}
}
there is no switch case for release operation. The same for the postTaskOperations.
Can anyone explain? Am I not supposed to use release for the use case above described?
Please help!!!
--------------------------------------------------------------
Reply to this message by going to Community
[
https://community.jboss.org/message/759580#759580]
Start a new discussion in jBPM at Community
[
https://community.jboss.org/choose-container!input.jspa?contentType=1&...]