Generating portlets from HATS Web projects

In order to allow an existing HATS Web project to run as a portlet, the structure and content of the HATS project must be altered to meet the portlet specification. The HATS Toolkit automates the process of converting a regular HATS Web project into a portlet. The Portal Tools feature of Rational® SDP is a prerequisite for this conversion process.

To generate a HATS portlet project from an existing HATS Web project, in the HATS Projects view, right-click the Web project and select Generate Portlet Project.

In the Generate Portlet Project wizard, on the Portlet Project Generation Options panel:
  1. Enter a name for the portlet project.
  2. For the Target server field, select one of the following target WebSphere® Portal servers:
    • WebSphere Portal v7.0
    • WebSphere Portal v8.0.
    Note:
    When generating a HATS portlet project from a HATS Web project, the target server of the Web project determines the target server options for the portlet project.

    If the target server of the Web project is WebSphere® Application Server v7.0, the target server options for the generated portlet are:

    • WebSphere Portal v7.0
    • WebSphere Portal v8.0.

    If the target server of the Web project is WebSphere® Application Server v8.0 or v8.5, the target server option for the generated portlet is:

    • WebSphere Portal v8.0.
  3. For the Enterprise application project field, enter the name of the EAR project to use for testing in the local test environment.
  4. For the Portlet API field, select JSR 286 Portlet, or JSR 168 Portlet to indicate with which API this portlet will comply.
  5. Select from this list the types of files to be automatically converted:
    • Transformations
    • Transformation fragments
    • Templates
    • Macro handlers
    • Cascading style sheets
  6. Click Finish.
A HATS portlet project will be created from the selected Web project. Once the portlet is created, additional customization can be done. For more information about modifying HATS projects, see Modifying a HATS project.
Note:
  1. If you convert a HATS Web project to a HATS portlet project, you may have to manually modify the Web Express Logon (WEL) configuration file (hatswelcfg.xml) if the plug-ins configured for the Web project are not supported for the portlet project. It is recommended that you use the WEL configuration user interface to add supported plug-ins so that the WEL configuration file (hatswelcfg.xml) is updated properly.
  2. After generating a HATS portlet project from a HATS Web project, changes made to one project are not reflected in the other. You can always generate a new HATS portlet project from a changed HATS Web project to reflect changes made in the Web project.
  3. You cannot convert a HATS portlet project back into a HATS Web project.
  4. If you have an existing HATS V4, V5, V6, V7.0, V7.1, V7.5, V8.0, or V8.5 application, you must migrate your application to HATS V9.7V9.7 before generating a portlet project. For more information about migrating to HATS V9.7 see Migrating to HATS V9.7.