-
Notifications
You must be signed in to change notification settings - Fork 930
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
transports/websocket: Handle websocket CLOSE with reason code (#2319)
Pass websocket CLOSE reason to the app as an `Incoming::Closed(soketto::CloseReason)`. This PR is a companion to paritytech/soketto#31 and lets applications know what the remote end claimed to be the reason for closing the connection (if any). `IncomingData` is now renamed to `Incoming` and the actual data (text or binary) is moved into its own `Data` enum, which in turn allows `into_bytes()` and the `AsRef` impl to apply more sanely to something that is actually data. Co-authored-by: David Palm <dvdplm@gmail.com>
- Loading branch information
Showing
6 changed files
with
69 additions
and
39 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
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