JBoss Community

Re: Issue in leavenode from a Task node on task-create event

created by Yogita Bartake in jBPM - View the full discussion

Thanks for the Reply :)

 

We tried using node for automatic activities but our application needs to show the history of what path a process execution has taken. With node we did not find any jbpm table which would show the log of executed nodes.

So we took this approach...If u know of any other solution for this please do let me know.

 

Well, we tried using taskInstance.end() in the Action handler but it gave Null pointer exception since in the handler was being called on a task-create event. Then we tried using the same in the class that implements AssignmentHandler. In this case what happens is that the execution moves ahead from the task till it gets user activity(for which the AssignmentHandler class is not mapped) but the execution starts again from the 1st automatic activity from where we are doing taskInstance.end() and goes in an infinite loop.

 

E.g

 

public class TaskAssignHandler implements AssignmentHandler

{

private static final long serialVersionUID = 1L;

public void assign(Assignable assignable, ExecutionContext executionContext)

{     

 

 

}

 

 

 

I am assuming here that the AssignmentHandler(which I have mapped in that Handler Property of the task) class gets called on task-assign event and by this time the task has got created for me to end it from here. Please correct me if I my assumption is incorrect.



Thanks a lot!! :)



Regards,

Yogita

 

 

     executionContext.getTaskInstance().end();

 

Reply to this message by going to Community

Start a new discussion in jBPM at Community