1 Reply Latest reply on Sep 16, 2010 6:53 AM by Balraj Kannan

    Server Side Load Balancing in JBoss 5.1 with HornetQ 2.1.1

    Balraj Kannan Newbie


      I am facing an issue with server side load balancing with JBoss.


      The environment is as follows:

      JBoss 5.1 GA

      HornetQ 2.1.1 Final.

      Windows XP


      I tried executing the examples which come with hornetq and was able to run them.


      The problem i am facing is as follows:


      I have two instances of jboss servers running on the same machine in a cluster mode (Say server0 and server1). Both have a Queue defined as ExampleQueue.


      I have a MDB(QueueMDB) deployed in each of the instance which consume the messages dropped on the queue.


      From the stand alone java client I forward the request to the server. It is always handled by only one managed server. The request never is handled by the other instance.


      I am attaching the client code, MDB and the configuration files.


      QueueMDB.java - MDB

      TestMDBMessageClient.java - Stand alone client to produce the messages


      Command used to start the servers are as follows


      server 1 :  run.bat -g cluster -c server0  -Djboss.messaging.ServerPeerID=1


      server 2 :  run.bat -g cluster -c server1 -Djboss.messaging.ServerPeerID=2 -Djboss.service.binding.set=ports-01 



      Could someone please let me know where am I going wrong with the configuration?


      Any pointers will be of great help.