-
Notifications
You must be signed in to change notification settings - Fork 23
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[1/2] stream_all_messages: bindings and streaming messages from an un…
…changing group list (#526) Putting this up early, so that work on propagating this to SDK's can begin in parallel. This implements `stream_all_messages()`, but it doesn't pick up messages from any groups that get created after the method was called. Some of the setup for picking up messages from *new* groups is in this PR, but that functionality won't be complete until the next PR (along with some cleanup). At that point, only the libxmtp binary will need to be updated - the binding interface won't be any different from the one in this PR. Other changes: 1. Make a file called `subscriptions.rs` and move `process_streamed_welcome` and `stream_conversations` to it - `client.rs` was becoming a monster file. 2. Move the logic for streaming conversations with a callback from the `stream()` method in the bindings into a `stream_conversations_with_callback` method in xmtp_mls. The logic for running an infinite listener loop in a background thread, as well as closing the stream, will also be needed for the groups stream in `stream_all_messages`.
- Loading branch information
1 parent
bfdda64
commit e460692
Showing
6 changed files
with
372 additions
and
75 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.