[−][src]Crate sc_authority_discovery
Substrate authority discovery.
This crate enables Substrate authorities to directly connect to other authorities.
AuthorityDiscovery
implements the Future trait. By polling AuthorityDiscovery
an
authority:
-
Makes itself discoverable
-
Retrieves its external addresses.
-
Adds its network peer id to the addresses.
-
Signs the above.
-
Puts the signature and the addresses on the libp2p Kademlia DHT.
-
-
Discovers other authorities
-
Retrieves the current set of authorities.
-
Starts DHT queries for the ids of the authorities.
-
Validates the signatures of the retrieved key value pairs.
-
Adds the retrieved external addresses as priority nodes to the peerset.
-
Structs
AuthorityDiscovery | An |
Traits
NetworkProvider | NetworkProvider provides AuthorityDiscovery with all necessary hooks into the underlying Substrate networking. Using this trait abstraction instead of NetworkService directly is necessary to unit test AuthorityDiscovery. |