feat: implement connection state recovery #338
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
In socket.io version 4.6.0 a feature called connection state recovery has been added. This feature is described as follows:
This PR adds support for connection state recovery to socket.io-client-dart. The implementation has been ported from socketio/socket.io-client@b4e20c5.
Even though the README says Port of awesome JavaScript Node.js library - Socket.io-client v2.0.1~v3.0.3 - in Dart, we did not need to port any other changes from versions between 3.0.3 and 4.6.0. We have validated the code in this PR by connecting to a server running socket.io version 4.6.1.