Skip Headers
Oracle® WebCenter Framework Developer's Guide
10g (10.1.3.2.0)

Part Number B31074-05
Go to Documentation Home
Home
Go to Book List
Book List
Go to Table of Contents
Contents
Go to Index
Index
Go to Feedback page
Contact Us

Go to previous page
Previous
Go to next page
Next
View PDF

A Reuse of OracleAS Portal Components

If you have used Oracle Application Server Portal (OracleAS Portal) in the past, then this appendix can help you to understand how you might make use of the components of your portal in a WebCenter application. While no direct migration is available from OracleAS Portal to Oracle WebCenter Suite, many of the components of your portal can be brought forward and reused in a WebCenter application built with Oracle WebCenter Framework.

A.1 Reusing Your OracleAS Portal Components in WebCenter Suite

The two most basic building blocks of OracleAS Portal are as follows:

You can reuse each of these building blocks in your WebCenter application.

Note:

In Oracle WebCenter Framework, there is currently no page template feature. You can, however, reuse a JSP by copying and pasting its content in a newly created page.

A.1.1 Reusing Portlets

To reuse portlets in your WebCenter application, all you need to do is register the producers (sometimes referred to as providers in OracleAS Portal) as you would any other producer. See Section 4.3, "Consuming Portlets" for information about consuming portlets in a WebCenter application. The sections that follow describe some areas where behavior of portlets differs from OracleAS Portal.

A.1.1.1 iframes

By default, a portlet may be placed inside of an iframe. If your portlet is placed in an iframe, then it effects the ability of the portlet to locate itself on the page. Inside of an iframe, your window.location setting may not give the expected results. For more information about when your portlet may be placed inside of an iframe, see Section 4.3.3.6, "iframes and form Tags"

A.1.1.2 Events

Events are not supported in Oracle WebCenter Framework. If you have PDK-Java portlets that use events and you deploy them in a Oracle WebCenter Framework environment, then the events are ignored.

A.1.1.3 Mobile Portlets

Mobile portlets are not supported in Oracle WebCenter Framework. If you have PDK-Java mobile portlets, then they will not work in a Oracle WebCenter Framework environment.

A.1.1.4 Portlet Chrome

In Oracle WebCenter Framework, the portlet does not provide the chrome. The consuming application provides the chrome. This behavior conforms to the WSRP convention, but it is a change from OracleAS Portal, where PDK-Java provided the chrome for portlets. Hence, the PDK-Java portlet header is filtered out in the Oracle WebCenter Framework environment.

As part of this filtering process, Oracle WebCenter Framework parses the title area of PDK-Java portlets to preserve the title and add the necessary portlet mode links. The filtering algorithm is as follows:

  • If the portlet has multiple tables, then the title area is considered to be the first table. If the portlet has only one table, then the title area is considered to be the first row in that table.

  • The first text in the title area is considered to be the title. If the portlet has no tables or a discernible title, then the title is taken from the adfp:portlet component.

  • Any link with that contains the fragment _mode= parameter is considered to be a portlet mode link. These links are moved into the portlet menu by Oracle WebCenter Framework.

If you wish to bypass the rendition of the header section of your portlet chrome and reuse its original, PDK-Java header, then you can set the displayHeader attribute of the adfp:portlet tag to false and retainPortletHeader as true in the associated portlet bindings of the page definition Extensible Markup Language (XML). Setting retainPortletHeader=true in the page definition portlet binding retains the portlet header in the portlet response. Setting displayHeader=false in the adf:portlet tag suppresses the application's header for the portlet chrome, and hides the icons and links normally displayed in the header.

A.1.1.5 Personalizations and Customizations

Portlet customizations and personalizations that you or your users applied to your portlets in OracleAS Portal will not be carried over to your WebCenter application. In a WebCenter application, your OracleAS Portal portlets are treated as new instances. Hence, previous personalizations and customizations are not available.

A.1.1.6 OracleAS Portal System Resources

Portlets built with a target consumer of OracleAS Portal in mind tend to make invalid assumptions about the run time environment. For example, the portlet might assume the presence of OracleAS Portal resources, such as images or Javascript functions. In Oracle WebCenter Framework, these resources are not available. Hence, you need to bundle the resources the portlet needs with the producer to ensure that the portlet runs properly in the Oracle WebCenter Framework environment.

