1 Reply Latest reply on Nov 16, 2012 9:48 PM by Tomohisa igarashi

    Separate transaction with bpm persistent=true

    Calvin Chu Newbie

      My SwitchYard project contains a bpm component, we ahich reference SwitchYard servicnd such SwitchYard service would access database with it's own persistent-unit. Without enabling the persistent in bpm component, everything are fine and I am able to manage the transaction of my non-jta-data-source. (I can use EntityManager em.getTransaction().commit() ; )


      But with persistent = true in my bpm component, my non-jta-data-source stop working as jBPM have definited a JTA transaction such that I cannot manage my own transaction. (again, my dataservice is called within jBPM workflow, by the SwitchYardServiceTaskHandler provided). I can only change my persistent-unit to JTA and use the same transaction as jBPM. But I don't want to tide my transaction with jBPM, indeed, I need to commit within my dataservice which terminated the transaction of jBPM and cause some other errors.


      My question is, is there any way to isolate the transaction of my non-jta-data-source under the JTA transaction of jBPM? Any idea ? Thanks in advance.