<?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 Executing an action in asynchronous mode in Alfresco Archive</title>
    <link>https://connect.hyland.com/t5/alfresco-archive/executing-an-action-in-asynchronous-mode/m-p/223801#M176931</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;SPAN&gt;I have an action that works in batch mode configured as a scheduled action. I would like to call the same action from a webscript. &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;{{{&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;var rssImport = actions.create("importerPressReviewAction");&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;rssImport.parameters.dateFrom = dateFrom ;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;rssImport.parameters.dateTo = dateTo ;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;rssImport.parameters.mailTo = person.properties["cm:email"];&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&lt;SPAN&gt;rssImport.parameters.mailFrom = "&lt;/SPAN&gt;&lt;A class="jive-link-email-small" href="mailto:my@email.com" rel="nofollow noopener noreferrer"&gt;my@email.com&lt;/A&gt;&lt;SPAN&gt;";&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;rssImport.execute(companyhome);&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;}}}&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;The problem is that take a lot of time and the webscript request ends with a timeout. Exists a solutions to launch the action in asynchronous mode? I found this link &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;A href="http://wiki.alfresco.com/wiki/3.0_JavaScript_API_for_Rules_and_Actions#Add_to_ScriptNode_API" rel="nofollow noopener noreferrer"&gt;http://wiki.alfresco.com/wiki/3.0_JavaScript_API_for_Rules_and_Actions#Add_to_ScriptNode_API&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;but seems that&amp;nbsp; methods doen't exists on ScriptNode object.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Andrea&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 09 Mar 2010 16:51:20 GMT</pubDate>
    <dc:creator>andrepra</dc:creator>
    <dc:date>2010-03-09T16:51:20Z</dc:date>
    <item>
      <title>Executing an action in asynchronous mode</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/executing-an-action-in-asynchronous-mode/m-p/223801#M176931</link>
      <description>Hi,I have an action that works in batch mode configured as a scheduled action. I would like to call the same action from a webscript. {{{var rssImport = actions.create("importerPressReviewAction");rssImport.parameters.dateFrom = dateFrom ;rssImport.parameters.dateTo = dateTo ;rssImport.parameters.ma</description>
      <pubDate>Tue, 09 Mar 2010 16:51:20 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/executing-an-action-in-asynchronous-mode/m-p/223801#M176931</guid>
      <dc:creator>andrepra</dc:creator>
      <dc:date>2010-03-09T16:51:20Z</dc:date>
    </item>
    <item>
      <title>Re: Executing an action in asynchronous mode</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/executing-an-action-in-asynchronous-mode/m-p/223802#M176932</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Yes.&amp;nbsp; I agree that the JavaScript methods don't exist.&amp;nbsp; I've deleted that page to avoid further confusion. &lt;img id="smileysad" class="emoticon emoticon-smileysad" src="https://connect.hyland.com/i/smilies/16x16_smiley-sad.png" alt="Smiley Sad" title="Smiley Sad" /&gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;The slightly better news is that the action service does support running actions asynchronously and it should be an easy enhancement.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 09 Mar 2010 17:12:49 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/executing-an-action-in-asynchronous-mode/m-p/223802#M176932</guid>
      <dc:creator>mrogers</dc:creator>
      <dc:date>2010-03-09T17:12:49Z</dc:date>
    </item>
  </channel>
</rss>

