Skip Headers
Oracle® Containers for J2EE Enterprise JavaBeans Developer's Guide
10g (10.1.3.5.0)

Part Number E13981-01
Go to Documentation Home
Home
Go to Book List
Book List
Go to Table of Contents
Contents
Go to Index
Index
Go to Feedback page
Contact Us

Go to previous page
Previous
Go to next page
Next
View PDF

Configuring a J2CA Resource Adapter for use With Your Message Service Provider

To configure a J2CA resource adapter such as the Oracle JMS Connector (see "Oracle JMS Connector: J2EE Connector Architecture (J2CA)-Based Provider") for use with your message service provider, you must do the following:

  1. Install and configure the J2CA adapter (see "Installing and Configuring a J2CA Adapter").

  2. Choose appropriate JNDI names for your connection factory (see "J2CA Message Service Provider Connection Factory Names").

  3. Configure the appropriate deployment XML files (see "Configuring OC4J J2CA Resource Adapter Deployment XML Files").

    Using these deployment XML files, you can specify factories that are either not XA-compliant, when two-phase commit (2PC) transactions are not needed, or XA-compliant, when 2PC transactions are needed. For more information on 2PC, see "How do You Participate in a Global or Two-Phase Commit (2PC) Transaction?".

  4. Configure your message-driven beans to access your message service provider using your J2CA resource adapter.

    For more information, see the following:

Note:

Oracle recommends that you access a message service provider using a J2CA resource adapter such as the Oracle JMS Connector. For more information, see "Restrictions When Accessing a Message Service Provider Without a J2CA Resource Adapter".

Note:

For a complete code example of configuring a J2CA message service provider resource adapter and MDB application, see http://www.oracle.com/technology/tech/java/oc4j/1013/how_to/how-to-gjra-with-oracleasjms/doc/how-to-gjra-with-oracleasjms.html.

J2CA Message Service Provider Connection Factory Names

The actual JNDI names for the destination and connection factory depend on your J2CA installation as defined in your oc4j-connectors.xml file (see "Configuring OC4J J2CA Resource Adapter Deployment XML Files").

Typically, it will be composed of java:<Prefix>/<FactoryName> where <Prefix> is an optional JNDI location like comp/env/eis, and <FactoryName> is the name of the javax.cci.ConnectionFactory for your adapter.

Installing and Configuring a J2CA Adapter

OC4J includes the Oracle JMS Connector: a generic JMS J2CA resource adapter that integrates OC4J with OEMS JMS and OEMS JMS Database message service providers, as well as non-Oracle JMS providers such as WebSphereMQ, Tibco, and SonicMQ.

For more information, see the following:

Configuring OC4J J2CA Resource Adapter Deployment XML Files

To configure a J2CA message service provider, you must configure the following deployment XML files:

  • ra.xml

  • oc4j-ra.xml

  • oc4j-connectors.xml

Using these deployment XML files, you can specify factories that are either not XA-compliant, when two-phase commit (2PC) transactions are not needed, or XA-compliant, when 2PC transactions are needed. For more information on 2PC, see "How do You Participate in a Global or Two-Phase Commit (2PC) Transaction?".

For more information, see the following:

  • "Binding and Configuring a Connection Factory: Basic Settings" in the Oracle Containers for J2EE Resource Adapter Administrator's Guide

  • "OC4J Resource Adapter Configuration Files" in the Oracle Containers for J2EE Resource Adapter Administrator's Guide