Why are you only forwarding one destination per networkConnector, and a different one in each case? And what destination are you publishing to?
It sounds like you believe that you have a master/slave cluster (you say "cluster1 is the active machine"), but that's not true. What you actually have is a mesh network of brokers, where each broker is a standalone entity that can forward messages to the others (and a message exists on only one broker at a time) and where all brokers are active at all times. If any of that is a surprise to you, you need to read up on those subjects on the wiki. You've limited which destinations will have messages forward to which other brokers (for reasons I don't understand, but hopefully you'll explain), which seems incompatible with your failover URI (which means that a client will connect to only one of the brokers and that they're all equivalent, which isn't true because some destinations can only be forwarded to certain brokers but not others. I suspect that your problem will disappear by forwarding all destinations (using the wildcard ">") to all other brokers, but I'm not sure what you were trying to accomplish with it in the first place. Also, I think you'll want to set the decreaseNetworkConsumerPriority="true" option; see http://activemq.apache.org/networks-of-brokers.html for more details. Tim On Jan 6, 2016 3:33 PM, "tybreizh29" <mlem...@vecsys.fr> wrote: > Hi, > I've got 4 machines running ActiveMQ, the config is (names, ports > changed): > > <networkConnectors> > <networkConnector name="SYSTEM1" duplex="true" > uri="static:(tcp://cluster1.aaa.com:222)" userName="system" password=""> > <dynamicallyIncludedDestinations> > <topic physicalName="outgoing.System1" /> > </dynamicallyIncludedDestinations> > </networkConnector> > <networkConnector name="SYSTEM2" duplex="true" > uri="static:(tcp://amidala.aaa.com:222)" userName="system" password=""> > <dynamicallyIncludedDestinations> > <topic physicalName="outgoing.System2"/> > </dynamicallyIncludedDestinations> > </networkConnector> > <networkConnector name="SYSTEM3" duplex="true" > uri="static:(tcp://msf01.aaa.com:222)" userName="system" password=""> > <dynamicallyIncludedDestinations> > <topic physicalName="outgoing.System3"/> > </dynamicallyIncludedDestinations> > </networkConnector> > <networkConnector name="SYSTEM4" duplex="true" > uri="static:(tcp://msf02.aaa.com:222)" userName="system" password=""> > <dynamicallyIncludedDestinations> > <topic physicalName="outgoing.System4"/> > </dynamicallyIncludedDestinations> > </networkConnector> > </networkConnectors> > > > I write messages into a cluster1 queue using PHP and STOMP, I see the > message in cluster1 web console (jetty one). > I don't see the message on others web gui. They say cluster1 is the active > machine. > > I want to read the message with java, the uri is: > 'failover:(tcp://msf01.aaa.com:222,tcp://msf02.aaa.com:222,tcp:// > cluster1.aaa.com:222,tcp://amidala.aaa.com:222 > )?timeout=10000&jms.prefetchPolicy.queuePrefetch=1'; > > there is no message to read with this settings, > if i put cluster1 as the first machine in the failover machine order, it > works, but like that I'm not sure the failover works. > > what's wrong with my setting. > thanks for your help. > marc > > > > > > > > -- > View this message in context: > http://activemq.2283324.n4.nabble.com/failover-and-cannot-access-queue-tp4705622.html > Sent from the ActiveMQ - User mailing list archive at Nabble.com. >