eth/eth_watch_dialer.hpp¶
Namespaces¶
| Name |
|---|
| eth |
Functions¶
| Name | |
|---|---|
| std::shared_ptr< discv4::WatcherPool > | make_eth_watcher_pool(const EthWatchConnectionConfig & config) Create the shared watcher connection pool used by chain peer dialers. |
| std::shared_ptr< discv4::DialScheduler > | start_eth_watch_chain_peer_dialing(boost::asio::io_context & io, std::shared_ptr< discv4::WatcherPool > pool, discv4::DialFn dial_fn, const std::vector< discv4::ValidatedPeer > & peers) Create a per-chain dial scheduler and enqueue the provided peer candidates. |
Functions Documentation¶
function make_eth_watcher_pool¶
std::shared_ptr< discv4::WatcherPool > make_eth_watcher_pool(
const EthWatchConnectionConfig & config
)
Create the shared watcher connection pool used by chain peer dialers.
Parameters:
- config Pool limits.
Return: Shared watcher pool.
function start_eth_watch_chain_peer_dialing¶
std::shared_ptr< discv4::DialScheduler > start_eth_watch_chain_peer_dialing(
boost::asio::io_context & io,
std::shared_ptr< discv4::WatcherPool > pool,
discv4::DialFn dial_fn,
const std::vector< discv4::ValidatedPeer > & peers
)
Create a per-chain dial scheduler and enqueue the provided peer candidates.
Parameters:
- io Boost.Asio context used by the scheduler.
- pool Shared watcher pool.
- dial_fn Callback used for each dial attempt.
- peers Validated RLPx/ETH peer candidates from
chain_enodes.json.nodes.
Return: Scheduler that owns the dial queue and active sessions.
Source code¶
// Copyright 2026 Genius Ventures, Inc.
// SPDX-License-Identifier: MIT
#ifndef EVMRELAY_INCLUDE_ETH_ETH_WATCH_DIALER_HPP
#define EVMRELAY_INCLUDE_ETH_ETH_WATCH_DIALER_HPP
#include <boost/asio/io_context.hpp>
#include <discv4/dial_scheduler.hpp>
#include <eth/eth_watch_service.hpp>
#include <memory>
#include <vector>
namespace eth
{
[[nodiscard]] std::shared_ptr<discv4::WatcherPool> make_eth_watcher_pool(
const EthWatchConnectionConfig& config);
[[nodiscard]] std::shared_ptr<discv4::DialScheduler> start_eth_watch_chain_peer_dialing(
boost::asio::io_context& io,
std::shared_ptr<discv4::WatcherPool> pool,
discv4::DialFn dial_fn,
const std::vector<discv4::ValidatedPeer>& peers);
} // namespace eth
#endif // EVMRELAY_INCLUDE_ETH_ETH_WATCH_DIALER_HPP
Updated on 2026-06-05 at 17:22:19 -0700