Viewing Information About an MDS Repository Using Fusion Middleware Control

14-20 Oracle Fusion Middleware Administrators Guide The target directory or archive file .jar, .JAR, .zip or .ZIP to which to transfer the documents selected from the source partition. If you export to a directory, the directory must be a local or network directory or file where the application is physically deployed. If you export to an archive, the archive can be located on a local or network directory or file where the application is physically deployed, or on the system on which you are executing the command. If the location does not exist in the file system, a directory is created except that when the names ends with .jar, .JAR, .zip or .ZIP, an archive file is created. If the archive file already exists, the exportMetadata operation overwrites the file. Click Export. Then, in the Confirmation dialog box, click Close. If you check Exclude base documents, this operation exports only the customizations, not the base documents. See Section 14.3.1 for information about base documents and customizations. 4. If the production application is on a different system, copy the exported metadata to that system. 5. From the navigation pane for the production system, expand the farm, expand Application Deployments , then select the application. 6. From the Application Deployment menu, choose MDS Configuration. The MDS Configuration page is displayed 7. In the Import section, select one of the following: ■ Import metadata documents from an archive on the machine where this web browser is running. ■ Import metadata documents from a directory or archive on the machine where this application is running. Enter the location of the directory or archive that contains the exported metadata. If you specify a directory, include the subdirectory with the partition name in the specification. The directory or archive file must be a local or network directory or file where the application is physically deployed. 8. Click Import. 9. In the Confirmation dialog box, click Close.

14.3.8.2 Transferring Metadata using WLST

To use WLST to transfer metadata: 1. Export the metadata from the original partition using the exportMetadata command: exportMetadataapplication=sampleApp, server=server1, toLocation=tmpmyreposmypartition, docs= This command exports a versioned stripe of the metadata documents from the metadata partition to a file system directory. Only customization classes declared in the cust-config element of adf-config.xml are exported. If there is no cust-config element declared in adf-config.xml, all customization classes are exported. To export all customizations, use the option restrictCustTo=. 2. If the production application is on a different system, copy the exported metadata to that system. Managing the Metadata Repository 14-21 3. Import the metadata to the other partition using the WLST importMetadata command: importMetadataapplication=sampleApp, server=server1, fromLocation=tmpmyreposmypartiton, docs= The value of the fromLocation parameter must be on the same system that is running WLST or on a mapped network drive or directory mount. You cannot use direct network references such as \\mymachine\repositories\. Only customization classes declared in the cust-config element of adf-config.xml are imported. If there is no cust-config element declared in adf-config.xml, all customization classes are imported. To import all customizations, use the option restrictCustTo=.

14.3.9 Moving from a File-Based Repository to a Database-Based Repository

You can move from a file-based repository to a database-based repository. You cannot move from a database-based repository to a file-based repository. To minimize downtime, take the following steps to move an applications metadata from a file-based repository to a database-based repository: 1. Use RCU to create schemas in the new repository, as described in Section 14.2 . 2. Create a new partition using the WLST command createMetadataPartition with same name as source partition: createMetadataPartitionrepository=mds-repos1, partition=partition1 3. Export the metadata from the source partition to a directory on the file system: exportMetadataapplication=sampleApp, server=server1, toLocation=tmpmyrepospartition1, docs= 4. Import the metadata from the file system to the new partition: importMetadataapplication=sampleApp, server=server1, fromLocation=tmpmyrepospartition1, docs= 5. Redeploy the application, as described in Section 10.4.3 , Section 10.5.3 , or Section 10.6.3 , depending on the type of application. When you do so, you specify the new partition and repository in the Application Attributes page: a. To change the repository, click the icon next to the Repository Name. In the Metadata Repositories dialog box, select the repository and click OK. b. To change the partition, enter the partition name in Partition Name. 6. Deregister the file-based repository, as described in Section 14.3.3.2 .

14.3.10 Deleting a Metadata Partition from a Repository

You can delete metadata partitions if there are no applications either deployed to the partition or referring to the partition. You may want to delete a metadata partition from the repository in the following circumstances: ■ When you undeploy an application. Oracle Fusion Middleware leaves the metadata partition because you may still want the metadata, such as user customizations, in the partition. If you do not need the metadata, you can delete the partition.