Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: support multiple peer selection for filter client #1005

Merged
merged 13 commits into from
Jan 26, 2024

Conversation

chaitanyaprem
Copy link
Collaborator

@chaitanyaprem chaitanyaprem commented Jan 11, 2024

Description

Addresses #1001 and provides an option for a user to specify upto how many peers a filter subscription is to be made

Changes

  • Update general peer selection algo to support multiple peer selection
  • Update Filter client code to support subscribing and unsubscribing from multiple peers
  • Add tests to validate behaviour

Notes: This PR is a little messy for now and makes filter code more complex 🙏, will refactor once we move out subscription management functionality to an SDK layer ( as prt of a new milestone)

  • Peer selection with RTT still selects only single peer, this will be taken up later.
  • Not supporting option to specify peers to be excluded (as we can subscribe to same peer again and the user for now can manage this) This limtation will gets addressed once we have proper subscription management implemented in filter-sdk layer.

@status-im-auto
Copy link

status-im-auto commented Jan 11, 2024

Jenkins Builds

Click to see older builds (10)
Commit #️⃣ Finished (UTC) Duration Platform Result
✔️ 2fd3c80 #1 2024-01-11 12:15:20 ~1 min nix-flake 📄log
✔️ dbf5b3f #2 2024-01-11 12:26:32 ~1 min nix-flake 📄log
✔️ 24a8247 #3 2024-01-12 10:09:57 ~2 min nix-flake 📄log
✔️ 1683250 #4 2024-01-12 10:48:45 ~1 min nix-flake 📄log
✔️ 4842808 #5 2024-01-12 10:54:14 ~1 min nix-flake 📄log
✔️ 9f2fb92 #6 2024-01-12 11:03:45 ~1 min nix-flake 📄log
✔️ 1a4bf26 #7 2024-01-12 11:43:10 ~2 min nix-flake 📄log
✔️ 21bb3b1 #8 2024-01-25 06:38:55 ~2 min nix-flake 📄log
✔️ 26cacfe #9 2024-01-25 07:16:13 ~2 min nix-flake 📄log
✔️ 4499312 #10 2024-01-25 10:44:30 ~1 min nix-flake 📄log
Commit #️⃣ Finished (UTC) Duration Platform Result
✔️ 836694a #11 2024-01-26 08:10:20 ~1 min nix-flake 📄log
✔️ a9f00af #12 2024-01-26 08:12:18 ~1 min nix-flake 📄log

waku/v2/peermanager/peer_selection.go Dismissed Show dismissed Hide dismissed
@chaitanyaprem chaitanyaprem marked this pull request as ready for review January 12, 2024 11:40
@chaitanyaprem chaitanyaprem linked an issue Jan 12, 2024 that may be closed by this pull request
waku/v2/protocol/legacy_filter/waku_filter.go Show resolved Hide resolved
waku/v2/protocol/filter/client.go Outdated Show resolved Hide resolved
waku/v2/protocol/filter/client.go Outdated Show resolved Hide resolved
waku/v2/protocol/filter/client.go Outdated Show resolved Hide resolved
waku/v2/peermanager/service_slot.go Outdated Show resolved Hide resolved
waku/v2/peermanager/peer_selection.go Outdated Show resolved Hide resolved
waku/v2/peermanager/peer_selection.go Outdated Show resolved Hide resolved
waku/v2/protocol/lightpush/waku_lightpush.go Show resolved Hide resolved
waku/v2/protocol/legacy_filter/waku_filter.go Show resolved Hide resolved
@chaitanyaprem chaitanyaprem merged commit 3be0edb into master Jan 26, 2024
11 of 12 checks passed
@chaitanyaprem chaitanyaprem deleted the feat/filter-subscribe-options branch January 26, 2024 08:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

feat: unique peer selection for same content filters
4 participants