CanRetry

Trait CanRetry 

Source
pub trait CanRetry {
    // Required method
    fn can_retry(&self) -> bool;

    // Provided methods
    fn is_no_available_addresses(&self) -> bool { ... }
    fn is_node_failure(&self) -> bool { ... }
}
Expand description

Returns true if the operation can be retried.

Required Methods§

Source

fn can_retry(&self) -> bool

Returns true if the operation can be retried safely.

Provided Methods§

Source

fn is_no_available_addresses(&self) -> bool

Returns true if this error represents a “no available addresses” condition.

When all addresses have been banned due to errors, the client returns this error. Retry logic uses this to return the last meaningful error instead of this one.

Source

fn is_node_failure(&self) -> bool

👎Deprecated: Use !can_retry() instead

Get boolean flag that indicates if the error is retryable.

Deprecated in favor of CanRetry::can_retry.

Implementations on Foreign Types§

Source§

impl CanRetry for Status

Source§

fn can_retry(&self) -> bool

Implementors§