Skip to main content

select_bootstrap_peers

Function select_bootstrap_peers 

Source
pub fn select_bootstrap_peers(
    cached: impl IntoIterator<Item = MultiAddr>,
    configured: impl IntoIterator<Item = MultiAddr>,
) -> Vec<MultiAddr>
Expand description

Select startup bootstrap peers.

Cached peers are ordered first and configured bootstrap peers are appended behind them. saorsa-core stops client bootstrap after the client bootstrap target is reached, so configured peers are only reached when the cached candidates do not produce enough successful connections.