Skip to content

No addresses of peer after successful kademlia lookup? #5371

Answered by guillaumemichel
Wiezzel asked this question in Q&A
Discussion options

You must be logged in to vote

It is likely that the bucket to which the target peer belong is already full, so the addresses aren't stored in the kad routing table.

This is indeed a serious issue.

I can see two ways to address it:

  • implement a Peerstore (see #4103)
  • emit a FromSwarm::NewExternalAddrOfPeer event (context in #4371). This event could be emitted either a) for the target of the FIND_NODE RPC only or b) for all discovered peers in a request (probably overkill). The caller of the kademlia lookup then needs to handle the addresses.

The Peerstore seems to be the right approach, although it may not be straightforward to implement. Emitting a FromSwarm::NewExternalAddrOfPeer event could be a temporary quick fix.

Replies: 2 comments 13 replies

Comment options

You must be logged in to vote
2 replies
@Wiezzel
Comment options

@Wiezzel
Comment options

Comment options

You must be logged in to vote
11 replies
@Wiezzel
Comment options

@guillaumemichel
Comment options

@Wiezzel
Comment options

@guillaumemichel
Comment options

Answer selected by Wiezzel
@guillaumemichel
Comment options

@Wiezzel
Comment options

@Wiezzel
Comment options

@guillaumemichel
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
3 participants