Skip to content

P2P sync: add wrapper/abstraction for known peers #2188

@CHr15F0x

Description

@CHr15F0x

Instead of referring directly to libp2p::kad for known peers consider creating a wrapper that would hold the list of known peers.
The "list" would:

  • include "in-config" predefined peers (which ofc should also be in the local DHT)
  • be in sync with any kad updates (in particular new peers)

Pros:

  • syncing would proceed immediately provided that at least one peer was predefined via config,
  • internal p2p client logic wouldn't have to periodically poll for new/random peers.

Also see: #2187

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Projects

    Status

    Todo

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions