Closed chair28980 closed 1 year ago
I think part of this has been implemented already for WakuRelay since https://github.com/waku-org/go-waku/pull/595 , because anytime Relay().Subscribe
is called or a pubsub subscription is closed, the ENR is updated with the new shards.
See https://github.com/waku-org/go-waku/blob/master/waku/v2/node/localnode.go#L288-L347
In https://github.com/waku-org/research/issues/3 the following is described:
Task: Peer discovery with dynamic shards as dimension Tracks work necessary to ensure that nodes can filter discovered peers according to the shards the node is currently subscribed to and for the node to update its own discoverable ENR every time its subscription set changes.
This does not mention specific protocols, so I have the following question: should a lightnode doing a filter subscription have its ENR affected as well? cc: @SionoiS
@richard-ramos
What I did in Nwaku was to update the ENR (and filter) that discv5 use which is different from the waku_node
one but that's impl. details.
This does not mention specific protocols, so I have the following question: should a lightnode doing a filter subscription have its ENR affected as well?
:thinking: probably not since lightnode are not discoverable anyway.
I see, in that case I'd consider this task to be complete.
Closing this as per above discussion as it is already addressed. Any new scenarios identified would be taken up as maintenance.
Tracks work necessary to ensure that nodes can filter discovered peers according to the shards the node is currently subscribed to and for the node to update its own discoverable ENR every time its subscription set changes.
Priority: Critical for launch.