[jboss-user] [JBoss jBPM] - concurrency question

twiceknightly do-not-reply at jboss.com
Tue Feb 5 10:04:13 EST 2008


Hi,

I want to write a plugin that I can call to persist my domain objects from within an action.  I want to build on the jbpm hibernate code so that my updating of domain objects happens within the same transaction/hibernate session as the jbpm stuff.  Will something like the following bit of code get me the hibernate session for the current thread?

JbpmConfiguration.getInstance().getCurrentJbpmContext().getPersistenceService().getSession()

Is there any concurrency concerns?  The reason I ask is the way the current code uses thread locals.  My understanding is that there is a jbpmContext per thread via a thread local in JbpmConfiguration.  

cheers!
 

View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4126568#4126568

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4126568



More information about the jboss-user mailing list