Another common issue with portlets designed for OracleAS Portal consumption is the portlet assuming the OracleAS Portal URL format and the presence of OracleAS Portal parameters. The page URL of an Oracle ADF application is different from that of OracleAS Portal. Therefore, portlet developers cannot make assumptions about the page URL and must prepare their PDK-Java portlets for execution in the Oracle WebCenter Framework environment by using the proper portlet Application Programming Interface (API)s.

A.1.1.7 Partner and External Applications

Partner applications are not supported. External applications are supported, but they send a null login URL. Any links wrapped by the login URL (links through Oracle Single Sign-On) will not work.

A.1.1.8 Federated Portal Adapter

The Federated Portal Adapter (FPA) enables you to make PL/SQL portlets, Portlet Builder portlets, and OracleAS Portal pages visible in your WebCenter applications. Note that for pages to be available through the FPA, they must have been exposed as portlets in OracleAS Portal. These FPA portlets are read only in a WebCenter application. Users can see their contents but not interact with them.

Implementing FPA for your portal exposes the OracleAS Portal portlets through the PDK-Java Web producer protocol making it possible to register them as PDK-Java producers. Registering the producer with a WebCenter application causes the portlets to appear in the Component Palette, and you can then drag and drop them onto pages as you would any other portlet. Without FPA, you cannot access these producers from a WebCenter application.

To register your FPA producer with Oracle WebCenter Framework, perform the following steps:

  1. Implement FPA for your OracleAS Portal instance based on the information in Oracle Application Server Portal Configuration Guide.

  2. For any pages in the OracleAS Portal instance that you want to expose through FPA, publish them as portlets.

  3. For secured portlets, configure HMAC in the OracleAS Portal instance. This procedure is described in Oracle Application Server Portal Configuration Guide. Note that for WebCenter applications the sending portal is always:

    http://www.oracle.com/adapter/portal
    
  4. In Oracle JDeveloper, register the producer as a PDK-Java producer using the FPA URL and Service ID.

  5. The producer should now appear in the Component Palette and you can drag and drop its portlets onto a page.

  6. Since portlets exposed through FPA may not be customized or personalized from within a WebCenter application, you should suppress the appearance of Customize and Personalize in the Actions menu. You can remove these choices from the Actions menu by setting the isCustomizeModeAvailable and isPersonalizeModeAvailable attributes of the adfp:portlet tag to false. For more information, see Section 4.3.3.2, "Actions Attributes of the adfp:portlet Tag".

  7. Confirm that the users of the WebCenter application have appropriate privileges on the portlets and pages exposed through FPA, and that they map to the users of the OracleAS Portal instance. The user name for a person on the WebCenter application should map to the user name of the same person on OracleAS Portal. For example, JSMITH should represent the same person in both the WebCenter application and OracleAS Portal.

  8. Now run the page.

A.1.1.9 PDK-Java Producers from Earlier Oracle Application Server Versions

If you have a producer that you designed and deployed on Oracle Application Server Release 2 (10.1.2) or earlier, then you can reuse it in either one of two ways:

  • You can consume a portlet from a producer running on an Oracle Application Server Release 2 (10.1.2.0.2) middle tier. In this case, the producer's code is running on Release 2 (10.1.2.0.2) while the application consuming the producer is running on Release 3 (10.1.3.2).

  • You can redeploy the producer application as an EAR file on WebCenter Suite and consume its portlets in other WebCenter applications. In this case, both the producer's code and the consuming application are running on Release 3 (10.1.3.2).

In either of these cases, you must take some additional steps to get the producer's portlets to operate correctly. Portlets built for OracleAS Portal expect certain boilerplate images to be present on the page assembly servlet and they will break if those images are not available. These images were included in the middle-tier servlet by default in Oracle Application Server Release 2 (10.1.2.0.2), but for Oracle WebCenter Framework you must manually ensure that the images can be found by portlets.

A.1.1.9.1 Consuming a Portlet from OracleAS Portal

