Importing portal sites
Use the Import wizard to retrieve an existing portal site from a WebSphere Portal server.
To create a new portal project, it is recommended that you import an existing portal site from WebSphere Portal server into Rational Developer. Importing is also useful for updating the configuration of a project that already exists in Rational Developer.
The portal site configuration on WebSphere Portal server contains the following resources: the global settings, the resource definitions, the portal content tree, and the page layout. Importing these resources from WebSphere Portal server to Rational Developer overwrites duplicate resources within the existing portal project. Non-duplicate resources from the server configuration are copied into the existing portal project. Likewise, resources that are unique to the portal project are not affected by the import.
Rational Developer uses the XML configuration interface to import a server configuration, and optionally retrieves files under websphere_installation_directory/installedApps/node/wps.ear directory. When creating a new portal project, retrieving files is mandatory. To retrieve files, Rational Developer must have access to the directory described above via copy or FTP. You define this access method on the Portal server. For more details on defining a Portal server for import, see Defining servers for importing or publishing portals.
- Select File > Import.
- Within the Select page, click Portal for your import source; then click Next.
- Within the Import Portal Project page, select a portal server that you want to use. If the server dialog box is empty, click New to define a server. For more information on defining a server for import, refer to Defining servers for importing or publishing portals.
- From the Portal project combo box, either choose the name of the portal project or enter a name for your portal project for import.
- Under Import Options, choose whether you want to import the configuration and files, or the configuration only.
If you choose to import the configuration and files, the files under the websphere_installation_directory/installedApps/node/wps.ear directory are imported. The files include the JSP, CSS, and image files for themes and skins.
Also within the Import Options dialog box is a check box labeled Delete project on overwrite. This option is only active if you are importing to an existing portal project. If you select this option, the existing portal project is completely deleted before overwriting.
Limitations
- To ensure the imported portal project accurately reflects the portal server, copy the contents of portal_installation_directory/share/app/nls directory of the Portal server to websphere_installation_directory/installedApps/node/wps.ear/wps.war/WEB-INF/classes/nls before the import operation. If you do not wish to copy files in the portal server machine (i.e when you are importing from production server), you can copy the files from the server to the portal project manually after the import operation is finished by following these steps:
- Copy the property files from portal_installation_directory/share/app/nls of the server to Project/PortalContents/WEB-INF/classes/nls in the workspace.
- Copy these same files to the Project/JavaSource/nls directory in the workspace.
- Refresh the project.
- The Portal configuration in an imported project does not contain all of the configuration information from the Portal server. If you deploy the imported project to another server, it won't have complete configuration information.
- Import requires either copy or FTP access to the websphere_installation_directory/installedApps/node/wps.ear directory. If your firewall does not permit access to this directory, you cannot import from the WebSphere Portal server.
- If you only have FTP access to above directory, even if the firewall is configured to allow FTP, the import may still fail because more than 3,000 files are transferred. To increase your chances of a successful import, specify passive mode in the server configuration.
- If the portal server has more than one label or page of the same ordinal, the order of top level labels and pages in the newly imported portal project may be different from the order that was on the portal server.
- If JSP files or Java classes within the portal server refer to classes that are in external JAR files, there may be compilation errors after the project is imported. You need to import any external JAR files, which can be located in the websphere_installation_directory/lib or portal_installation_directory/shared/app directories on the external portal server, to your development machine, and add them to Java Build Path of your portal project. To set the Java Build Path,...
- From the Project Explorer view, highlight the project, right-click and select Properties.
- In the left pane, select Java Build Path.
- In the right pane, select the Libraries tab.
- Add the referenced JAR.
- Click OK to save the configuration.
Related tasks
Creating new portal projects