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

API for Topics management #53

Open
Tracked by #141 ...
hopeyen opened this issue Mar 27, 2023 · 4 comments
Open
Tracked by #141 ...

API for Topics management #53

hopeyen opened this issue Mar 27, 2023 · 4 comments

Comments

@hopeyen
Copy link

hopeyen commented Mar 27, 2023

It would be really nice to have a function returning topics related to the running node, such as

  • subscribed/unsubscribed pubsub/content topics
  • peer ids (as filter protocol is specific to peers)

This makes it easier to track and manage the topics

@danielSanchezQ
Copy link
Collaborator

@richard-ramos do we have something like that in the underlaying lib?

@richard-ramos
Copy link
Member

Hm. In go-waku we could access the list of topics via wakuNode.Relay().Topics() so we could expose that easily.
For the list of peers, in the current version of go-waku filter, there's no subscription management at client side, so there's no easy way to obtain the list of peers. One solution i could provide could be to instead of returning true when waku_filter_subscribe is executed, to instead return an object with the info for the subscription:

{
  peerId: ....,
  topic: ....,
  contentTopics: [ ... ]
}

and then subscription management could be done by the application using go-waku library.

...

In vacp2p/rfc#562 a lot of improvements over filter protocol are being done, and once they land in go-waku and nwaku i believe it will be easier to provide a list of active filter subscriptions.

@fryorcraken fryorcraken added the enhancement New feature or request label Sep 7, 2023
@fryorcraken fryorcraken added this to Waku Sep 7, 2023
@fryorcraken fryorcraken moved this to Triage in Waku Sep 7, 2023
@chair28980 chair28980 moved this from Triage to Priority in Waku Oct 31, 2023
@chair28980 chair28980 assigned richard-ramos and unassigned harsh-98 Nov 28, 2023
@richard-ramos richard-ramos moved this from Priority to In Progress in Waku Dec 13, 2023
@chair28980
Copy link
Contributor

This will need to be added to nwaku when we switch from go-waku to nwaku for Rust bindings.

@chair28980 chair28980 moved this from In Progress to Icebox in Waku Feb 6, 2024
@chair28980 chair28980 moved this from Icebox to To Do in Waku Feb 6, 2024
@chair28980 chair28980 added E:nwaku Bindings and removed enhancement New feature or request labels Feb 12, 2024
@chair28980
Copy link
Contributor

Added to Epic: waku-org/nwaku#2420

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: To Do
Development

No branches or pull requests

6 participants