In WebCenter Suite, to consume a portlet running on a page in an OracleAS Portal instance, you can do either of the following:

  • Obtain the OracleAS Portal images zip file from the Oracle Technology Network and unzip it inside the ADFP servlet.

  • Properly configure the resource servlet as follows:

  1. Add an initialization parameter to the Web servlet as shown is Example A-1.

    Example A-1 Web Servlet Initialization Parameters

    <servlet> 
     <servlet-name>SOAPServlet</servlet-name> 
     <display-name>SOAPServlet</display-name> 
     <description>Extended Portal SOAP Server</description> 
     <servlet-class>oracle.webdb.provider.v2.adapter.SOAPServlet</servlet-class> 
     ...
     <init-param> 
       <param-name>resourceServletMapping</param-name> 
       <param-value>/pdkresource</param-value> 
     </init-param> 
    </servlet>
    
  2. Add a servlet definition for the resource servlet as shown in Example A-2.

    Example A-2 Servlet Definition for Resource Servlet

    <servlet> 
     <servlet-name>ResourceServlet</servlet-name> 
      <display-name>ResourceServlet</display-name> 
      <description>Image resource servlet</description>     
      <servlet-class>oracle.webdb.provider.v2.adapter.ResourceServlet</servlet-class> 
    </servlet>
    
  3. Add a servlet mapping for the resource servlet as shown in Example A-3.

    Example A-3 Servlet Mapping for Resource Servlet

    <servlet-mapping> 
     <servlet-name>ResourceServlet</servlet-name> 
     <url-pattern>/pdkresource/*</url-pattern> 
    </servlet-mapping> 
    
  4. Now you can register this PDK-Java producer as you would any other PDK-Java producer. See Section 4.3.1.2, "Registering PDK-Java Portlet Producers" for more information about registering PDK-Java producers.

A.1.1.9.2 Redeploying PDK-Java Producers from OracleAS Portal

If you choose to take a PDK-Java producer from OracleAS Portal and redeploy it on WebCenter Suite, then you need to enable the resource servlet as follows:

  1. Add an initialization parameter to the Web servlet as shown in Example A-4.

    Example A-4 Web Servlet Initialization Parameter

    <servlet> 
     <servlet-name>SOAPServlet</servlet-name> 
     <display-name>SOAPServlet</display-name> 
     <description>Extended Portal SOAP Server</description> 
     <servlet-class>oracle.webdb.provider.v2.adapter.SOAPServlet</servlet-class> 
     ...
     <init-param> 
       <param-name>resourceServletMapping</param-name> 
       <param-value>/pdkresource</param-value> 
     </init-param> 
    </servlet>
    
  2. Add a servlet definition for the resource servlet as shown in Example A-5.

    Example A-5 Servlet Definition for Resource Servlet

    <servlet> 
     <servlet-name>ResourceServlet</servlet-name> 
      <display-name>ResourceServlet</display-name> 
      <description>Image resource servlet</description>     
      <servlet-class>oracle.webdb.provider.v2.adapter.ResourceServlet</servlet-class> 
    </servlet>
    
  3. Add a servlet mapping for the resource servlet as Example A-6.

    Example A-6 Servlet Mapping for Resource Servlet

    <servlet-mapping> 
     <servlet-name>ResourceServlet</servlet-name> 
     <url-pattern>/pdkresource/*</url-pattern> 
    </servlet-mapping> 
    
  4. Now you can register this PDK-Java producer as you would any other PDK-Java producer. See Section 4.3.1.2, "Registering PDK-Java Portlet Producers" for more information about registering PDK-Java producers.

A.1.2 Reusing Items

Items from OracleAS Portal have no equivalent in Oracle WebCenter Framework. As such, creating, maintaining, and publishing items is not supported in Oracle WebCenter Framework. To replicate some of the behavior of items with Oracle WebCenter Framework, you can do either one of the following:

  • Use JCR data controls to include content from OracleAS Portal. OracleAS Portal is one of the content repositories that Oracle WebCenter Framework supports out of the box in the Data Control Wizard in Oracle JDeveloper. For more information about integrating content from OracleAS Portal, see Chapter 5, "Integrating Content".

  • Store item-like content in Oracle Content Database and publish it with standard Oracle ADF components such as adf:tree. For more information, see Chapter 5, "Integrating Content".