[jbpm-users] [JBoss jBPM] - Re: JbpmContext usage & best practices
apdo
do-not-reply at jboss.com
Wed Feb 25 09:30:01 EST 2009
We are using jbpm with EJB3. we use jbpm beind SLSB
Here is a solution that we have implemented.
We have implemented an Interceptor (using jboss AOP) that identify when it exit from the latest layer of a SLSB (exit from the business layer). When the aspect identify that the execution path is going to exit from the business layer it close the ejbcontext.
In the Interceptor, we identify when we exit from the first called SLSB (exit from the business layer) by using a counter in the Interceptor. the counter is incremented when entering in the aspect and in the finaly block, if the counter is 0 the jbpmcontext is closed if it has been opened during the transaction.
It will have been easier to register a listener to the jboss transaction but I didn`t find anyway to do it. Is there a way to doing it?
An Phong Do
www.solabs.com
View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4213004#4213004
Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=4213004
More information about the jbpm-users
mailing list