Thursday, August 25, 2011

Manually copy plan.xml into other servers in the cluster

It is strange that you need to do so. But it is true. In Oracle SOA 11g cluster environment when you update the plan.xml you need to copy this plan.xml to other servers in the same cluster before you can activate the changes. No doing so will lead the error that complains the plan.xml file is not found.

For example, when you create a new outbound connection pool for JMSAdapter in the one cluster which has 3 servers: server01_01, server01_02 and server01_03 the plan.xml is created when you do so via EM on server01_01. You need to manually copy this plan.xml to the same folder on server01_02 and server01_03 before you activate the changes. Otherwise you will get the error like the below:

java.io.FileNotFoundException: /opt/oracle/Middleware/Oracle_SOA1/soa/connectors/JMSPlan/Plan.xml (No such file or directory).



Create Distributed Queue in Oracle SOA 11g


Step1: Create the queues as the members of the distributed queue.
Assume there are 3 JMS server: SOAJMSServer_auto_2, SOAJMSServer_auto_3 and SOAJMSServer_auto_4.
Create 3 queues namely: qContentProvider1-2, qContentProvider1-3 and qContentProvider1-4. These queues are respectively targeted to the above 3 JMS servers.
Step2: Create the distributed queue.
Create the distributed queue: dist_ContentProvider1Queue in which the 3 queues created in Step1 are the members respectively.

Monday, August 15, 2011

Oracle SOA 11g MDS


A metadata repository is the centralized store for the metadata used for the applications in Oracle SOA. It is very useful since most organizations and companies have their own common data models defined as XML schema and WSDL files. These files are organized in some hierarchies and there are dependencies among them. Obviously it is not wise to have local copies of these files for each SOA application. The metadata repository: MDS – Metadata Store in Oracle SOA provides to share these common metadata among the various SOA applications.
In Oracle SOA there are two types of MDS: file-based and database-based. File-based MDS uses the file system to store all these metadata and database-based uses the database. File-based MDS is only used for the development purpose. If the application is deployed on sever the database-based MDS must be used.
File-based MDS
Normally when you do the SOA application development using JDeveloper you usually uses file-based MDS. It is much easier to use file-based MDS for the development purpose. For each application there is one adf-config.xml located in YourAppFolder/.adf/META-INF folder.

In the adf-config.xml the element defines the metadata-namespace and metadata-store-usage from which we know where the shared artefacts. In this example the wsdl and schema files are located in the folder:
D:\Oracle\Middleware\jdeveloper\integration\seed\apps\SOInterfaces-2.3.9.8
where D:\Oracle\Middleware\jdeveloper\integration is the metadata-path and seed is partition-name and apps\SOInterfaces-2.3.9.8 is the namespace-path.

After the artefacts are put into the right file folder specified in adf-config.xml you can create one MDS connection in JDeveloper to view all the wsdl and schema files in the MDS.
From JDeveloper right click on Applic ation Resources->Connections and then select SOA-MDS from New Connection menu item. Then in the popup window: Create SOA-MDS Connection type in the Connection Name and choose File Based MDS as the Connection Type and type in the MDS Root Folder as: D:\Oracle\Middleware\jdeveloper\integration\seed. You can test the connection by clicking on Test Connection button. If the test is su ccessful click on OK button.

After the MDS connection is created you can see it from IDE Connections in JDeveloper.
Once the MDS is created you use it in your development. For example in your BPEL application you can choose one WSDL from MDS as the service interface of the BPEL process.
In the application one artefact such as wsdl or xsd is referenced it will be referred using oramds protocol. The below is one example from a wrapper wsdl.
location="oramds:/apps/SOInterfaces-2.3.9.8/BSC/OrderAndActivation/Activation/ServiceProvisioning-v1.wsdl"