6.5. Configuring a portal container

A portal container is defined by several attributes.

First, there is a portal container name, which is always equal to the URL context to which the current portal is bound.

Second, there is a REST context name, which is used for REST access to portal application - every portal has exactly one (unique) REST context name.

Then, there is a realm name which is the name of security realm used for authentication when users log into the portal.

Finally, there is a list of Dependencies - other web applications, whose resources are visible to current portal (via extension mechanism described later), and are searched in the specified order.

Example: Portal container declaration

<?xml version="1.0" encoding="UTF-8"?>

        <!-- The full qualified name of the PortalContainerConfig -->

           <!-- The name of the plugin -->
           <name>Add PortalContainer Definitions</name>

           <!-- The name of the method to call on the PortalContainerConfig
                in order to register the PortalContainerDefinitions -->

           <!-- The full qualified name of the PortalContainerDefinitionPlugin -->

                 <object type="org.exoplatform.container.definition.PortalContainerDefinition">
                    <!-- The name of the portal container -->
                    <field name="name"><string>portal</string></field>

                    <!-- The name of the context name of the rest web application -->
                    <field name="restContextName"><string>rest</string></field>

                    <!-- The name of the realm -->
                    <field name="realmName"><string>exo-domain</string></field>

                    <!-- All the dependencies of the portal container ordered by loading priority -->
                    <field name="dependencies">
                       <collection type="java.util.ArrayList">
                          <!-- The sample-ext has been added at the end of the dependency list
                               in order to have the highest priority -->


Dependencies are part of the extension mechanism.

Every portal container is represented by a PortalContainer instance, including:

Unified servlet context, and unified classloader are part of the extension mechanism (explained in next section), and provide standard APIs (ServletContext, ClassLoader) with the specific resource loading behavior - visibility into the associated web application archives, configured with Dependencies property of PortalContainerDefinition. Resources from other web applications are queried in the order specified by Dependencies. The later entries in the list override the previous ones.

See also

Copyright ©. All rights reserved. eXo Platform SAS
blog comments powered byDisqus