[][src]Module libp2p::kad

Implementation of the libp2p-specific Kademlia protocol.

Modules

handler
kbucket

Implementation of a Kademlia routing table as used by a single peer participating in a Kademlia DHT.

protocol

The Kademlia connection protocol upgrade and associated message types.

record

Records and record storage abstraction of the libp2p Kademlia DHT.

Structs

AddProviderOk

The successful result of publishing a provider record.

Addresses

A non-empty list of (unique) addresses of a peer in the routing table.

BootstrapOk

The successful result of [Kademlia::bootstrap].

GetClosestPeersOk

The successful result of [Kademlia::get_closest_peers].

GetProvidersOk

The successful result of [Kademlia::get_providers].

GetRecordOk

The successful result of [Kademlia::get_record].

Kademlia

Network behaviour that handles Kademlia.

KademliaConfig

The configuration for the Kademlia behaviour.

PutRecordOk

The successful result of [Kademlia::put_record].

Enums

AddProviderError

The possible errors when publishing a provider record.

BootstrapError

The error result of [Kademlia::bootstrap].

GetClosestPeersError

The error result of [Kademlia::get_closest_peers].

GetProvidersError

The error result of [Kademlia::get_providers].

GetRecordError

The error result of [Kademlia::get_record].

KademliaEvent

The events produced by the Kademlia behaviour.

PutRecordError

The error result of [Kademlia::put_record].

Quorum

A quorum w.r.t. the configured replication factor specifies the minimum number of distinct nodes that must be successfully contacted in order for a query to succeed.

Constants

ALPHA_VALUE

The α parameter of the Kademlia specification.

Type Definitions

AddProviderResult

The result of publishing a provider record.

BootstrapResult

The result of [Kademlia::bootstrap].

GetClosestPeersResult

The result of [Kademlia::get_closest_peers].

GetProvidersResult

The result of [Kademlia::get_providers].

GetRecordResult

The result of [Kademlia::get_record].

PutRecordResult

The result of [Kademlia::put_record].