Skip to content

eth::rpc::RpcEndpointPool

#include <rpc_manager.hpp>

Public Functions

Name
RpcEndpointPool() =default
RpcEndpointPool(std::vector< RpcEndpoint > endpoints)
const std::vector< RpcEndpoint > & endpoints() const
std::vector< RpcEndpoint > & endpoints()
std::optional< std::reference_wrapper< RpcEndpoint > > next_endpoint()
std::optional< std::reference_wrapper< const RpcEndpoint > > next_endpoint() const
void mark_temporary_failure(std::string_view url)
void disable(std::string_view url)
void reset_temporary_failures()

Public Attributes

Name
auto kMaxBackoff
auto kBaseBackoff
auto kEscalationWindow
uint32_t kEscalationThreshold

Public Functions Documentation

function RpcEndpointPool

RpcEndpointPool() =default

function RpcEndpointPool

explicit RpcEndpointPool(
    std::vector< RpcEndpoint > endpoints
)

function endpoints

inline const std::vector< RpcEndpoint > & endpoints() const

function endpoints

inline std::vector< RpcEndpoint > & endpoints()

function next_endpoint

std::optional< std::reference_wrapper< RpcEndpoint > > next_endpoint()

function next_endpoint

std::optional< std::reference_wrapper< const RpcEndpoint > > next_endpoint() const

function mark_temporary_failure

void mark_temporary_failure(
    std::string_view url
)

function disable

void disable(
    std::string_view url
)

function reset_temporary_failures

void reset_temporary_failures()

Public Attributes Documentation

variable kMaxBackoff

static auto kMaxBackoff = std::chrono::seconds(60);

variable kBaseBackoff

static auto kBaseBackoff = std::chrono::seconds(1);

variable kEscalationWindow

static auto kEscalationWindow = std::chrono::minutes(5);

variable kEscalationThreshold

static uint32_t kEscalationThreshold = 3;

Updated on 2026-06-05 at 17:22:18 -0700