The starting point for this article is the following Service Bus project that has a JMS Transport configured to connect to the financial JMS queue, as described in the second section of Chapter 6.
We are now going to extend this project with a JCA JMS Adapter binding that does exactly the same thing – purely for educational purposed (note that JMS Transport is the preferred option according to Oracle SOA Suite product management for Service Bus projects).
Drag the JCA JMS Adapter from the Advanced category to the External References lane. When you drop it, the adapter configuration wizard appears, to configure the JMS Adapter binding.
On the first page, set the name of the Reference to FinanceAircraftMovementsReporterJCA. Set the Service Directory to the Adapters folder.
Select the Oracle Enterprise Messaging Service JMS provider and specify the Oracle WebLogic JMS option on page two.
On the third page, select the AppServer connection to the Integrated WLS (if that is the environment you are running on). This connection is used to browse for the JMS Adapter connection and the JMS queue – the JNDI names of which can also be entered manually.
Press Next. Select Import an existing WSDL and select the AircraftMovementService.wsdl as the source.
On the Operation page, set the Operation Type to Produce Message. The name of the operation is derived from the WSDL and is set to reportAircraftMovement.
The next page of the wizard (Figure 6-20) is titled Produce Operation Parameters. Set the Destination Name to the JNDI name of the JMS queue the adapter binding should publish messages to: jms/finance/AircraftMovementsQueue. Accept the defaults for Message Body Type (Text Message) and Delivery Mode (Persistent). Set the TimeToLive to 15 seconds.
The JNDI Name [of the JMS Adapter Connection] should be set to eis/Finance/Queue – the name specified for the new connection that was configured for the JMS Adapter.
In the next page, if we have not yet defined the Adapter Interface, we can specify the format of the messages that the JMS Adapter should pass onwards to the JMS queue. Checking the checkbox Native format translation is not required (Schema is Opaque) is used when a base64 payload should be passed. Alternatively, we can specify a native XSD definition for whatever format the JMS message payload should have. In this case, the WSDL specifies the reportAircraftMovementRequestMessage and this page in the wizard is disabled.
then press Finish to complete the configuration of the outbound JMS Adapter binding.
JDeveloper will create a business service with JCA transport that references the JMS Adapter binding configuration file FinanceAircraftMovementsReporterJCA.jca.
You can test this business service – by activating the run option in the context menu on the business service in the Service Bus composite overview.