You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@activemq.apache.org by Oscar Pernas <os...@pernas.es> on 2011/03/11 23:24:54 UTC

ACTIVEMQ-CPP. Which broker is chosen in a failover URI.

I have an URI like this:

ipbroker="failover://(tcp://localhost:61616,tcp://sig-hormes10:61616)"

Sometimes when I start the application, the consumer starts to consume to
the second IP instead the first one. Why?

I've tested using initial reconnect delay but with the same issue.

-- 
Óscar Pernas Plaza.

Re: ACTIVEMQ-CPP. Which broker is chosen in a failover URI.

Posted by Henrique Magarotto <ma...@gmail.com>.
Try "randomize" option:
ipbroker="failover://(tcp://localhost:61616,tcp://sig-hormes10:61616)?randomize=false"

regards
Henrique

2011/3/11 Oscar Pernas <os...@pernas.es>
>
> I have an URI like this:
>
> ipbroker="failover://(tcp://localhost:61616,tcp://sig-hormes10:61616)"
>
> Sometimes when I start the application, the consumer starts to consume to
> the second IP instead the first one. Why?
>
> I've tested using initial reconnect delay but with the same issue.
>
> --
> Óscar Pernas Plaza.