Sunday, March 07, 2010

How-to: Oracle Service Bus 10gR3 - Oracle FMW B2B 11g interoperability

In this posting I will describe how you can integrate Oracle B2B 11g and Oracle Service Bus 10gR3 to send messages to Oracle B2B 11g from an OSB 10gR3 service.

The most easy way to integrate Oracle B2B 11g and OSB 10gR3 is by using JMS. Oracle B2B 11g supports JMS as protocol for its internal inbound and outbound delivery channels out-of-the-box.To enable JMS set the Use JMS Queue as default property to true in the Administration -> Configuration tab in the Oracle B2B 11g management console in order to switch on the usage of the JMS queues B2B_IN_QUEUE and B2B_OUT_QUEUE.

I have reused the ebXML configuration that I have described in a previous blog posting in this example. In Oracle Workshop 10gR3 (shipped with OSB 10gR3) you now have to make a simple OSB service that accepts a message through a proxy service and enqueues the message on the B2B_OUT_QUEUE of Oracle B2B 11g using a business service. Below I will describe the details that require special attention while implementing the OSB 10gR3 service.

Business Service - JNDI string
The BS serves as a JMS wrapper for the B2B_OUT_QUEUE. Use the following JNDI string to locate the
ConnectionFactory and Destination:

jms://(ofm b2b 11g host):(port)/jms.b2b.B2BQueueConnectionFactory/jms.b2b.B2B_OUT_QUEUE

Proxy Service - message flow
Oracle B2B 11g expects several user header properties in the JMS transport header to be set. A list of the required properties can be found here. You have to use the property names defined in the second column. To set the user header properties use the Transport Header action in the request lane of the Routing action (assumed you use a Routing action). Click on Add Header to add a new header property and select Other to define a custom header property. Add header properties for all listed properties in the table expect the last four in the table (at least I didn't set them)

Here's a screen shot of my OSB 10gR3 configuration:

After you have completed the message flow publish your configuration to the server and use the SB console test functionality to execute a test.

1 comment: said...


This is a wonderful article.
If we have to do the same thing in a clustered environment where there are two SOA server instances, then how do we do that? To which queue do we send the message to (from the Business Service) to take advantages of clustering.
Do we send it to B2B_OUT_QUEUE_auto_2 or B2B_OUT_QUEUE_auto_1 ?