2 Replies Latest reply on May 18, 2011 9:30 AM by kamesh_sampath

    Create Multiple Portals With Same Extension

    kamesh_sampath

      Hi,

       

      I am a newbie to Gatein and using the JBoss EPP v5.1.0,  I followed the article  and was able to successfully update or override classic portal resources,   the article shows how to create a new portal as part of the extension, is there anyway we could create multiple portals with the same extension

       

      e.g

      An extension that will update some of the classic portal resources like BannerPortlet and Footer Portlet  + add some more navigaiton, another Portal-A and Portal-B with their own navigaiton and pages provided using pages.xml, portal.xml and navigation.xml

       

      unfortunately am not able to get ther Portal-A and Portal-B and was able to see only the updates to the resources like Footer and Banner.

       

      Can any one help on what I am missing and what needs to be done in this case.

       

      Thanks.

      Kamesh

        • 1. Create Multiple Portals With Same Extension
          mvanco

          Hi,

           

          if you followed this doc: http://community.jboss.org/wiki/CreateANewPortalUsingExtension then you can easily extend it to create multiple portals.

          What you need to change is NewPortalConfig in portal-configuration.xml, for example:

           

          <object type="org.exoplatform.portal.config.NewPortalConfig">
               <field name="predefinedOwner">
                    <collection type="java.util.HashSet">
                         <value>
                              <string>classic</string>
                         </value>
                         <value>
                              <string>portalA</string>
                         </value>
                         <value>
                              <string>portalB</string>
                         <value>
                    </collection>
               </field>
               <field name="ownerType">
                    <string>portal</string>
               </field>
               <field name="templateLocation">
                    <string>war:/conf/portal/</string>
               </field>
          </object>
          <object type="org.exoplatform.portal.config.NewPortalConfig">
                                  <field name="predefinedOwner">
                                      <collection type="java.util.HashSet">
                                          <value>
                                              <string>classic</string>
                                          </value>
                                          <value>
                                              <string>newPortal</string>
                                          </value>
                                      </collection>
                                  </field>
                                  <field name="ownerType">
                                      <string>portal</string>
                                  </field>
                                  <field name="templateLocation">
                                      <string>war:/conf/portal/</string>
                                  </field>
                              </object>

          Kamesh Sampath wrote:

           

          Hi,

           

          I am a newbie to Gatein and using the JBoss EPP v5.1.0,  I followed the article  and was able to successfully update or override classic portal resources,   the article shows how to create a new portal as part of the extension, is there anyway we could create multiple portals with the same extension

           

          e.g

          An extension that will update some of the classic portal resources like BannerPortlet and Footer Portlet  + add some more navigaiton, another Portal-A and Portal-B with their own navigaiton and pages provided using pages.xml, portal.xml and navigation.xml

           

          unfortunately am not able to get ther Portal-A and Portal-B and was able to see only the updates to the resources like Footer and Banner.

           

          Can any one help on what I am missing and what needs to be done in this case.

           

          Thanks.

          Kamesh

          Kamesh Sampath wrote:

           

          Hi,

           

          I am a newbie to Gatein and using the JBoss EPP v5.1.0,  I followed the article  and was able to successfully update or override classic portal resources,   the article shows how to create a new portal as part of the extension, is there anyway we could create multiple portals with the same extension

           

          e.g

          An extension that will update some of the classic portal resources like BannerPortlet and Footer Portlet  + add some more navigaiton, another Portal-A and Portal-B with their own navigaiton and pages provided using pages.xml, portal.xml and navigation.xml

           

          unfortunately am not able to get ther Portal-A and Portal-B and was able to see only the updates to the resources like Footer and Banner.

           

          Can any one help on what I am missing and what needs to be done in this case.

           

          Thanks.

          Kamesh

          And then you create folders /conf/portal/portal/portalA and /conf/portal/portal/portalB which will contain files for portal, navigation and pages definition.

           

          If you want to separate developed portlets, you can create two new modules (WAR archives) with portlets and you can point in pages definitions to these portlets.

           

          Hope this helps, feel free to ask for more details.

           

          Best regards,

          Michal Vančo, JBoss QE

          • 2. Create Multiple Portals With Same Extension
            kamesh_sampath

            Hey Michal,

             

            it did work today, its quiet annoying that I did the same thing yesterday and it didn't work and hence dropped this post. Anyways thanks for your reply

             

            Regards,

            Kamesh