Adin Schmahmann fcbc5f9e7f
Asynchronous lookups (#498)
* feat(query): fully async implementation of Kademlia lookup. peers returned from the lookup are not guaranteed to be alive (i.e. we're only guaranteed to have dialed the closest beta peers to the target), but given stable and correct routing tables the expectation that most of the peers returned are alive is high.
* feat(query): add wrapper lookup followup function to followup after the lookup is completed and ensure that the closest k returned peers from a lookup have been queried even for beta < k
* refactor(query) modified the structure returned from lookups to be a useful subset of the full query state instead of the entire query state
* feat(options): beta parameter exposed as the Resiliency parameter
* feat(routing): do not mark the routing table as updated after a FindPeer query
* feat(routing): FindPeer can return addresses even if not Connected as long as it was either recently connected (CanConnect) or was discovered during the lookup
* feat(bootstrap): bootstrap logic now uses GetClosestPeers instead of FindPeer
* refactor(dht): stopFn no longer takes any state
* fix(test): changed GetClosestPeers test to only assume beta instead of k peers since that is now more appropriate given the query logic changes and that the routing tables in that test are bad, i.e. a ring network with arbitrary peerIDs

Co-authored-by: Petar Maymounkov <petarm@gmail.com>
Co-authored-by: Aarsh Shah <aarshkshah1992@gmail.com>
2020-03-24 11:17:48 -04:00
2019-03-21 10:39:18 -07:00
2020-03-03 18:07:08 -08:00
2020-03-10 16:22:41 -04:00
2020-03-24 11:17:48 -04:00
2019-12-06 16:31:34 -05:00
2020-03-10 14:51:28 -07:00
2020-03-24 11:17:48 -04:00
2020-03-10 14:51:28 -07:00
2020-03-24 11:17:48 -04:00
2020-03-24 11:17:48 -04:00
2020-03-24 11:17:48 -04:00
2019-01-09 14:21:14 +11:00
2020-03-10 14:51:28 -07:00
2020-03-19 18:27:06 +05:30
2020-03-19 18:27:06 +05:30
2020-03-10 14:51:28 -07:00
2016-10-14 10:57:10 -04:00
2019-02-15 15:14:43 +11:00
2019-12-19 12:04:25 -05:00
2020-03-24 11:17:48 -04:00
2019-03-21 13:46:16 -07:00
2020-03-24 11:17:48 -04:00
2020-03-10 16:22:41 -04:00
2019-11-15 10:54:09 +08:00
2020-03-24 11:17:48 -04:00
2020-03-10 14:51:28 -07:00

go-libp2p-kad-dht

GoDoc Build Status Discourse posts

A Kademlia DHT implementation on go-libp2p

Table of Contents

Install

go get github.com/libp2p/go-libp2p-kad-dht

Usage

Go to https://godoc.org/github.com/libp2p/go-libp2p-kad-dht.

Contribute

Contributions welcome. Please check out the issues.

Check out our contributing document for more information on how we work, and about contributing in general. Please be aware that all interactions related to libp2p are subject to the IPFS Code of Conduct.

Small note: If editing the README, please conform to the standard-readme specification.

License

MIT © Protocol Labs Inc.


The last gx published version of this module was: 4.4.34: QmXuNFLZc6Nb5akB4sZsxK3doShsFKT1sZFvxLXJvZQwAW

Description
No description provided
Readme MIT 2.5 MiB
Languages
Go 99.9%