Qpid Proton C++ API  0.37.0
reconnect_options

Unsettled API - Options for reconnect and failover after connection loss. More...

#include <reconnect_options.hpp>

Public Member Functions

 reconnect_options ()
 Create an empty set of options.
 
 reconnect_options (const reconnect_options &)
 Copy options.
 
reconnect_optionsoperator= (const reconnect_options &)
 Copy options.
 
reconnect_optionsdelay (duration)
 The base value for recurring delays. More...
 
reconnect_optionsdelay_multiplier (float)
 The scaling multiplier for successive reconnect delays. More...
 
reconnect_optionsmax_delay (duration)
 The maximum delay between successive connect attempts. More...
 
reconnect_optionsmax_attempts (int)
 The maximum number of reconnect attempts. More...
 
reconnect_optionsfailover_urls (const std::vector< std::string > &conn_urls)
 Deprecated - use connection_options::failover_urls Alternative connection URLs used for failover. More...
 

Detailed Description

Unsettled API - Options for reconnect and failover after connection loss.

These options determine a series of delays to coordinate reconnection attempts. They may be open-ended or limited in time. They may be evenly spaced or increasing at an exponential rate.

Normal value semantics: copy or assign creates a separate copy of the options.

See also
messaging_handler, connection_options::reconnect()
Examples
simple_send.cpp.

Member Function Documentation

◆ delay()

The base value for recurring delays.

The default is 10 milliseconds.

◆ delay_multiplier()

reconnect_options& delay_multiplier ( float  )

The scaling multiplier for successive reconnect delays.

The default is 2.0.

◆ max_delay()

reconnect_options& max_delay ( duration  )

The maximum delay between successive connect attempts.

The default duration::FOREVER, meaning no limit.

◆ max_attempts()

reconnect_options& max_attempts ( int  )

The maximum number of reconnect attempts.

The default is 0, meaning no limit.

◆ failover_urls()

reconnect_options& failover_urls ( const std::vector< std::string > &  conn_urls)

Deprecated - use connection_options::failover_urls Alternative connection URLs used for failover.

There are none by default.


The documentation for this class was generated from the following file: