You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@activemq.apache.org by "Timothy Bish (JIRA)" <ji...@apache.org> on 2012/11/29 22:28:58 UTC

[jira] [Closed] (AMQ-3489) Slave not replicating consumption with Pure Master Slave

     [ https://issues.apache.org/jira/browse/AMQ-3489?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Timothy Bish closed AMQ-3489.
-----------------------------

    Resolution: Won't Fix

Pure master/slave removed in upcoming v5.8.0
                
> Slave not replicating consumption with Pure Master Slave
> --------------------------------------------------------
>
>                 Key: AMQ-3489
>                 URL: https://issues.apache.org/jira/browse/AMQ-3489
>             Project: ActiveMQ
>          Issue Type: Bug
>          Components: Broker
>    Affects Versions: 5.4.2, 5.5.0
>            Reporter: Dan Checkoway
>
> I'm seeing some strange behavior with ActiveMQ 5.4.2 pure master slave setup...
> 5.4.2 master running on mqmaster01:
>  <broker xmlns="http://activemq.apache.org/schema/core" brokerName="localhost" dataDirectory="${activemq.base}/data" destroyApplicationContextOnStop="true" schedulerSupport="false" advisorySupport="false">
> ...
>         <transportConnectors>
>             <transportConnector name="openwire" uri="tcp://0.0.0.0:61616"/>
>         </transportConnectors>
> 5.4.2 slave running on mqslave01:
>     <broker masterConnectorURI="tcp://mqmaster01:61616" shutdownOnMasterFailure=
> "false" xmlns="http://activemq.apache.org/schema/core" brokerName="localhost" da
> taDirectory="${activemq.base}/data" destroyApplicationContextOnStop="true" sched
> ulerSupport="false" advisorySupport="false">
> ...
>         <transportConnectors>
>             <transportConnector name="openwire" uri="tcp://0.0.0.0:61616"/>
>         </transportConnectors>
> Producers and consumers are using this connection URL:
> failover:(tcp://mqmaster01:61616,tcp://mqslave01:61616)?randomize=false
> Here's what I'm seeing.  I start up the master.  My producers/consumers connect immediately (they were waiting to connect) and begin doing their thing.
> I then start up the slave (with a freshly emptied ./data dir).  The slave connects to the master, as witnessed by this in data/activemq.log on mqslave01:
> 2011-08-24 22:51:48,833 | INFO  | Starting a slave connection between vm://localhost#0 and tcp://mqmaster01:61616 | org.apache.activemq.broker.ft.MasterConnector | main
> 2011-08-24 22:51:48,843 | INFO  | Slave connection between vm://localhost#0 and tcp://mqmaster01/10.0.3.42:61616 has been established. | org.apache.activemq.broker.ft.MasterConnector | main
> Shortly thereafter, a message is sent to a queue.  A consumer consumes it.  On mqmaster01, I can see on http://mqmaster01:8161/admin/queues.jsp that the enqueue/dequeue count went up by one, and "Number Of Pending Messages" is zero.  All good, right?
> Yeah, except mqslave01 now shows Messages Enqueued = 1, and Number Of Pending Messages = 1.  As more messages run through the system, mqslave01's enqueue & pending count continues to go up, but the dequeue count remains at zero.  I don't understand why the slave isn't replicating the consumption of these messages...
> Has anybody seen this before?  Any idea what might be causing it?  Did I screw something up in my configuration, i.e. with schedulerSupport="false" or advisorySupport="false"?
> Any help would be much appreciated... 
> ------------------------------------------
> Torsten then posted:
> Hi,
> I just gave it a quick test here using the latest 5.5 release and there does indeed seem to be an issue.
> Was sending and consuming msgs on the master broker using a new queue and the JMX properties got updated correctly on both master and slave.
>  
> However when sending some msgs to queue example.A which also has a Camel consumer connected, I noticed the same problem as reported here. On the slave the Enqueue Count rises correctly but dequeue and dispatch count remain 0. QueueSize is at EnqueueCount number, despite all msgs being consumed already.
> I further noticed the following error in the slave log:
> WARN | Async error occurred: java.lang.IllegalStateException: Cannot lookup a connection that had not been registered: ID:mac.fritz.box-53812-1315495654277-4:1
> java.lang.IllegalStateException: Cannot lookup a connection that had not been registered: ID:mac.fritz.box-53812-1315495654277-4:1
>         at org.apache.activemq.broker.MapTransportConnectionStateRegister.lookupConnectionState(MapTransportConnectionStateRegister.java:97)
>         at org.apache.activemq.broker.TransportConnection.lookupConnectionState(TransportConnection.java:1444)
>         at org.apache.activemq.broker.TransportConnection.processRemoveProducer(TransportConnection.java:530)
>         at org.apache.activemq.command.RemoveInfo.visit(RemoveInfo.java:78)
>         at org.apache.activemq.broker.TransportConnection.service(TransportConnection.java:316)
>         at org.apache.activemq.broker.TransportConnection$1.onCommand(TransportConnection.java:180)
>         at org.apache.activemq.transport.ResponseCorrelator.onCommand(ResponseCorrelator.java:116)
>         at org.apache.activemq.transport.TransportFilter.onCommand(TransportFilter.java:69)
>         at org.apache.activemq.transport.vm.VMTransport.iterate(VMTransport.java:218)
>         at org.apache.activemq.thread.DedicatedTaskRunner.runTask(DedicatedTaskRunner.java:98)
>         at org.apache.activemq.thread.DedicatedTaskRunner$1.run(DedicatedTaskRunner.java:36)
> There seems to be a problem here.
> Dan, if you have the time, could you raise a new JIRA for this problem?
> Thanks,
> Torsten Mielke 

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira