0 Replies Latest reply on Mar 13, 2012 9:33 AM by Gur Kamal Badal

    Forwarding Messages Using HornetQ Core Bridge is Very Slow

    Gur Kamal Badal Newbie

      We are trying to use the HornetQ store and forward mechanism ... however forwarding messages from one standalone hornetq instance to another using the core bridge is very slow. We have not been able to increase the throughput rate above 200 messages per second.


      The surprising fact is that if we point the same clinet (that was publishing messages to the forwarding hornetq instance) directly at the destination hornetq instance, we start observing a throughput rate of over 1000 messages per second (this client is JMS based). This basically means that the core bridge that's been configured between the Forwarding HornetQ instance and the Destination HornetQ instance is problematic.


      The following are the relevant sections for configuring the core bridge on the Forwarding HornetQ:



                  <connector name="netty-bridge">


                       <param key="host" value="destination.xxx.com"/>

                       <param key="port" value="5445"/>

                       <param key="batch-delay" value="50"/>

                       <param key="tcp-send-buffer-size" value="1048576"/>

                       <param key="tcp-receive-buffer-size" value="1048576"/>

                       <param key="use-nio" value="true"/>




            <address-setting match="jms.queue.Record">








               <queue name="jms.queue.Record">





              <bridge name="core-bridge">














      The following are the relevant sections for configuring the core bridge on the Destination HornetQ:



            <acceptor name="netty">


               <param key="host"  value="${hornetq.remoting.netty.host:}"/>

               <param key="port"  value="${hornetq.remoting.netty.port:5445}"/>

               <param key="tcp-send-buffer-size"  value="1048576"/>

               <param key="tcp-receive-buffer-size"  value="1048576"/>

               <param key="use-nio"  value="true"/>

               <param key="batch-delay"  value="50"/>

               <param key="use-nio"  value="true"/>



              <address-setting match="jms.queue.Record">








      All system variables (CPU / Memory / Disk IO / Network etc.) are underutilized and there are no errors in the logs.


      Note: We have tried with both NIO as well as the legacy / old IO. This has been tried both with HornetQ-2.2.5-Final and HornetQ-2.2.5-GA (this was built from source)


      Any idea as to what might be causing this issue and what the resolution might be?


      Other observations: It looks like the messages are being sent through the core bridge are transactional ... so is it possible to batch these transactions and have the communication between the two HornetQ instances happen asynchronously?