The ActiveMQ project site, 2004–2007 · independent archive
Independent historical archive. This site preserves the ActiveMQ project pages that were published at activemq.org in 2004–2007. It is not the project’s website and is not affiliated with or endorsed by the Apache Software Foundation. ActiveMQ and Apache are trademarks of the ASF. For current downloads and documentation go to activemq.apache.org.

Archive › Documentation › Failover Transport Reference

Archived page

Failover Transport Reference

Archived from http://www.activemq.org/site/failover-transport-reference.html, captured 2006-08-29 · view the capture · Added by Hiram Chirino, last edited by Rob Davies on Jul 25, 2006

The Failover Transport

The Failover transport layers reconnect logic on top of any of the other transports. This is what used to be the Reliable transport in ActiveMQ 3. It's configuration syntax allows you to specify any number of composite uris. The Failover transport randomly chooses one of the composite URI and attempts to establish a connection to it. If it does not succeed or if it subsequently fails, a new connection is established to one of the other uris in the list.

Configuration Syntax

failover:(uri1,...,uriN)?transportOptions
or
failover:uri1,...,uriN

Transport Options
Option Name Default Value Description
initialReconnectDelay 10 How long to wait before the first reconnect attempt
maxReconnectDelay 30000 The maximum amount of time we ever wait between reconnect attempts
useExponentialBackOff true Should an exponential backoff be used btween reconnect attempts
backOffMultiplier 2 The exponent used in the exponential backoff attempts
maxReconnectAttempts 0 If not 0, then this is the maximum number of reconnect attempts before an error is sent back to the client
random true use a random algorithm to choose the the URI to use for reconnect from the list provided
Example URI
failover:(tcp://localhost:61616,tcp://remotehost:61616)?initialReconnectDelay=100

More from the archive