6 Replies Latest reply on Nov 16, 2009 2:05 PM by kukeltje

    jBPM 3.2.6.SP1 enterprise environments question

    salaboy21

      Hi all,
      I'm working with the tag jBPM 3.2.6.SP1, (http://anonsvn.jboss.org/repos/jbpm/jbpm3/tags/jbpm-3.2.6.SP1/) and a big question arise.
      I have an example about a Stateless Session bean that will use the jBPM APIs to interact with processes. The configurations of the example uses:

      <service name="persistence" factory="org.jbpm.persistence.jta.JtaDbPersistenceServiceFactory" />
      


      and in hibernate.cfg.xml:

       <!-- CMT transaction properties (begin) === -->
       <property name="hibernate.transaction.factory_class">org.hibernate.transaction.CMTTransactionFactory</property>
       <property name="hibernate.transaction.manager_lookup_class">org.hibernate.transaction.JBossTransactionManagerLookup</property>
       <!-- ==== CMT transaction properties (end) -->
      


      Basically, I want to delegate the transactions administration to the container.
      Now in my Stateless Session bean, I have some methods that will use the jBPM API's and I don't want to create the jBPMContext each time inside each method of my Stateless Session Bean. It's that possible? right now with 3.2.6.SP1 version, I need to create inside each method the context in order to work.

      Thanks in advance.