Contents

FioranoMQ can be integrated with an OC4j Application Server. The sample code that is provided in the following zip file can be downloaded from ftp://downloads.fiorano.com/fmqdownload/OC4JIntegration.zip

29.13.1 Deploy the MDB Application

Download the MDB application from: ftp://downloads.fiorano.com/fmqdownload/fiorano.ear

Save the MDB Application on the local drive. in the \fiorano\MDB directory.

Follow the steps below to deploy MDB on OC4J:

Add the following lines of code to the server.xml file which can be located at \oracle10g\j2ee\home\config directory

Icon

It is assumed that the Oracle 10g Application Server is installed at the \oracle10g directory.


The file server.xml defines the configuration parameters for the OC4J Server. This file also contains information regarding any Application or any Bean requiring loading or deploying at startup. InFioranoMQ the Application is a simple MDB with auto-start set to true. The OC4J Server looks for the ear file of the Application or of the Bean along the path provided by the application name. The correct path of the file mdb.ear needs to be added to the server.xml file.

Start the OC4J Server by entering the command below in

\oracle10g\j2ee\home directory:java -jar oc4j.jar

This starts the 0C4J Server and deploys the MDB on it.

29.13.2 Test the MDB

Upon deployment, the MDB starts listening for messages on the primaryQueue. If a message is pushed onto the primaryQueue (via a Sender sample for example), the message should show up in the output logs of the Oracle Application Server.

  1. Run a sender application (present in fmq/samples/Ptp/SendReceive directory) using the following command:

2. Now send a message. This message will appear in the OC4J console as shown below:

04/06/28 13:32:01 Got Message=fiorano.jms.services.msg.def.FioranoTextMessage@354749

Adaptavist ThemeBuilder EngineAtlassian Confluence