Hi,

I want to combine a master/slave technology with a network of brokers. The
idea is to have a central master/slave combination, and a remote ActiveMQ
server connected to the master/slave. The Master/Slave should always be
available, messages posted to the remote server are less important, that is,
there is no need for HA there. Is this setup possible?

My idea was to create a master/slave combination, and have them both connect
to the remote server with a <networkConnector> configuration. The remote
server connects to the master/slave combination with a <networkConnector>
with a failover:// protocol. This seems to work fine if all servers are up &
running, but if I bring down the master server, the remote server gets error
messages like 'Unexpected local command'. The slave server seems to take
over the master just fine.

Here are the relevant parts of the configuration:

Master:
 <broker brokerName="dev" useJmx="true" persistent="true"
xmlns="http://activemq.org/config/1.0";>
    <transportConnectors>
       <transportConnector name="openwire" uri="tcp://localhost:61616"/>
    </transportConnectors>
    
        <networkConnectors>
          <networkConnector name="ha-network"
uri="static://(tcp://localhost:61618)" networkTTL="5"/>
          </networkConnectors>
</broker>

Slave:
 <broker brokerName="dev-slave" useJmx="false" persistent="true"
xmlns="http://activemq.org/config/1.0";
masterConnectorURI="tcp://localhost:61616">
    <transportConnectors>
       <transportConnector name="openwire" uri="tcp://localhost:61617"/>
    </transportConnectors>
    
        <networkConnectors>
                <networkConnector name="ha-network" 
uri="static://(tcp://localhost:61618)"
networkTTL="5"/>
        </networkConnectors>    
</broker>


Remote:
 <broker brokerName="dev-remote" useJmx="false" persistent="true"
xmlns="http://activemq.org/config/1.0";>
    <transportConnectors>
       <transportConnector name="openwire" uri="tcp://localhost:61618"/>
    </transportConnectors>
    
    <networkConnectors>
          <networkConnector name="ha-network"
uri="static://(failover://(tcp://localhost:61616,tcp://localhost:61617)?randomize=false)"
networkTTL="5" />
    </networkConnectors>
  </broker>

Is it possible what I want? Can someone point me in the right direction?

Thanks.

With kind regards,

Pieter
-- 
View this message in context: 
http://www.nabble.com/Combining-MasterSlave-and-network-of-brokers-tf3751194s2354.html#a10600449
Sent from the ActiveMQ - User mailing list archive at Nabble.com.

Reply via email to