3 Replies Latest reply on Aug 23, 2011 3:32 PM by ameya mk

    Static Cluster Discovery issues

    ameya mk Newbie

      Hi,

       

      I am trying to setup HornetQ cluster in static discovery mode.

       

      Here is overall setup:

       

      2 servers:

       

      hornetq1.ec

      hornetq2.ec

       

      I'd like these 2 servers to be in cluster mode. My configurations are as follows:

       

      On server 1:

       

      <clustered>true</clustered>

       

      <connector name="hornetq2.ec">

               <factory-class>org.hornetq.core.remoting.impl.netty.NettyConnectorFactory</factory-class>

                 <param key="host" value="hornetq2.ec" />

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

      </connector>

       

      AND

       

      <cluster-connections>

            <cluster-connection name="my-cluster">

               <address>jms</address>

               <connector-ref>netty-connector</connector-ref>

               <retry-interval>500</retry-interval>

               <use-duplicate-detection>true</use-duplicate-detection>

               <forward-when-no-consumers>true</forward-when-no-consumers>

               <max-hops>1</max-hops>

               <static-connectors>

                  <connector-ref>hornetq2.ec</connector-ref>

               </static-connectors>

            </cluster-connection>

         </cluster-connections>

       

       

      Similar configs on server2

       

      I have consumers connected to both the servers.

       

      I am sending 100+ messages to hornetq1.ec and I was expecting load balanced output to both the consumers. However only consumer connected to hornetq1.ec receiving all the messages.

       

      Am I missing something?