How to create JMS Bridge in JBoss EAP 6.x/7.x to Weblogic 10

Solution Verified - Updated -

Environment

  • Red Hat JBoss Enterprise Applciation Platform (EAP)
    • 6.x
    • 7.x
  • Oracle Weblogic
    • 10.3

Issue

  • How to create JMS Bridge in JBoss EAP 6.x to Weblogic 10 ?

Resolution

  • Please find the configuration:

  • Prerequisites Oracle Weblogic 10.3 (Examples Server):

1) Initial Context Factory Class Name: weblogic.jndi.WLInitialContextFactory
2) URL: t3://ip:7001
3) Connection Factory JNDI: weblogic.examples.jms.QueueConnectionFactory
4) QUEUE JNDI: weblogic.examples.ejb30.ExampleQueue
5) Credentials: weblogic/weblogic
  • JBoss EAP 6 (standalone-full.xml):
1) Connection Factory JNDI: java:/ConnectionFactory
2) QUEUE JNDI: java:/MyQ
3) Weblogic Module: com.weblogic  // Create a module in JBoss with Weblogic libraries
  • JMS Bridge Source Destination:
<source>
     <connection-factory name="java:/RemoteConnectionFactory"/>
     <destination name="java:/TestQ"/>
</source>
  • JMS Bridge Target Destination:
<target>
    <connection-factory name="weblogic.examples.jms.QueueConnectionFactory"/>
    <destination name="weblogic.examples.ejb30.ExampleQueue"/>
    <user>weblogic</user>
    <password>weblogic</password>
    <context>
        <property key="java.naming.factory.initial"
            value="weblogic.jndi.WLInitialContextFactory"/>
        <property key="java.naming.provider.url" value="t3://IP:7001"/>
    </context>
</target>
  • Bridge Configuration:
           <jms-bridge name="myBridge" module="com.weblogic">
              <source>
             <connection-factory name="java:/RemoteConnectionFactory"/>
             <destination name="java:/TestQ"/>
              </source>
              <target>
             <connection-factory name="weblogic.examples.jms.QueueConnectionFactory"/>
             <destination name="weblogic.examples.ejb30.ExampleQueue"/>
             <user>weblogic</user>
             <password>weblogic</password>
             <context>
                <property key="java.naming.factory.initial" value="weblogic.jndi.WLInitialContextFactory"/>
                <property key="java.naming.provider.url"    value="t3://localhost:7001"/>
             </context>
              </target>
              <quality-of-service>AT_MOST_ONCE</quality-of-service>
              <failure-retry-interval>500</failure-retry-interval>
              <max-retries>1</max-retries>
              <max-batch-size>500</max-batch-size>
              <max-batch-time>500</max-batch-time>
              <add-messageID-in-header>true</add-messageID-in-header>
           </jms-bridge>

EAP 7

  • To create module refer article 3259881.
  • In xml add following jms bridge configuration
<jms-bridge name="test-jms-bridge" max-batch-time="100" max-batch-size="10" max-retries="1" failure-retry-interval="500" quality-of-service="AT_MOST_ONCE" module="com.oracle.weblogic.client">
<source destination="jms/source" connection-factory="weblogic.examples.jms.QueueConnectionFactory">
                <source-context>
<property name="java.naming.factory.initial" value="weblogic.jndi.WLInitialContextFactory"/>
                     <property name="java.naming.provider.url" value="t3://localhost:7001"/>
                </source-context>
                </source>
<target destination="java:/jboss/exported/targetQueue" connection-factory="ConnectionFactory"/>
            </jms-bridge>

This solution is part of Red Hat’s fast-track publication program, providing a huge library of solutions that Red Hat engineers have created while supporting our customers. To give you the knowledge you need the instant it becomes available, these articles may be presented in a raw and unedited form.

Close

Welcome! Check out the Getting Started with Red Hat page for quick tours and guides for common tasks.