pub unsafe extern "C" fn cass_cluster_set_exponential_reconnect(
    cluster: *mut CassCluster,
    base_delay_ms: cass_uint64_t,
    max_delay_ms: cass_uint64_t
) -> CassError
Expand description

Configures the cluster to use a reconnection policy that waits exponentially longer between each reconnection attempt; however will maintain a constant delay once the maximum delay is reached.

Default:

  • 2000 milliseconds base delay
  • 60000 milliseconds max delay

Note: A random amount of jitter (+/- 15%) will be added to the pure exponential delay value. This helps to prevent situations where multiple connections are in the reconnection process at exactly the same time. The jitter will never cause the delay to be less than the base delay, or more than the max delay.

@public @memberof CassCluster

@param[in] cluster @param[in] base_delay_ms The base delay (in milliseconds) to use for scheduling reconnection attempts. @param[in] max_delay_ms The maximum delay to wait between two reconnection attempts. @return CASS_OK if successful, otherwise error occurred.