Module libp2p_network

Source
Expand description

Libp2p based/production networking implementation This module provides a libp2p based networking implementation where each node in the network forms a tcp or udp connection to a subset of other nodes in the network

Structs§

Empty
Stubbed out Ack
GossipConfig
Configuration for Libp2p’s Gossipsub
Libp2pMetricsValue
Libp2p-specific metrics
Libp2pNetwork
Networking implementation that uses libp2p generic over M which is the message type
Libp2pNetworkInner 🔒
The underlying state of the libp2p network
RequestResponseConfig
Configuration for Libp2p’s request-response

Constants§

QC_TOPIC
hardcoded topic of QC used

Functions§

derive_libp2p_keypair
Derive a Libp2p keypair from a given private key
derive_libp2p_multiaddr
Parse a Libp2p Multiaddr from a string. The input string should be in the format hostname:port or ip:port. This function derives a Multiaddr from the input string.
derive_libp2p_peer_id
Derive a Libp2p Peer ID from a given private key

Type Aliases§

BootstrapAddrs
convenience alias for the type for bootstrap addresses concurrency primitives are needed for having tests
PeerInfoVec
Type alias for a shared collection of peerid, multiaddrs