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

WakuV2 filter debugging and refactor #4042

Closed
vitvly opened this issue Sep 18, 2023 · 15 comments
Closed

WakuV2 filter debugging and refactor #4042

vitvly opened this issue Sep 18, 2023 · 15 comments
Assignees

Comments

@vitvly
Copy link
Contributor

vitvly commented Sep 18, 2023

Some of the message deliverability issues listed here (status-im/status-mobile#16873) are related to filter operation.

Investigations have been previously carried out in this issue: status-im/status-mobile#17091 (comment). Seems that in that particular case peer connection between filter server and filter client was dropped and not resurrected for some reason.

This issue exists for the purpose of tracking ongoing investigations.

@vitvly vitvly self-assigned this Sep 18, 2023
@vitvly
Copy link
Contributor Author

vitvly commented Sep 18, 2023

Related PR: #4020

Extra debug output has been added.

Code analysis has uncovered potential problems that are being addressed in that PR:

  • access to filter-to-subscription data map was not properly synchronised
  • not-so-nice timed loop in Subscribe() that might result in many repeated subscribe calls
  • there existed a possibility of multiple subscribes with similar ContentTopics to the same peer. PR to address these issues here: feat: topic refactors for filter client waku-org/go-waku#750.

@vitvly
Copy link
Contributor Author

vitvly commented Sep 19, 2023

Update: fixed WakuV2Filter test issues in #4020, added some extra logs.
There is new build tag added with recent go-waku changes - gowaku_no_rln, need to fix status-go build.

@vitvly
Copy link
Contributor Author

vitvly commented Sep 19, 2023

status-go PR build fixed
waku-org/go-waku#750 merged

@vitvly
Copy link
Contributor Author

vitvly commented Sep 20, 2023

Changes in status-go PR #4020 - replace weird callbacks with channels passing Filter objects, thus all Subscribes occur from within the same goroutine.

@vitvly
Copy link
Contributor Author

vitvly commented Sep 20, 2023

Created a status-mobile PR to run some client-side tests on: status-im/status-mobile#17344

Fixing status-go mobile build issues that surfaced there.

@vitvly
Copy link
Contributor Author

vitvly commented Sep 20, 2023

After meeting with @richard-ramos and @cammellos it was decided to

  • allow multiple subscriptions to the same [peer, contentFilter]
  • fix filter.client.UnsubscribeWithSubscription so that it allows fine-grained unsubscribes for a particular subscription

@vitvly
Copy link
Contributor Author

vitvly commented Sep 21, 2023

Added a go-waku PR implementing changes discussed on yesterday's meeting: waku-org/go-waku#762

@vitvly
Copy link
Contributor Author

vitvly commented Sep 22, 2023

Tiny PR: waku-org/go-waku#766, rebased waku-org/go-waku#762. Need to fix some race condition in TestWakuFilter.

Relevant changes for multiple subs and sub-specific unsubscribe have been added to https://github.com/status-im/status-go/pulls/4020.

@vitvly
Copy link
Contributor Author

vitvly commented Sep 22, 2023

Fixed race condition in tests in waku-org/go-waku#762, merged. Updated status-go PR https://github.com/status-im/status-go/pulls/4020 to point to updated go-waku.

@vitvly
Copy link
Contributor Author

vitvly commented Sep 25, 2023

Testing mobile PR status-im/status-mobile#17344, fixing issues discovered there.

@vitvly
Copy link
Contributor Author

vitvly commented Sep 26, 2023

Progress update: status-im/status-mobile#16873 (comment)

@vitvly
Copy link
Contributor Author

vitvly commented Sep 29, 2023

Refactored health checks again, now these a single event loop.

@vitvly
Copy link
Contributor Author

vitvly commented Oct 4, 2023

Merged in #4082 and status-im/status-mobile#17472.

There are still issues with community sending, as there is no retry. To be investigated.

@vitvly
Copy link
Contributor Author

vitvly commented Oct 17, 2023

Recent updates:

@vitvly
Copy link
Contributor Author

vitvly commented Nov 3, 2023

I think it's safe to close for now, will be replaced by more specific issues later on.

@vitvly vitvly closed this as completed Nov 3, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant