Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

When no explicit provider addr is configured listen to local address changes and use the latest #371

Open
masih opened this issue May 30, 2023 · 0 comments

Comments

@masih
Copy link
Member

masih commented May 30, 2023

The provider engine allows a user to explicitly set provider addrs in 2 ways:

  1. as option to engine, and
  2. as argument passed to NotifyPut

When no such setting exists, it uses the given libp2p host addrs by caching the host addrs in options.
This means when the libp2p local addrs change, engine will not reflect the changes.

Instead, when no explicit provider addr is given the engine should listen to libp2p eventbus for local address changes and use the latest addrs in subsequent advertisements. Specifically, the event it should listen to is EvtLocalAddressesUpdated.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant