activemq-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Michael Chen (JIRA)" <j...@apache.org>
Subject [jira] Commented: (AMQ-1825) Pure MasterSlave doesn't work
Date Thu, 09 Apr 2009 17:51:34 GMT

    [ https://issues.apache.org/activemq/browse/AMQ-1825?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=51132#action_51132
] 

Michael Chen commented on AMQ-1825:
-----------------------------------

This has to do with NOT using the <broker waitForSlave="true" ... > setting. The steps
to reproduce are:

1. Start master (waitForSlave=false).
2. Let some client connect and send messages to a topic or queue.
3. Start the slave.
4. Send more messages, which will produce the following on the SERVER side log:

ERROR MasterBroker                   - Slave Failed
java.lang.IllegalStateException: Cannot lookup a producer from a connection that had not been
registered: ID:mwcs-37256-1237566087493-0:0
        at org.apache.activemq.broker.MapTransportConnectionStateRegister.lookupConnectionState(MapTransportConnectionStateRegister.java:73)
        at org.apache.activemq.broker.TransportConnection.lookupConnectionState(TransportConnection.java:1352)
        at org.apache.activemq.broker.TransportConnection.getProducerBrokerExchange(TransportConnection.java:1233)
        at org.apache.activemq.broker.TransportConnection.processMessage(TransportConnection.java:449)
        at org.apache.activemq.command.ActiveMQMessage.visit(ActiveMQMessage.java:639)
        at org.apache.activemq.broker.TransportConnection.service(TransportConnection.java:305)
        at org.apache.activemq.broker.TransportConnection$1.onCommand(TransportConnection.java:179)
        at org.apache.activemq.transport.ResponseCorrelator.onCommand(ResponseCorrelator.java:104)
        at org.apache.activemq.transport.TransportFilter.onCommand(TransportFilter.java:68)
        at org.apache.activemq.transport.vm.VMTransport.iterate(VMTransport.java:205)
        at org.apache.activemq.thread.DedicatedTaskRunner.runTask(DedicatedTaskRunner.java:98)
        at org.apache.activemq.thread.DedicatedTaskRunner$1.run(DedicatedTaskRunner.java:36)

The master still functions normally, but it keep receiving the above complain from the slave
on every replication. It seems that there is no "state replication" from the master to the
slave when the slave first attached. I suspect this is a design flaw that must be plugged.

The only remedy is to use the <broker waitForSlave="true" ... > setting. Unfortunately,
this degrades the pure master/slave significantly. If either the master or the slave is down,
there is no way to restore the down node without shutting down the running node.  This means
service interruption. The following no-service-interruption-scenarios are NOT possible:

Scenario1:
  master_up -> client_connect -> slave_up -> slave_down -> slave_restart

Scenario2:
  master_up -> client_connect -> slave_up -> master_down -> slave_become_master
-> master_restart_as_slave

No service interruption is a common expectation of redundancy. This bug is related to bug
AMQ-869.


> Pure MasterSlave doesn't work
> -----------------------------
>
>                 Key: AMQ-1825
>                 URL: https://issues.apache.org/activemq/browse/AMQ-1825
>             Project: ActiveMQ
>          Issue Type: Bug
>          Components: Broker
>    Affects Versions: 5.1.0
>            Reporter: Dima
>             Fix For: 5.3.0
>
>
> Slave doen't synchronize state with master
> 1.If master has messages which absent in slave, these messages won't replicate ot slave
after attaching slave to master.
> 2.If remove messages via JMX purge() in master, messages in slave won't remove
> 3. If slave has messages wich absent in master, these messages won't remove when slave
is attaching to master

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message