Skip to content

Alllow simple way to enable peerExchange #2001

Open
@vpavlin

Description

@vpavlin

This is a feature request

Problem

It seems that currently the only straightforward way to enable peerExchange is to set defaultBootstrap: true. This is problematic in case a user runs on a custom pubsubTopic or generally separate network and may not want to use default fleets to bootstrap.

It is possible to enable peerExchange by adding it to libp2p.peerDiscovery (thanks @danisharora099 !)

waku = await createLightNode({
        libp2p: {
          peerDiscovery: [
            wakuPeerExchangeDiscovery(pubsubTopic)
          ]
        }
      });

But it might be useful to either enable it by default, or add something like peerExchange: true to the top level config

Proposed Solutions

(these are or options:) )

  1. Enable peerExchange by default
  2. Add peerExchange parameter to createLightNode
  3. Document the current way (via libp2p.peerDiscovery)

Notes

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    Status

    To Do

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions