[jboss-user] [jBPM] - Re: Dispose of knowledgeSession when use with persistence

Andy Yeung do-not-reply at jboss.com
Tue Nov 8 22:58:58 EST 2011

Andy Yeung [http://community.jboss.org/people/andy.yeung] created the discussion

"Re: Dispose of knowledgeSession when use with persistence"

To view the discussion, visit: http://community.jboss.org/message/635634#635634

I did the following to make this issue gone. I am not quite certain that if every steps needed to be done or not.

1. I added a CountDownLatch in BlockingCommandBasedWSHumanTaskHandler and let my main thread to wait for it. In the GetCompletedTaskResponseHandler and GetResultContentResponseHandler handler I execute countDown based on the result to release the lock to ensure the response handler completed before I dispose the session in main thread.

2. I move the transaction scope to wrap my whole complete task logic.

3. I also find that it was triggering multiple callback to TaskCompletedHandler due to some reason. I partially fix that part.

Reply to this message by going to Community

Start a new discussion in jBPM at Community

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-user/attachments/20111108/60df2b86/attachment.html 

More information about the jboss-user mailing list