<?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: SQL Deadlock in Alfresco Archive</title>
    <link>https://connect.hyland.com/t5/alfresco-archive/sql-deadlock/m-p/24148#M11761</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;Well, the reason why it is a bad practice, is because the API call will also create a new transaction; new commandcontext, etc.&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;SPAN&gt;I don't understand this…&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;If I call to API inside a JavaDelegate class, for sample create a processinstance… then… I'm using the same transaction … is it true??&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I think that maybe is useful a small documentation about activiti transactions.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 05 Jan 2011 15:51:48 GMT</pubDate>
    <dc:creator>jcosano</dc:creator>
    <dc:date>2011-01-05T15:51:48Z</dc:date>
    <item>
      <title>SQL Deadlock</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/sql-deadlock/m-p/24144#M11757</link>
      <description>I am hitting a deadlock at a point where 2 threads start processes in quick succession. 9 times out of 10 it is fine, but on occasions I get the deadlock below.It looks like one thread is starting a process while another is setting variables? I guess I am doing something wrong, any pointers on what</description>
      <pubDate>Wed, 29 Dec 2010 13:19:15 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/sql-deadlock/m-p/24144#M11757</guid>
      <dc:creator>pault</dc:creator>
      <dc:date>2010-12-29T13:19:15Z</dc:date>
    </item>
    <item>
      <title>Re: SQL Deadlock</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/sql-deadlock/m-p/24145#M11758</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I read in a reply elsewhere :&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;Using the activiti API from within activiti-context (JavaDelegate or TaskListeners) is a bad idea, this can mess up command-context and transactions in activiti. When you start a process-instance this way, the thread that drives the execution (which is used to invoke your code) will be used to run the spawned process instance (until it ends or reaches a wait-state).&lt;/BLOCKQUOTE&gt;&lt;SPAN&gt;Could&amp;nbsp; this is my problem too ? I am starting a process from an object instantiated by a Java Service task. The requirement is to start an exception process in response to some condition, but in a different PVM, so I dont think it can be modelled in the process.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;So I think I need to put something like a message queue in between, or somehow force a it onto a new thread in the service task.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;In the quote above it says using the API within a JavaDelegate is a bad idea - am I correct in saying that is just those API calls that result in data being committed ?&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 05 Jan 2011 08:28:53 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/sql-deadlock/m-p/24145#M11758</guid>
      <dc:creator>pault</dc:creator>
      <dc:date>2011-01-05T08:28:53Z</dc:date>
    </item>
    <item>
      <title>Re: SQL Deadlock</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/sql-deadlock/m-p/24146#M11759</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;It looks like you are indeed trying to lock the same entity in different threads,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;hence the reason why it sometimes works and sometimes not.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;Could this is my problem too ? I am starting a process from an object instantiated by a Java Service task. The requirement is to start an exception process in response to some condition, but in a different PVM, so I dont think it can be modelled in the process.&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;SPAN&gt;Do you mean starting a process on another Activiti instance?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;So I think I need to put something like a message queue in between, or somehow force a it onto a new thread in the service task.&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;SPAN&gt;A message queue would be a solution; albeit a heavy one.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;It should be possible just to start a new process from a service task.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;In the quote above it says using the API within a JavaDelegate is a bad idea - am I correct in saying that is just those API calls that result in data being committed ?&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;SPAN&gt;Well, the reason why it is a bad practice, is because the API call will also create a new transaction; new commandcontext, etc.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;For a workaround: check how the startProcessInstanceXX actually is run behind the scenes, and call that method.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 05 Jan 2011 14:36:51 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/sql-deadlock/m-p/24146#M11759</guid>
      <dc:creator>jbarrez</dc:creator>
      <dc:date>2011-01-05T14:36:51Z</dc:date>
    </item>
    <item>
      <title>Re: SQL Deadlock</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/sql-deadlock/m-p/24147#M11760</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Thanks for the info. I think it gives me enough to work on and understand what is happening. Though having turned off the history service in the process engine that had the issue (it doesn't need it in any case), I haven't seen the problem since.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;Do you mean starting a process on another Activiti instance&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;SPAN&gt;In the example I am working on I have an application that is implemented as Activiti processes, and which interacts with other Activiti processes (outside my application) that may be running in different process engines. So yes it may be in another process engine instance.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 05 Jan 2011 15:18:03 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/sql-deadlock/m-p/24147#M11760</guid>
      <dc:creator>pault</dc:creator>
      <dc:date>2011-01-05T15:18:03Z</dc:date>
    </item>
    <item>
      <title>Re: SQL Deadlock</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/sql-deadlock/m-p/24148#M11761</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;Well, the reason why it is a bad practice, is because the API call will also create a new transaction; new commandcontext, etc.&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;SPAN&gt;I don't understand this…&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;If I call to API inside a JavaDelegate class, for sample create a processinstance… then… I'm using the same transaction … is it true??&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I think that maybe is useful a small documentation about activiti transactions.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 05 Jan 2011 15:51:48 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/sql-deadlock/m-p/24148#M11761</guid>
      <dc:creator>jcosano</dc:creator>
      <dc:date>2011-01-05T15:51:48Z</dc:date>
    </item>
    <item>
      <title>Re: SQL Deadlock</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/sql-deadlock/m-p/24149#M11762</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Depending on your configuration, it will run in the same transaction. If your are using the default standalone config, all is fine transaction-wise.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;However, there are a few things going on when you call the API, which might screw it. We advise not to do it, since we havent tested it enought yet to be satisfied.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 06 Jan 2011 09:10:17 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/sql-deadlock/m-p/24149#M11762</guid>
      <dc:creator>jbarrez</dc:creator>
      <dc:date>2011-01-06T09:10:17Z</dc:date>
    </item>
  </channel>
</rss>

