Skip to main content

Module peer_cache

Module peer_cache 

Source
Expand description

Persistent client bootstrap peer cache.

Client peer IDs are ephemeral, so this cache is not keyed by distance from the local client. It remembers authenticated node peers that we have already connected to directly during client runs, stores their dialable channel addresses, and prefers retaining peers that are spread across the peer-id keyspace.

Enums§

BootstrapAddressFilter
Address families allowed when materializing cached startup candidates.

Constants§

CLIENT_PEER_CACHE_MAX_PEERS

Functions§

cache_path
Build the on-disk cache path for the client peer cache.
cached_bootstrap_peers
Load cache addresses to try before configured bootstrap peers.
cached_bootstrap_peers_with_filter
Load cache addresses to try before configured bootstrap peers, applying an address-family filter before choosing the first address for each peer.
promote_connected_direct_peers
Persist authenticated peers reached directly during this client run.
select_bootstrap_peers
Select startup bootstrap peers.