JBoss Community

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

created by Maurice de Chateau in jBPM - View the full discussion

Hi Yogita,

 

First off, I'd be really asking myself why you cannot use regular Nodes, as these are the exact node type that is intended for this type of work. Without any reason for that, I can't help you on that - but it actually seems the right thing to find out here.

 

If you want to get out of a TaskNode programmaticaly, leaving the node yourself is not the best way, as this leaves the TaskNode's internal administration in an undefined state (hence the null). What you should do is to call the end() method on the TaskInstance, and allow the TaskNode to close shop itself before moving on.

 

Hope this helps a bit!

 

Regards,

Maurice

Reply to this message by going to Community

Start a new discussion in jBPM at Community