Top
Best
New

Posted by gasull 6/25/2025

Iroh: A library to establish direct connection between peers(github.com)
268 points | 57 commentspage 2
throw10920 6/26/2025|
I've been wanting something like what Syncthing does for peer discovery for a while - something like this. Too bad it's written in such a low-level language.
outside1234 6/26/2025||
The promise of this is super interesting. How would people compare it to libp2p? Is libp2p a lower level toolkit that leaves the assembly to you?
dpc_01234 6/26/2025|
Each time I looked at libp2p I didn't even knew where to begin. With Iroh it was trivial to get connections.

Also, AFAIK, Iroh makes some architectural choices (using relays to help establish connections), that make it less "pure p2p", but much more likely to actually work reliably.

splintercell 6/26/2025||
I'm using GunDB (for my still in-development project), what would I need to migrate from GunDB to Iroh?
swoorup 6/26/2025||
Does this always have to be p2p or does it also allow for client server architecture
rklaehn 6/26/2025||
The two sides are peers when it comes to connection establishment, but once you have a connection they can and frequently will have different roles.

Many existing iroh protocols have clear client and server roles once the connection is established. E.g. gossip is a peer to peer protocol, blobs is a client server protocol in that one side provides data and the other requests it.

For a client you can use an ephemeral node id and not publish your info to discovery, since you will never be dialed yourself.

dpc_01234 6/26/2025||
It just makes a connection between two sides. How you use it (e.g. client makes a request, server responds) is up to you. So yes.
Calwestjobs 6/26/2025||
This is what GIT should had from start ! Imagine...
b0a04gl 6/25/2025|
lets say if i someone wants to keep using bittorrent dht for peer finding but swap out quic for something else maybe grpc, does the lib support that split clean? asking from a modular embed first tooling pov, where discovery logic needs to outlive or outswap transport depending on deployment
b_fiive 6/25/2025|
yep totally doable. You'd use iroh configured with mainline, Then write a custom protocol for the grpc bit: https://www.iroh.computer/docs/protocols/writing

We use this a bunch for writing rpc protocols on iroh: https://github.com/n0-computer/irpc , but there's no reason you couldn't write one with grpc.