Skip to content

feat(gql_socket_link): BREAKING CHANGE multiplex websocket connection #491

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

Open
wants to merge 5 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions links/gql_websocket_link/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
## 3.0.0

- BREAKING: graphql-transport-ws: streaming operations and single result operations are now multiplexed on a single connection, user has to manually resubscribe subscription when connection is broken

## 2.0.1

- support uuid 4.0.0
Expand Down
2 changes: 2 additions & 0 deletions links/gql_websocket_link/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,9 @@ The `WebSocketLink` class has some known issues, see:
- https://github.com/gql-dart/gql/issues/430


#### TransportWebSocketLink (`graphql-transport-ws`)

- Streaming operations and single result operations are now multiplexed on a single connection. This means you have to manually resubscribe on subscriptions. On IOS and Android, when you app is in background (lock screen, etc.), all open sockets will be closed to save battery, and your app is freezed, no code from your app will run. Thus there is no way to reconnect a websocket connection when it is broken because no code from your app will run, you have to manually resubscribe on app resume (use `WidgetsBindingObserver` or related packages). You can use old TransportWebSocketLink client to resubscribe, the underlying socket is newly acquired when you resubscribe.


## Features and bugs
Expand Down
Loading