pub trait DhtContactsStoreTrait:
Sync
+ Send
+ 'static {
// Required methods
fn load_v4<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<HashSet<SocketAddrV4>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn load_v6<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<HashSet<SocketAddrV6>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn store_v4<'life0, 'async_trait>(
&'life0 self,
contacts: HashSet<SocketAddrV4>,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn store_v6<'life0, 'async_trait>(
&'life0 self,
contacts: HashSet<SocketAddrV6>,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
}Expand description
Persistent store for DHT contacts. It is periodically updated with the current DHT contacts and persisted. It is then used to provide additional nodes to bootstrap against on the next DHT discovery startup.