* refactor discovery and common service to separate package to remove package inter-dependencies
* relay on-demand discovery ,use proto to enr field mapping
* chore: no need to dial discovered peers as peermanager already does that
* on demand discovery for service peers during peer selection
* identify supported protocols for discovered peers and add to service slots
* fix: tests to use proper static sharding topics
* fix: random selection with default pubsubTopic
---------
Co-authored-by: richΛrd <info@richardramos.me>
* feat: update lightpush API to make pubSubTopic optional as per autosharding
* Extract contentFilter and subscriptions out of filter to reuse in relay (#779)
* chore: extract contentFilter outside filter package
* chore: move subscription outside of filter so that it can be modified and reused for relay
* Feat: filter select peer for sharding (#783)
* update selectPeer to support pubsubTopic based selection
* fix: slice error for index out of bounds
this commit fixes slicing `notConnectedPeers` array with 0 to a negative value of `numPeersToConnect` by first checking if `numPeersToConnect` are greater than 0
* feat: add serviceSlot ds
* test: service slot
* nit: codeClimate related changs
* nit: based on comments
* nit: dont' run getPeers for WakuRelayIDv200
* refactor: peerConnector
* fix: code climate and dont waitOn subscriptions PeerData
* fix: check in peerConnector is on outRelay connections
* fix: introduced bug in peerConnector
* feat: support peermanager serviceslots and update store protocol to use serviceslots
* fix: lint errors in test code
* fix: error in nix build due to vendor sha change
* fix: set host in peermanager even if relay is disabled
* chore: fix codeclimate issues
* chore: using common filterPeer function to avoid duplication
* feat:use service slots in other service protocols
* chore: fix codeclimate issues
* chore: move AddPeer to peermanager
* Apply suggestions from code review
Co-authored-by: richΛrd <info@richardramos.me>
* chore:address review comments
* feat: implement RemovePeer #638
* chore: fix test failure
* Support for multiple slots for service peers
Adding discovered peers also moved to peer manager
---------
Co-authored-by: richΛrd <info@richardramos.me>
* chore: refactor existing code into peer maanger package
* feat: move peer connection related code into peer manager
* feat: in relay peer connection pruning
* feat: add max-connections CLI flag and limit outRelayPeers based on max-connections #621
* tested both in and out relay connection limits
Co-authored-by: richΛrd <info@richardramos.me>
* Review comment, use context to pause connectivity loop during node shutdown.
Co-authored-by: richΛrd <info@richardramos.me>
* address review comments
---------
Co-authored-by: richΛrd <info@richardramos.me>