<?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: Using a folder rule to execute a script from the classpath? in Alfresco Archive</title>
    <link>https://connect.hyland.com/t5/alfresco-archive/using-a-folder-rule-to-execute-a-script-from-the-classpath/m-p/249718#M202848</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hello,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;You can of course add the scripts in your file system in&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;lt;tomcat home&amp;gt;\shared\classes\alfresco\extension\scripts\yourscript.js&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;However the scripts in the file system have a major drawback: every time you update a script, you have to fully restart your server.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 21 Aug 2012 14:35:26 GMT</pubDate>
    <dc:creator>scouil</dc:creator>
    <dc:date>2012-08-21T14:35:26Z</dc:date>
    <item>
      <title>Using a folder rule to execute a script from the classpath?</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/using-a-folder-rule-to-execute-a-script-from-the-classpath/m-p/249717#M202847</link>
      <description>I would like to use a folder rule to trigger a script, using the normal "Manage Rules" wizard. The pull down menu for "Execute Script" seem to be populated from the scripts in Data Dictionary/Scripts in the repository - this all works fine.However, is there a way to include scripts from the classpat</description>
      <pubDate>Tue, 21 Aug 2012 11:13:26 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/using-a-folder-rule-to-execute-a-script-from-the-classpath/m-p/249717#M202847</guid>
      <dc:creator>dnallsopp</dc:creator>
      <dc:date>2012-08-21T11:13:26Z</dc:date>
    </item>
    <item>
      <title>Re: Using a folder rule to execute a script from the classpath?</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/using-a-folder-rule-to-execute-a-script-from-the-classpath/m-p/249718#M202848</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hello,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;You can of course add the scripts in your file system in&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;lt;tomcat home&amp;gt;\shared\classes\alfresco\extension\scripts\yourscript.js&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;However the scripts in the file system have a major drawback: every time you update a script, you have to fully restart your server.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 21 Aug 2012 14:35:26 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/using-a-folder-rule-to-execute-a-script-from-the-classpath/m-p/249718#M202848</guid>
      <dc:creator>scouil</dc:creator>
      <dc:date>2012-08-21T14:35:26Z</dc:date>
    </item>
    <item>
      <title>Re: Using a folder rule to execute a script from the classpath?</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/using-a-folder-rule-to-execute-a-script-from-the-classpath/m-p/249719#M202849</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;I tried adding a script to:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;STRONG&gt;&amp;nbsp; /opt/alfresco-4.0.e/tomcat/shared/classes/alfresco/extension/scripts/&lt;/STRONG&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;and restarting the server, but no luck -&amp;nbsp; the script doesn't seem to be picked up by the menu in &lt;/SPAN&gt;&lt;EM&gt;Edit Rule-&amp;gt;Perform Action-&amp;gt;Execute Script&lt;/EM&gt;&lt;SPAN&gt;. &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Only the "Start Pooled Review and Approve Workflow" script appears in this menu.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I also tried the script in &lt;/SPAN&gt;&lt;STRONG&gt;/opt/alfresco-4.0.e/tomcat/webapps/alfresco/WEB-INF/classes/alfresco/extension/scripts/&lt;/STRONG&gt;&lt;SPAN&gt; and restarting, but again no luck - not sure whether this should have the same effect as putting it in &lt;/SPAN&gt;&lt;STRONG&gt;shared&lt;/STRONG&gt;&lt;SPAN&gt;.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;The script is just a one-liner as shown below, though presumably it makes no difference since it won't be read until execution time:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;PRE class="language-none line-numbers"&gt;&lt;CODE&gt;logger.log('+++ Logging test script +++');&lt;SPAN class="line-numbers-rows"&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 21 Aug 2012 16:37:22 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/using-a-folder-rule-to-execute-a-script-from-the-classpath/m-p/249719#M202849</guid>
      <dc:creator>dnallsopp</dc:creator>
      <dc:date>2012-08-21T16:37:22Z</dc:date>
    </item>
    <item>
      <title>Re: Using a folder rule to execute a script from the classpath?</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/using-a-folder-rule-to-execute-a-script-from-the-classpath/m-p/249720#M202850</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hello.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Then the extension/scripts folder isn't automatically picked up, my bad.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;You probably need to register your action through spring then.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;webapps/alfresco/WEB-INF/classes/alfresco/* is mostly the same as shared/classes/alfresco/extension . However, webapps/alfresco/* is from Alfresco jar and will be lost when you upgrade alfresco that's why the good practice is to put your extensions in shared/*&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Regards,&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 22 Aug 2012 07:23:53 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/using-a-folder-rule-to-execute-a-script-from-the-classpath/m-p/249720#M202850</guid>
      <dc:creator>scouil</dc:creator>
      <dc:date>2012-08-22T07:23:53Z</dc:date>
    </item>
  </channel>
</rss>

