<?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 Secure shutting down the engine in Alfresco Archive</title>
    <link>https://connect.hyland.com/t5/alfresco-archive/secure-shutting-down-the-engine/m-p/137659#M96478</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;first of all: i'm a new to activiti - but used to work for years with jbpm.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;My question:&amp;nbsp; How to shut down the engine without destroying executed serviceTasks.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;All of my serviceTasks are running very short. So - it would be good that if the engine&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;is going to be shut down it won't start any new serviceTasks and will wait for all allready started&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;servicetasks to 'end'.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;My suggested solution to this is to provide a global volatile static variable which is set if i want to shut down the system.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Each 'new' serviceTask (java) will wait forever (in the very first line of code) if this variable is set. So no new funtionallity is&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;run after the 'shutdown' signal was set.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;After a little time - i will shut down the system assuming that all allready 'really' running tasks are completed… and all 'new' running tasks are sleeping before any business functions is started …… which wlll be hopefully started after the system is up again…&amp;nbsp; &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Good or bad idea?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 17 May 2013 08:50:09 GMT</pubDate>
    <dc:creator>martinbauer</dc:creator>
    <dc:date>2013-05-17T08:50:09Z</dc:date>
    <item>
      <title>Secure shutting down the engine</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/secure-shutting-down-the-engine/m-p/137659#M96478</link>
      <description>Hi,first of all: i'm a new to activiti - but used to work for years with jbpm.My question:&amp;nbsp; How to shut down the engine without destroying executed serviceTasks.All of my serviceTasks are running very short. So - it would be good that if the engineis going to be shut down it won't start any new serv</description>
      <pubDate>Fri, 17 May 2013 08:50:09 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/secure-shutting-down-the-engine/m-p/137659#M96478</guid>
      <dc:creator>martinbauer</dc:creator>
      <dc:date>2013-05-17T08:50:09Z</dc:date>
    </item>
    <item>
      <title>Re: Secure shutting down the engine</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/secure-shutting-down-the-engine/m-p/137660#M96479</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Remark: What happens after a&amp;nbsp; ProcessEngines.destroy();&amp;nbsp; &lt;/SPAN&gt;&lt;BR /&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 17 May 2013 09:13:00 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/secure-shutting-down-the-engine/m-p/137660#M96479</guid>
      <dc:creator>martinbauer</dc:creator>
      <dc:date>2013-05-17T09:13:00Z</dc:date>
    </item>
    <item>
      <title>Re: Secure shutting down the engine</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/secure-shutting-down-the-engine/m-p/137661#M96480</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Another option is to make the service task async. The thread pool that executes the async jobs does a graceful shut down when the process engine is closed. Of course a kind of 'barrier' as you describe could also work, but I'm unsure if a volatile property is the best way to do that).&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;The ProcessEngines.destroy() will close() all process engines it knows of.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 21 May 2013 15:51:50 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/secure-shutting-down-the-engine/m-p/137661#M96480</guid>
      <dc:creator>jbarrez</dc:creator>
      <dc:date>2013-05-21T15:51:50Z</dc:date>
    </item>
    <item>
      <title>Re: Secure shutting down the engine</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/secure-shutting-down-the-engine/m-p/137662#M96481</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Thank you.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 24 May 2013 17:09:43 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/secure-shutting-down-the-engine/m-p/137662#M96481</guid>
      <dc:creator>martinbauer</dc:creator>
      <dc:date>2013-05-24T17:09:43Z</dc:date>
    </item>
  </channel>
</rss>

