go-libp2p-circuit icon indicating copy to clipboard operation
go-libp2p-circuit copied to clipboard

Discovery shouldn't tag relays

Open vyzo opened this issue 6 years ago • 2 comments

We have this code: https://github.com/libp2p/go-libp2p-circuit/blob/master/notify.go#L49 which tags all relays discovered with passive discovery.

This was useful before autorelay, but it seems to result in a large number of idle connections.

What was the rationale for it? I suggest we remove this tag.

cc @whyrusleeping who added the tag, @Stebalien

vyzo avatar Apr 26 '19 11:04 vyzo

We probably added it assuming that we're more likely to connect to peers behind relays than not. These nodes are strictly more useful.

Given the low tag value, I'm happy either way.

Stebalien avatar Apr 30 '19 18:04 Stebalien

yeah, not binding. I am not dead set on removing them either.

vyzo avatar Apr 30 '19 18:04 vyzo