<?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: JTA and starting processes in Alfresco Archive</title>
    <link>https://connect.hyland.com/t5/alfresco-archive/jta-and-starting-processes/m-p/121208#M85383</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Ok. So "async" could be a solution. But also in this case where I use a CDI object inside a sequence flow expression to get the information on how to proceed?&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Or what else can I do?&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 07 Mar 2013 15:36:39 GMT</pubDate>
    <dc:creator>tdtappe</dc:creator>
    <dc:date>2013-03-07T15:36:39Z</dc:date>
    <item>
      <title>JTA and starting processes</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/jta-and-starting-processes/m-p/121202#M85377</link>
      <description>I just started using Activiti. So my question(s) might be a bit "strange". Anyway…I am using Activiti embedded in my app in a JTA context. When I for instance create a new order I start an order process via API.The problem: the process starts right away without my order data having been committed ye</description>
      <pubDate>Wed, 06 Mar 2013 10:54:26 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/jta-and-starting-processes/m-p/121202#M85377</guid>
      <dc:creator>tdtappe</dc:creator>
      <dc:date>2013-03-06T10:54:26Z</dc:date>
    </item>
    <item>
      <title>Re: JTA and starting processes</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/jta-and-starting-processes/m-p/121203#M85378</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Why not commit tx then start a process with :&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;CODE&gt;runtimeService.startProcessInstanceByKey( pKey, variables );&lt;/CODE&gt;&lt;BR /&gt;&lt;SPAN&gt;?&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 07 Mar 2013 07:55:53 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/jta-and-starting-processes/m-p/121203#M85378</guid>
      <dc:creator>p4w3l</dc:creator>
      <dc:date>2013-03-07T07:55:53Z</dc:date>
    </item>
    <item>
      <title>Re: JTA and starting processes</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/jta-and-starting-processes/m-p/121204#M85379</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Because it runs in a JTA context. The "container" handles the transactions. And there might be more stuff to do after creating an order for instance. And it should be an "all or nothing" approach.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 07 Mar 2013 08:04:04 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/jta-and-starting-processes/m-p/121204#M85379</guid>
      <dc:creator>tdtappe</dc:creator>
      <dc:date>2013-03-07T08:04:04Z</dc:date>
    </item>
    <item>
      <title>Re: JTA and starting processes</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/jta-and-starting-processes/m-p/121205#M85380</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Activiti allows you to participate in a JTA-transaction, effectively not committing changes manually but relying on the container to do this. You'll have to use the JPAProcessEngineConfiguration instead of the normal one and hook in the transaction manager.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 07 Mar 2013 14:46:04 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/jta-and-starting-processes/m-p/121205#M85380</guid>
      <dc:creator>frederikherema1</dc:creator>
      <dc:date>2013-03-07T14:46:04Z</dc:date>
    </item>
    <item>
      <title>Re: JTA and starting processes</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/jta-and-starting-processes/m-p/121206#M85381</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I know. And that's what I do already: the process engine is configured to use JTA. But the problem is that obviously the process starts immediately and reaches for instance a point in the process where it's necessary to get some information. This information (for a conditional flow) is "fetched" via a CDI function that in turn calls some REST function to get the desired information. But this REST call won't find the current data as the transaction that initiated all this isn't committed yet.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;1) Container starts transaction&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;2) The application creates some data which is persisted (but of course not committed) to the database&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;3) The application then starts a process for this new data object&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;4) Container commits transaction&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;In the context of 3) a REST function call (initiated by the process) reaches the app which then tries to find the object in the database. But of course it isn't there yet =&amp;gt; BANG&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 07 Mar 2013 15:13:18 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/jta-and-starting-processes/m-p/121206#M85381</guid>
      <dc:creator>tdtappe</dc:creator>
      <dc:date>2013-03-07T15:13:18Z</dc:date>
    </item>
    <item>
      <title>Re: JTA and starting processes</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/jta-and-starting-processes/m-p/121207#M85382</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;That's not an activiti-specific problem, that is a generic problem where you try to combine non-transactional calls (REST) with transactional things. A solution would be to make the ServiceTask that is performing the REST-call, asynchronous. This way, when the process is started and reaches that serviceTask, it will be persisted/comitted to the database and the job executor will execute the REST-operation asynchronously in a new transaction. Since the process is now persisted, the REST can access it.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 07 Mar 2013 15:22:35 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/jta-and-starting-processes/m-p/121207#M85382</guid>
      <dc:creator>frederikherema1</dc:creator>
      <dc:date>2013-03-07T15:22:35Z</dc:date>
    </item>
    <item>
      <title>Re: JTA and starting processes</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/jta-and-starting-processes/m-p/121208#M85383</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Ok. So "async" could be a solution. But also in this case where I use a CDI object inside a sequence flow expression to get the information on how to proceed?&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Or what else can I do?&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 07 Mar 2013 15:36:39 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/jta-and-starting-processes/m-p/121208#M85383</guid>
      <dc:creator>tdtappe</dc:creator>
      <dc:date>2013-03-07T15:36:39Z</dc:date>
    </item>
    <item>
      <title>Re: JTA and starting processes</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/jta-and-starting-processes/m-p/121209#M85384</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Make sure the CDI-object in the sequence-flow is AFTER the async-tasks to make sure the REST-call won't fail due to uncommitted data…&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 08 Mar 2013 09:36:33 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/jta-and-starting-processes/m-p/121209#M85384</guid>
      <dc:creator>frederikherema1</dc:creator>
      <dc:date>2013-03-08T09:36:33Z</dc:date>
    </item>
  </channel>
</rss>

