Detecting Duplicate Artifacts Downloading Harvested Artifacts

6-38 Oracle Fusion Middleware Configuration Guide for Oracle Enterprise Repository ■ Section 6.3.6.1, Associate JDeveloper Application with Oracle Enterprise Repository Project ■ Section 6.3.6.2, Consume WSDL Services from Oracle Enterprise Repository

6.3.6.1 Associate JDeveloper Application with Oracle Enterprise Repository Project

1. Click Application Menu that appears to the right of the application in the

Application Navigator.

2. Select Application Properties. The Application Properties dialog is displayed.

3. Click Repository in the left pane. The Repository page is displayed in the right. 4. In the Repository Connection list, select the Oracle Enterprise Repository connection that you want to use for usage tracking. 5. In the Repository Project list, select the Oracle Enterprise Repository project that you want to use for usage tracking.

6. Click OK.

6.3.6.2 Consume WSDL Services from Oracle Enterprise Repository

1. In JDeveloper, open the composite editor. 2. Drag and drop the Web Service component from the Component Palette to External References swim lane. The Create Web Service dialog is displayed. 3. Enter a reference name in the Name field. 4. Click the Find Existing WSDL icon at appears at the extreme right of the WSDL URL field. The SOA Resource Browser dialog is displayed. 5. Select Resource Palette from the list.

6. Click IDE Connections, Oracle Enterprise Repository, Connection Name, Asset

Types , Service, and then select the service you want to invoke or consume. If the service has only one WSDL or UDDI key associated with it, then the same WSDL or UDDI key is used to create the reference. If service has more than one WSDL andor UDDI key associated with it, then the Choose WSDL dialog is displayed. You need to select one of the URLsUDDI keys to consume. For resolving UDDI keys in JDeveloper, you have to create a UDDI connection prior to creating the reference, without which you cannot select UDDI keys.

6.3.7 Detecting Duplicate Artifacts

The Harvester stores information about files such as WSDLs, BPELs, and XSDs as artifacts in Oracle Enterprise Repository. To avoid storing the same artifact file twice, the Harvester will calculate a Software File ID SFID for each artifact when it is stored. Before submitting a new artifact, the SFID can be compared against existing SFIDs in the repository to check for duplicates. The SFID calculated is an MD5 hash. Some level of canonicalization is performed before calculating the SFID. In particular, if the artifact file is XML, it is canonicalized Note: Follow the same procedure to browse for schemas XSDs, events EDL, transformations XSLT, except that you will select the respective Artifacts instead of Service. Configuring and Using Automated Harvesting in Design-time and Runtime Environments 6-39 using the Canonicalizer class in the Apache XML Security library. This canonicalizes according to the W3C Canonical XML standard see www.w3.orgTRxml-c14n, which includes canonicalizing the text encoding, line breaks, whitespace, comments, and attribute ordering. Some extra canonicalization not specified in the W3C standard is performed, including normalizing of namespace prefixes, normalizing the order of the elements in WSDLs, removing documentation elements, and inlining any includedimported files.

6.3.8 Downloading Harvested Artifacts

The Harvester creates artifact bundles that may be downloaded from the Harvested Assets. The artifact bundles for these assets are stored in zip files. For example, for an Endpoint, a WSDL file and its associated XSD files are stored in relative locations within the zip payload. When one artifact imports another artifact for example, a WSDL imports a XSD, it always refers to the child artifact relative to the parent. For example, if MyWSDL.wsdl is located in c:\temp and if the child XSD that is being imported resides in c:\temp\schemas\MyXSD.xsd, the parent MyWSDL.wsdl imports the child using the relative path .schemasMyXSD.xsd. When the bundle is downloaded, the child artifact should be created in a folder called schemas relative to the parent so that the parent can resolve the child. For more information about UsingDownloading Assets, see Oracle Fusion Middleware Users Guide for Oracle Enterprise Repository.

6.3.9 Searching Harvested Assets