-
Notifications
You must be signed in to change notification settings - Fork 178
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(rpc module): close subscription task when a subscription is `unsu…
…bscribed` via the `unsubscribe call` (#743) * refactor: remove SubscriptionSink::inner_send * fix: close running task if unsubscribed * Update core/src/server/rpc_module.rs * Update core/src/server/rpc_module.rs * fix nits * Update core/src/server/rpc_module.rs * add test for canceling subscriptions * print subscription info; once per minute * revert closure stuff * Revert "print subscription info; once per minute" This reverts commit 366176a. * use tokio::sync::watch instead of oneshot The receiver is clonable and it's possible to check whether the sender is still alive * Update tests/tests/helpers.rs Co-authored-by: David <dvdplm@gmail.com> * Update core/src/server/rpc_module.rs Co-authored-by: David <dvdplm@gmail.com> * grumbles: use unwrap in tests * add test for reuse pipe_from_stream Co-authored-by: David <dvdplm@gmail.com>
- Loading branch information
Showing
3 changed files
with
164 additions
and
134 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
Oops, something went wrong.