Undeploying WebCenter Applications Using WLST

7-28 Oracle Fusion Middleware Administrators Guide for Oracle WebCenter ■ Application Metadata -- which includes the customizations and personalizations on the application itself, such as those created when user edits a page and adds content to it. ■ Portlets Preferences-- which includes customizations and personalizations of the portlet instances. The following subsections explain how to preserve these three types of information about an application: ■ Section 7.3.1.1, Preserving Application Configuration ■ Section 7.3.1.2, Preserving Service and User Customizations ■ Section 7.3.1.3, Preserving Portlet Customizations

7.3.1.1 Preserving Application Configuration

In most cases, the end-points of services and portlet-producers are different in a test or staging environment than in a production environment. Therefore, when an application is redeployed to a production environment, you must reconfigure the application to work with the production environment services and producers or reuse the configuration used previously. Fusion Middleware facilitates this by storing the configuration information in the MDS repository. When you deploy the application for the first time, the base document of the application configuration is created in the MDS repository. This configuration is the set of all of the applications connections and their properties that are packaged in the EAR file. After the deployment, you may need to modify the connections using Fusion Middleware Control or WLST in response to production needs. This reconfiguration creates a layer of customization for the configuration changes in the MDS repository. When you redeploy the application, the configuration packaged with the application is laid down as the base document, but the customizations to the configuration are preserved. Therefore, the applications redeployment settings match the most recent configuration performed. However, customizations are completely preserved only when there are no changes in the base document. If you redeploy an application where the packaged connection information has changed, the following can be expected: ■ A new connection is added to the packaged configuration. The new connection should display without problems. ■ A connection has been removed in the packaged configuration. If you configured this connection after the last deployment, then the connection does not display after deployment, and you must re-create it. Note: You must delete runtime customizations customizations not done through JDeveloper before redeploying an updated application that has had major changes to artifacts such as pages, connections, or task flows. Note: To preserve application information, you must redeploy using the same MDS partition that was used or created using the initial deployment. Deploying WebCenter Applications 7-29 ■ A connection property has been changed in the packaged configuration. The customized properties are used. Connection customizations are managed at the individual connection level, and not at the properties level.

7.3.1.1.1 Preserving Configuration Across Deployment Using WLST

If you use WLST commands to configure the WebCenter Portal application, you can easily combine them into a script to remove all the connections and re-create them for the configuration of the production instance. Using this approach, you can always reconfigure an application to the target configuration without worrying about the details in the packaged configuration.

7.3.1.2 Preserving Service and User Customizations

Application metadata can change post-deployment due to customizations done by users at run time. When you redeploy the application, in most circumstances, you must preserve this customization information so that users see exactly what they were seeing before. Application and user customizations are stored in the MDS repository, and the same rules apply for preserving application metadata as for preserving configuration settings. When the application is redeployed, the base documents for all application artifacts are replaced with what is packaged in the EAR file. However, customizations are retained. There is no impact to this information unless the base artifact is changed, in which case the same rules apply as for configuration settings, which are: ■ If new elements are added to the package, then they appear as they are. ■ If elements are removed from the package, for which customizations were created, those customizations are ignored. ■ If elements are changed, then the effect depends on what exactly is changed, but must be verified.

7.3.1.3 Preserving Portlet Customizations

Portlet customizations are packaged with the metadata in the EAR file. Application startup after deployment kicks off the portlet customization migration to the target producers. The target producers are identified by resolving connection customizations. If you have modified your producer connections before redeployment, then those modified connections are used to identify target producers. Note that if you redeploy an EAR file with the same checksum that is, the same file as the pre-existing one, portlet customization and personalizations are not overwritten.

7.3.2 Redeploying WebCenter Applications Using Fusion Middleware Control

This section describes how to redeploy a WebCenter Portal application using Fusion Middleware Control. To redeploy a WebCenter Portal application using Fusion Middleware Control: Best Practice Note: In some cases, you may want to export all application and user customizations in a production application instance and import it into a test or staging instance. You can then test the application against those customizations to see that the new changes do not have an undesired impact.