JBoss Community

Re: When to call kSession.dispose()?

created by Sukumaran Raghavan in jBPM - View the full discussion

+1 ....

I use multiple sessions in my application and i dispose these as soon as i create a new process instance (basically each process instance has its own session). Once i register the work item, i dispose the ksession. I have also passed the ksession as a parameter to my work item handlers and they in turn save the ksession. Basically i want to call ksession.getWorkItemManager().completeWorkItem(workItemId).

 

Now i am not sure if that call will work or not. It seems to work which is surprising. especially since i disposed my ksession ?

How does this all work ? A lil clarity would help me make more apt design decisions.

 

Thanks in advance.! !

Reply to this message by going to Community

Start a new discussion in jBPM at Community