Discussion:
[jboss-user] [jBPM] - No current status match exception.
Dsire krish
2012-08-25 11:47:08 UTC
Permalink
Dsire krish [https://community.jboss.org/people/arselv] created the discussion

"No current status match exception."

To view the discussion, visit: https://community.jboss.org/message/755934#755934

--------------------------------------------------------------
I need to get the tasks by status and then start them.
But at some times while retrieveing the tasks im getting the started process id as well and thats in where im getting this exception.


org.jbpm.task.service.PermissionDeniedException: Server-side Exception: User '[User:'admin']' was unable to execution operation 'Start' on task id 287271 due to a no 'current status' match
     at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
     at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
     at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)

My mina task handler is running in jboss and the application uses its client to the task operations.

Retrieveing tasks by status:

BlockingTaskSummaryResponseHandler resHandler = new BlockingTaskSummaryResponseHandler();
                                        List<Status>statusls=new ArrayList<Status>();
                                        statusls.add(Status.Reserved);
                                        client.getTasksAssignedAsPotentialOwnerByStatus("admin",statusls,  "en-UK", resHandler);

Starting the task:

     BlockingTaskOperationResponseHandler responseHandler = new BlockingTaskOperationResponseHandler();
                    client.start(taskId, userId, responseHandler);

*Is there any thing to do with hibernate or what should i take care to eliminate this replication.?*
--------------------------------------------------------------

Reply to this message by going to Community
[https://community.jboss.org/message/755934#755934]

Start a new discussion in jBPM at Community
[https://community.jboss.org/choose-container!input.jspa?contentType=1&containerType=14&container=2034]
Ouadi BEL
2013-03-21 01:29:42 UTC
Permalink
Ouadi BEL [https://community.jboss.org/people/ouadi_dev] created the discussion

"Re: No current status match exception."

To view the discussion, visit: https://community.jboss.org/message/803938#803938

--------------------------------------------------------------
Hi https://community.jboss.org/people/arselv Dsire krish
Maybe its too late but i wanna share my solution for others

I had the same issue but i solve the problem by modifing

jbpm-human-task-core-5.4.0.Final.jar : org/jbpm/task/service/operations-dsl.mvel

file
You can change the operation requirements in this file

Operation.Start
        : [ new OperationCommand().{
                status = [ Status.Ready ],
                allowed = [ Allowed.PotentialOwner ],
                setNewOwnerToUser = true,
                newStatus = Status.InProgress
            },
            new OperationCommand().{
                status = [ Status.Reserved ],
                allowed = [ Allowed.Owner, *Allowed.PotentialOwner* ], 
                newStatus = Status.InProgress
            } ],    

this solved my problem.
--------------------------------------------------------------

Reply to this message by going to Community
[https://community.jboss.org/message/803938#803938]

Start a new discussion in jBPM at Community
[https://community.jboss.org/choose-container!input.jspa?contentType=1&containerType=14&container=2034]
Loading...