<?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 Programmatically add File System Receivers to Web Projects? in Alfresco Archive</title>
    <link>https://connect.hyland.com/t5/alfresco-archive/programmatically-add-file-system-receivers-to-web-projects/m-p/275358#M228488</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;For the longest time, I've had just 2 web projects in my Alfresco installation and as our business has grown, so too have the number of servers we need to deploy to.&amp;nbsp; Each time we need to&amp;nbsp; add server capacity, our sys admins would go be able to use puppet to quickly push out a new server with an installed File System Receiver, but then they'd manually go in to Alfresco and add a new File System Receiver in our web projects' "Actions -&amp;gt; Edit Web Projects -&amp;gt; Configure Deployment Receivers" page.&amp;nbsp; Over time, we've accumulated about 20 different deployment receivers, duplicated in both web projects.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;We're about to add 4 or more new web projects and the thought of manually adding each FSR to each web project is really unappealing.&amp;nbsp; Is there a programmatic way to do this?&amp;nbsp; Any config file or DB table I can hack?&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 09 Jun 2011 20:41:42 GMT</pubDate>
    <dc:creator>tvaughan77</dc:creator>
    <dc:date>2011-06-09T20:41:42Z</dc:date>
    <item>
      <title>Programmatically add File System Receivers to Web Projects?</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/programmatically-add-file-system-receivers-to-web-projects/m-p/275358#M228488</link>
      <description>Hi,For the longest time, I've had just 2 web projects in my Alfresco installation and as our business has grown, so too have the number of servers we need to deploy to.&amp;nbsp; Each time we need to&amp;nbsp; add server capacity, our sys admins would go be able to use puppet to quickly push out a new server with an</description>
      <pubDate>Thu, 09 Jun 2011 20:41:42 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/programmatically-add-file-system-receivers-to-web-projects/m-p/275358#M228488</guid>
      <dc:creator>tvaughan77</dc:creator>
      <dc:date>2011-06-09T20:41:42Z</dc:date>
    </item>
    <item>
      <title>Re: Programmatically add File System Receivers to Web Projects?</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/programmatically-add-file-system-receivers-to-web-projects/m-p/275359#M228489</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;There's nothing out of the box.&amp;nbsp;&amp;nbsp;&amp;nbsp; However the deployment config is just a child node of the web project node with a particular content model and assoc.&amp;nbsp;&amp;nbsp;&amp;nbsp; You could write a web script to create one.&amp;nbsp; &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;The code that will do it for you see CreateWebsiteWizard.java and EditWebsiteWizard.java&amp;nbsp;&amp;nbsp; (And yes it needs a re-factor :cry: )&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 10 Jun 2011 08:17:16 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/programmatically-add-file-system-receivers-to-web-projects/m-p/275359#M228489</guid>
      <dc:creator>mrogers</dc:creator>
      <dc:date>2011-06-10T08:17:16Z</dc:date>
    </item>
    <item>
      <title>Re: Programmatically add File System Receivers to Web Projects?</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/programmatically-add-file-system-receivers-to-web-projects/m-p/275360#M228490</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Below is how you can achieve this programatically.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;1. Write a Java backed webscript&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;2. The backend java class for webscript will read the webproject dns name passed as a webscript argument.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;3. It will fetch the webproject noderef using webproject service.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;4. Create an XML file to configure deployment receivers to be read programatically.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;5. Create DeploymentServerConfig objects and set the required deployment receiver properties accrodingly after reading from the XML file.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;6. Add the Deployment receiver to the webproject as below&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;this.serviceRegistry.getNodeService().createNode(WebProjectNodeRef, WCMAppModel.ASSOC_DEPLOYMENTSERVER, WCMAppModel.ASSOC_DEPLOYMENTSERVER, WCMAppModel.TYPE_DEPLOYMENTSERVER, DeploymentServerConfig.getRepoProps());&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;You may get a clear idea if you refer to saveDeploymentServerConfig() in CreateWebSiteWizard.java.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Hope it helps.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 05 Jul 2011 09:18:32 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/programmatically-add-file-system-receivers-to-web-projects/m-p/275360#M228490</guid>
      <dc:creator>romschn</dc:creator>
      <dc:date>2011-07-05T09:18:32Z</dc:date>
    </item>
  </channel>
</rss>

