2 Replies Latest reply on Oct 20, 2010 6:35 AM by KVMKrishna Reddy

    Migration from JBoss 4.2.2 (JBoss MQ)- JBoss 5.1(JBoss Messaging)

    KVMKrishna Reddy Newbie



      All our applications are currently running in JBoss 4.2.2. We are migrating the applications from JBoss 4.2.2 to JBoss 5.1.0 version.


      Few of our applications are connecting to Jboss MQ remote queues. Like MDB(EJB 2.0/2.1 version) deployed in server A connects to JMS Queue hosted in Server B.  We are migrating applications in phase manner. That means few of our applications will be running in JBoss 4.2.2 and few are in JBoss 5.1.0.


      My question is, how we can able to acheive remote queue lookup across JBoss MQ and JBoss Messaging?


      As per the current architecture, we need two types of remote look up.

      1. MDB (running in JBoss 5.1) can look  up to JMS Queue(hosted in JBoss 4.2.2)

      2. MDB (running in JBoss 4.2.2) can look  up to JMS Queue(hosted in JBoss 5.1)



      Thanks and Regards


        • 1. Re: Migration from JBoss 4.2.2 (JBoss MQ)- JBoss 5.1(JBoss Messaging)
          Wolf-Dieter Fink Master

          I would prefer to run JBossMessaging in a 5.1 server.

          The difference is a cluster implementation instead of a SingletonHA (mean only one JBoss in a cluster starts the MQ).

          JBossMessaging (JBM) will be full cluster aware.


          I'm not sure whethter the JBoss4.x libraries are compatible in for JMS, the 4,3 version is per default JBM and 4.2 MQ.


          Remove the MQ from your installation with all libraries.

          Add the JBoss Messaging client libraries to the lib directory, in your case 4.2 should not have JBM classes.

          If this will not work I think you must repack your application and include the JBM libraries and separate with a class-loader-repository.


          With migration from JB4 to JB5 I have trouble because it will be not very easy to bring this into work.

          We have many trouble and the point of failure was the transaction handling, it is not possible to have an ACID Tx within a JB5App witch call a JBoss4App.

          • 2. Re: Migration from JBoss 4.2.2 (JBoss MQ)- JBoss 5.1(JBoss Messaging)
            KVMKrishna Reddy Newbie

            I am able to resolve this by creating JBM Bridge between JBoss MQ and JBM server instances.


            Find the below bridge configurations, I used.



            <?xml version="1.0" encoding="UTF-8"?>


            <mbean code="org.jboss.jms.jndi.JMSProviderLoader" name="jboss.messaging:service=JMSProviderLoader,name=RemoteJMSProvider">
                <attribute name="ProviderName">RemoteXAConnectionFactory</attribute>
                <attribute name="ProviderAdapterClass">org.jboss.jms.jndi.JNDIProviderAdapter</attribute>
                <attribute name="QueueFactoryRef">XAConnectionFactory</attribute>
                <attribute name="TopicFactoryRef">XAConnectionFactory</attribute>
                <attribute name="Properties">

            <mbean code="org.jboss.jms.server.bridge.BridgeService" name="jboss.messaging:service=Bridge,source=JBM,destination=JBossMQ"
                 <depends optional-attribute-name="SourceProviderLoader">jboss.messaging:service=JMSProviderLoader,name=JMSProvider</depends>
                 <depends optional-attribute-name="TargetProviderLoader">jboss.messaging:service=JMSProviderLoader,name=RemoteJMSProvider</depends>
                 <attribute name="SourceDestinationLookup">/queue/local_queue</attribute>
                 <attribute name="TargetDestinationLookup">/queue/remote_queue</attribute>
                 <attribute name="QualityOfServiceMode">2</attribute>

                 <attribute name="MaxBatchSize">1</attribute>
                 <attribute name="MaxBatchTime">1000</attribute>
                 <attribute name="FailureRetryInterval">5000</attribute>
                 <attribute name="MaxRetries">-1</attribute>
                 <attribute name="AddMessageIDInHeader">true</attribute>