6 Replies Latest reply on Feb 16, 2011 7:18 AM by Andy Taylor

    Live Backup pair with replication issue - queue does not seem to replicate

    alon zamir Newbie


      I'm a hornetQ newvbie, just started evaluating the platform.

      I want to test the replication feature with live/ backup pair of standalone, non clustered servers, as explained in chapter 39 of user manual.

      I use jmx as a monitor tool for the server queue state.

      After the basic test, it seems like the replication feature is not working as it should be.I'd like to know whether its a configuration problem.


      the test:


      1. start backup server

      2. start live (main) server

      3. client connects to main server and produceses a message in the queue ( note that there are no defined consumer for this queue)

      4. via jmx / jconsole, I see the queue's MessageCount and MessagesAdded properties increase ( from  0 to 1):

      - org.hornetq

      -------    Acceptor

      --------------- Queue

      ----------------- Core

      ----------------------- queue name

      ---------------------------  ( queue attributes)



      5. browsing the backup server via jmx /jconsole, I only see the following in the mbeans tree:


      - org.hornetq

      -------    Acceptor

           ---------------- Core

      ( without any of the queue information )


      However, If my client producees a message directly to the backup server, I do see the Queue mbean in the mbeans tree, but it does not look like there was any replication taking place.


      client code ( injection via spring):




          public void testSpringJMSTemplate(){

             this.jmsTemplate.send("bbb", new MessageCreator() {

                  public Message createMessage(Session session) throws JMSException {

                    TextMessage text = session.createTextMessage("hello  world");

                      return text;





      configuration of client:


      <bean name="connectionFactory" class="org.hornetq.jms.client.HornetQConnectionFactory" >


            <bean class="org.hornetq.api.core.TransportConfiguration">

         <constructor-arg value="org.hornetq.core.remoting.impl.netty.NettyConnectorFactory" />


              <map key-type="java.lang.String" value-type="java.lang.Object">

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

               <entry key="host" value="server1"></entry>







          <bean name="jmsTemplate" class="org.springframework.jms.core.JmsTemplate">

           <property name="connectionFactory" ref="connectionFactory"></property>




      servers configurations are supposed to be the same as chapter 39 in the usermanual:


      I'd thanks,