My Oracle Support Banner

How to Receive JMS Messages in an MDB Using a Queue From JMS in a Different Remote OC4J Instance (Doc ID 726803.1)

Last updated on FEBRUARY 13, 2024

Applies to:

Oracle Containers for J2EE - Version 10.1.3.0.0 and later
Information in this document applies to any platform.

Goal

The example demonstrates a queue on one server (Server A), while having an MDB on another server (Server B) that listens to the queue. It also includes a client that connects to Server B and reads the messages.

The example involves having 2 Oracle Application Server and applies to Oracle AS 10.1.3.x.

The following outline the tasks to be complete:

  1. Server A is used to send the message to.
    • Need to create a JMS destination and queue connection factory
    • The queue on Server A will be called jms/MyJMSQueue.
    • The queue connection factory Server A will be called jms/MyJMSQCF.
    • The client will connect to server A and send a message to the queue.
  2. Server B is used to read the messages.
    • Need to create a queue connection factory destination that point to Server A and the JMS destination as in Server A.
    • The queue on Server B is the same as Server A.
    • The queue connection factory Server B will be called jms/MyRemoteQCF.
    • The MDB will be deployed to Server B. The MDB will listen to messages on Server A.
    • The client will connect to server B and read messages from the queue.

Solution

To view full details, sign in with your My Oracle Support account.

Don't have a My Oracle Support account? Click to get started!


In this Document
Goal
Solution


My Oracle Support provides customers with access to over a million knowledge articles and a vibrant support community of peers and Oracle experts.