<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Activiti transaction + JEE transactions in Alfresco Archive</title>
    <link>https://connect.hyland.com/t5/alfresco-archive/activiti-transaction-jee-transactions/m-p/61769#M38396</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Thanks Tijs. Yes the CDI support is certainly very useful as a starting point.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Regards&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp; James&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 12 Jan 2012 13:41:40 GMT</pubDate>
    <dc:creator>jsher</dc:creator>
    <dc:date>2012-01-12T13:41:40Z</dc:date>
    <item>
      <title>Activiti transaction + JEE transactions</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/activiti-transaction-jee-transactions/m-p/61765#M38392</link>
      <description>Hi,Apologies for these basic questions - I have limited JEE knowledge, but here goes…I am trying to build a picture of how Activiti will behave in a JEE setting, particularly from a persistence/transactions point of view. I am considering only JEE6 container managed persistence for the moment. I see</description>
      <pubDate>Tue, 03 Jan 2012 15:49:41 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/activiti-transaction-jee-transactions/m-p/61765#M38392</guid>
      <dc:creator>jsher</dc:creator>
      <dc:date>2012-01-03T15:49:41Z</dc:date>
    </item>
    <item>
      <title>Re: Activiti transaction + JEE transactions</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/activiti-transaction-jee-transactions/m-p/61766#M38393</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hi,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Did you look at the Activiti CDI module? Because this provides integration with JEE 6 and EJB's.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Best regards,&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 05 Jan 2012 18:28:09 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/activiti-transaction-jee-transactions/m-p/61766#M38393</guid>
      <dc:creator>trademak</dc:creator>
      <dc:date>2012-01-05T18:28:09Z</dc:date>
    </item>
    <item>
      <title>Re: Activiti transaction + JEE transactions</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/activiti-transaction-jee-transactions/m-p/61767#M38394</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hi James,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Q1 yes&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Q2 yes&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Q3 We do not provide support for this. You could write your own JobExecutor and delegate Job acquisition &amp;amp; execution to JEE-container-managed threads there. &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Q4 If you configure activiti with JTA, a JTA transaction will be opened for executing the job and if you invoke a SessionBean, the transaction context will be propagated to that bean.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 05 Jan 2012 20:11:47 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/activiti-transaction-jee-transactions/m-p/61767#M38394</guid>
      <dc:creator>meyerd</dc:creator>
      <dc:date>2012-01-05T20:11:47Z</dc:date>
    </item>
    <item>
      <title>Re: Activiti transaction + JEE transactions</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/activiti-transaction-jee-transactions/m-p/61768#M38395</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Maybe as an additional side note: &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;- we are currentls looking into refactoring the JobExecutor, so that self-management of Threads is factored out and you can plugin your own Thread-management strategy: ACT-34&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;- I will write a bolg post shortly on activiti integration with websphere application server 8.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 05 Jan 2012 20:14:25 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/activiti-transaction-jee-transactions/m-p/61768#M38395</guid>
      <dc:creator>meyerd</dc:creator>
      <dc:date>2012-01-05T20:14:25Z</dc:date>
    </item>
    <item>
      <title>Re: Activiti transaction + JEE transactions</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/activiti-transaction-jee-transactions/m-p/61769#M38396</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Thanks Tijs. Yes the CDI support is certainly very useful as a starting point.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Regards&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp; James&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 12 Jan 2012 13:41:40 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/activiti-transaction-jee-transactions/m-p/61769#M38396</guid>
      <dc:creator>jsher</dc:creator>
      <dc:date>2012-01-12T13:41:40Z</dc:date>
    </item>
    <item>
      <title>Re: Activiti transaction + JEE transactions</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/activiti-transaction-jee-transactions/m-p/61770#M38397</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Thanks Daniel for your very helpful replies.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Q3&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;- re. writing my own JobExecutor… I suspect that JobExecutor is not pluggable currently so I guess this would require custom changes to Activiti which I wouldn't be too keen to do having limited knowledge of the internals. Ideally the experts like yourselves&amp;nbsp; &lt;img id="smileyhappy" class="emoticon emoticon-smileyhappy" src="https://connect.hyland.com/i/smilies/16x16_smiley-happy.png" alt="Smiley Happy" title="Smiley Happy" /&gt; would provide such functionality assuming of course there are sufficient requests for this type of feature.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Q4&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;- I'm still unsure though if there is an issue with a thread not managed by the container (assuming I don't do custom JobExecutor) invoking EJBs. I need to dig into JEE/EJB more to answer this - or maybe someone reading this knows the answer ?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Regards&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; James&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 12 Jan 2012 13:51:12 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/activiti-transaction-jee-transactions/m-p/61770#M38397</guid>
      <dc:creator>jsher</dc:creator>
      <dc:date>2012-01-12T13:51:12Z</dc:date>
    </item>
    <item>
      <title>Re: Activiti transaction + JEE transactions</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/activiti-transaction-jee-transactions/m-p/61771#M38398</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hi James,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;Q3&lt;BR /&gt;- re. writing my own JobExecutor… I suspect that JobExecutor is not pluggable currently so I guess this would require custom changes to Activiti which I wouldn't be too keen to do having limited knowledge of the internals. Ideally the experts like yourselves &lt;img id="smileyhappy" class="emoticon emoticon-smileyhappy" src="https://connect.hyland.com/i/smilies/16x16_smiley-happy.png" alt="Smiley Happy" title="Smiley Happy" /&gt; would provide such functionality assuming of course there are sufficient requests for this type of feature.&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;SPAN&gt;I will merge branch ACT-34 shortly, that will make it a lot easyer to implement JobExecutor delegating to Threads of your choice (ie. "supported", Container-Managed Threads in an App Server)&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 12 Jan 2012 14:35:00 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/activiti-transaction-jee-transactions/m-p/61771#M38398</guid>
      <dc:creator>meyerd</dc:creator>
      <dc:date>2012-01-12T14:35:00Z</dc:date>
    </item>
    <item>
      <title>Re: Activiti transaction + JEE transactions</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/activiti-transaction-jee-transactions/m-p/61772#M38399</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;Maybe as an additional side note: &lt;BR /&gt;- we are currentls looking into refactoring the JobExecutor, so that self-management of Threads is factored out and you can plugin your own Thread-management strategy: ACT-34&lt;BR /&gt;- I will write a bolg post shortly on activiti integration with websphere application server 8.&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;SPAN&gt;Wondering if thread management is pluggable in 5.8. We might want to use spring task executor.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 12 Jan 2012 15:20:47 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/activiti-transaction-jee-transactions/m-p/61772#M38399</guid>
      <dc:creator>pangea</dc:creator>
      <dc:date>2012-01-12T15:20:47Z</dc:date>
    </item>
    <item>
      <title>Re: Activiti transaction + JEE transactions</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/activiti-transaction-jee-transactions/m-p/61773#M38400</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hi pangea,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;not in 5.8&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 12 Jan 2012 15:30:00 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/activiti-transaction-jee-transactions/m-p/61773#M38400</guid>
      <dc:creator>meyerd</dc:creator>
      <dc:date>2012-01-12T15:30:00Z</dc:date>
    </item>
    <item>
      <title>Re: Activiti transaction + JEE transactions</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/activiti-transaction-jee-transactions/m-p/61774#M38401</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;Hi pangea,&lt;BR /&gt;&lt;BR /&gt;not in 5.8&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;SPAN&gt;Could you please let me know the approximate version when this will be included?&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 12 Jan 2012 15:31:52 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/activiti-transaction-jee-transactions/m-p/61774#M38401</guid>
      <dc:creator>pangea</dc:creator>
      <dc:date>2012-01-12T15:31:52Z</dc:date>
    </item>
    <item>
      <title>Re: Activiti transaction + JEE transactions</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/activiti-transaction-jee-transactions/m-p/61775#M38402</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;Hi James,&lt;BR /&gt;&lt;BR /&gt;I will merge branch ACT-34 shortly, that will make it a lot easyer to implement JobExecutor delegating to Threads of your choice (ie. "supported", Container-Managed Threads in an App Server)&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;SPAN&gt;Daniel, will these scheme work for jobs initiated by timer events (boundary, intermediate) ? What I mean is we need to have Activiti continue to execute tasks which flow from timer events as it does currently but to do so in CM threads. The custom JobExecutor would only provide CM thread to Activiti when timer event fires, Activiti then continues to execute the flow as defined in the process.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Does this make sense ?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Regards&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp; James&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 12 Jan 2012 17:18:34 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/activiti-transaction-jee-transactions/m-p/61775#M38402</guid>
      <dc:creator>jsher</dc:creator>
      <dc:date>2012-01-12T17:18:34Z</dc:date>
    </item>
    <item>
      <title>Re: Activiti transaction + JEE transactions</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/activiti-transaction-jee-transactions/m-p/61776#M38403</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hi,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;This topic is useful but I'm still unsure about the behaviour of Activiti in regard to JTA Transactions. I have the same setup as the original poster's:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;JtaProcessEngineConfiguration, transactionsExternallyManaged=true&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;some part of my process definition setup is such:&lt;/SPAN&gt;&lt;BR /&gt;&lt;CODE&gt;+—————————————————–+&lt;BR /&gt;|&amp;nbsp; user_task_a –&amp;gt; service_task –&amp;gt; user_task_b&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; |&lt;BR /&gt;|&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; +—+&lt;BR /&gt;|&amp;nbsp;&amp;nbsp;&amp;nbsp; [Error boundary event]&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; |&amp;nbsp;&amp;nbsp; |&lt;BR /&gt;+————-|—————————————+&amp;nbsp;&amp;nbsp; |&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; |&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; |&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; +–&amp;gt;handle_error—————————-+–&amp;gt;O&lt;/CODE&gt;&lt;BR /&gt;&lt;SPAN&gt;In the JavaDelegate of &lt;/SPAN&gt;&lt;EM&gt;service_task&lt;/EM&gt;&lt;SPAN&gt; I call EJB methods with default &lt;/SPAN&gt;&lt;EM&gt;transaction attribute: Required&lt;/EM&gt;&lt;SPAN&gt;.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Q1) When I complete user_task_a from Activiti GUI will I have a started transaction in the service_task?&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Q2) When I complete user_task_a from code in my own service layer, will I have a transaction in the service_task?&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Q3) When I complete user_task_a from code within EJB that started a transaction, will activiti use this transaction or create a new one?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Q4) If There is already a started transaction in the service_task – assumingly activiti already started one at the completion of user_task_a – in which I invoke the EJB. And EJB throws EJBTransactionRolledBack exception, will it roll back the transaction started by activiti?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;My use case is that we have several service tasks, that may generate errors. What we do is we create our process definitions in a subprocess and use an &lt;/SPAN&gt;&lt;EM&gt;Error boundary event&lt;/EM&gt;&lt;SPAN&gt; that leads to a "handle error" user task in case any error. &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;The scenario is this: If something goes wrong in service task, we catch the exception, set a variable and throw a BpmnError exception to fall into the "handle error" task.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;My problem is that I don't see right now if an error happens in my EJB that is called from service task, how it will affect the workflow. If the error triggers a transaction rollback, will it roll back the activiti transaction as well and eventually the state won't change?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;My solution would be this to my problem: I would set the transactionAttribute of my EJB called from service task to "requiresNew". This way if something goes wrong in the EJB, it will not affect the activiti transaction.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Any suggestions about this approach?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thank you for your help!&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 21 Oct 2012 13:36:09 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/activiti-transaction-jee-transactions/m-p/61776#M38403</guid>
      <dc:creator>pkonyves</dc:creator>
      <dc:date>2012-10-21T13:36:09Z</dc:date>
    </item>
    <item>
      <title>Re: Activiti transaction + JEE transactions</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/activiti-transaction-jee-transactions/m-p/61777#M38404</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;UL&gt;&lt;LI&gt;Q1: Yes, activiti will request a new transaction from the underlying transaction mechanism, in your case, JTA&lt;/LI&gt;&lt;BR /&gt;&lt;LI&gt;Q2: If your own service-layer uses JTA-transactions, activiti (when completing task) will use the existing JTA-trasaction (underlying transaction-mechanism returns the active one to activiti). If your own service IS NOT transactional, activiti will get a new JTA-transactions as wit Q1.&lt;/LI&gt;&lt;BR /&gt;&lt;LI&gt;Q3: If the EJB uses JTA, then yes, activiti will participate in this transaction.&lt;/LI&gt;&lt;BR /&gt;&lt;LI&gt;Q4: That's what JTA is for… If configured correctly (using XA if needed), exceptions in YOUR code or Activiti code will roll back both. So when "completing" a task and an exception is thorn somewhere while executing the process, it's rolled back to the initial state. So the "complete" never happened &lt;img id="smileywink" class="emoticon emoticon-smileywink" src="https://connect.hyland.com/i/smilies/16x16_smiley-wink.png" alt="Smiley Wink" title="Smiley Wink" /&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;SPAN&gt;If you're service-calls to EJB and it throws an exception, it's very likely that the proxy around the EJB will cause the transaction to be marked as "rollback only", depending on the configuration of the EJB and the rollback-behaviour. So if you want to have your EJB be rolled back, but you're handling the error inside the process (BPMNError) it makes sense to use a new transaction for the service-call. However, it's not guaranteed that these 2 transactions (in case of success) both get committed… This may cause invalid state in your process vs. your own model&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 22 Oct 2012 09:21:07 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/activiti-transaction-jee-transactions/m-p/61777#M38404</guid>
      <dc:creator>frederikherema1</dc:creator>
      <dc:date>2012-10-22T09:21:07Z</dc:date>
    </item>
    <item>
      <title>Re: Activiti transaction + JEE transactions</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/activiti-transaction-jee-transactions/m-p/61778#M38405</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;STRONG&gt;frederikheremans:&lt;/STRONG&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks for clearing these up. I'm familiar with JTA in the context of EJBs, but was not sure how it cooperates with activiti.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I'm now concerned about this &lt;/SPAN&gt;&lt;EM&gt;"it's not guaranteed that these 2 transactions (in case of success) both get committed"&lt;/EM&gt;&lt;SPAN&gt;.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;In which cases does not both transactions will be committed? It would be essential to know if I go with this approach.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Do you have a better idea about error handling in service tasks?&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 22 Oct 2012 09:47:55 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/activiti-transaction-jee-transactions/m-p/61778#M38405</guid>
      <dc:creator>pkonyves</dc:creator>
      <dc:date>2012-10-22T09:47:55Z</dc:date>
    </item>
    <item>
      <title>Re: Activiti transaction + JEE transactions</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/activiti-transaction-jee-transactions/m-p/61779#M38406</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;If you have 2 transactions, one for activiti, and another one (forced created by the REQUIRES_NEW) for your beans/services. In case the service-call is done, the REQUIRES_NEW transaction is committed. Then, when activiti engine flows on, it's possible that, after the service-task call, something goes wrong (no DB, another service-task fails, optimistic locking, …) the activiti-transaction is rolled back.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;This leaves your own services' data-mutations committed and activiti's reverted back to the state it was in, causing a difference. So having your services FORCE a new transaction, is generally a bad idea if you want to be absolutely safe. &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Or am I missing something?&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 22 Oct 2012 12:33:27 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/activiti-transaction-jee-transactions/m-p/61779#M38406</guid>
      <dc:creator>frederikherema1</dc:creator>
      <dc:date>2012-10-22T12:33:27Z</dc:date>
    </item>
  </channel>
</rss>

