Hi everyone, so I saw this code sample https://github.com/libp2p/go-libp2p-examples/tree/master/chat-with-rendezvous of libp2p, but I’m confused on how to notify other peers that a peer has disconnected so that they can close the stream for that peer, any Good resources that talks about libp2p in details…
The stream will be “reset” (closed with an error) on disconnect. Any in progress or future reads/writes will fail. There’s no need to notify anyone.
In terms of resources, the examples (and go-ipfs/go-bitswap/go-libp2p-pubsub, etc.) are the best resources.
Thanks, @stebalien, I have been able to fix that using https://pkg.go.dev/github.com/libp2p/go-libp2p-pubsub package