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

Iroh GossipSub topic tracker #262

Open
rustonbsd opened this issue Jan 14, 2025 · 3 comments
Open

Iroh GossipSub topic tracker #262

rustonbsd opened this issue Jan 14, 2025 · 3 comments

Comments

@rustonbsd
Copy link

I wanted to some feedback about my Iroh protocol lib.
A protocol that allows Iroh nodes using GossipSub to find each others node id's based on a Gossip Topic.

Here an example:

use iroh_topic_tracker::topic_tracker::TopicTracker;

let topic = Topic::from_passphrase("my test topic");
let endpoint = Endpoint::builder()
    .secret_key(SecretKey::generate(rand::rngs::OsRng))
    .discovery_n0()
    .discovery_dht()
    .bind()
    .await?;

let topic_tracker = TopicTracker::new(&endpoint);
let router = Router::builder(endpoint.clone())
    .accept(TopicTracker::ALPN, topic_tracker.clone())
    .spawn()
    .await?;
topic_tracker.get_topic_nodes(&topic).await?;

I would love some feedback and to know about the requirements a pull request to add a new protocol to your docs. I realise this is in no way ready for that. Just wandering. Would love to contribute.

Thank you for making a great lib!

https://github.com/rustonbsd/iroh-topic-tracker

@Arqu Arqu added this to iroh Jan 14, 2025
@dignifiedquire
Copy link
Contributor

Thanks a lot, in general we are very open to adding protocols from the community. We don't have clear requirements yet, some general things that would be good to have

  • some basic docs & some tests
  • readme structure similar to our existing ones, as we use that to generate the docs on the website
  • a published crate
  • license similar to iroh, or an explicit note that it is different

@rustonbsd
Copy link
Author

I will get on that and post an update as a pull request or would you like me to keep this issue open?

@rustonbsd
Copy link
Author

rustonbsd commented Jan 26, 2025

Hi @dignifiedquire, I implemented your suggestions. what else would you like to see added to make this a valid protocol to be added?

some basic docs & some tests:
work in progress..
see repo: https://github.com/rustonbsd/iroh-topic-tracker
or docs.rs: https://docs.rs/iroh-topic-tracker/0.1.9/iroh_topic_tracker/

readme structure similar to our existing ones, as we use that to generate the docs on the website:
let me know if you would like anything changed
README

a published crate:
https://crates.io/crates/iroh-topic-tracker

license similar to iroh, or an explicit note that it is different:
i just switched to the same dual license of iroh to keep it simple

Thank you and best regards

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

No branches or pull requests

2 participants