Skip to content
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

Use SocketRocket for web socket library (#36347) #36471

Closed
wants to merge 1 commit into from

Conversation

javache
Copy link
Member

@javache javache commented Mar 14, 2023

Summary:
The previous native web socket API, RCTSRWebSocket, appears to be an older version of the one provided as part of SocketRocket. The latter has several improvements, such as the ability to respect proxy settings, which has been requested by a user of a React Native app.

Everything translates over pretty easily, and considering that SocketRocket is already a dependency of Flipper, there doesn't seem to be much additional cost to swapping out the libraries. If we wanted to make things even slimmer, it may even be possible to make the WebSocket library be optional for release builds.

Changelog

[IOS] [CHANGED] - Use SocketRocket for web socket library

Pull Request resolved: #36347

Test Plan:
Validated the following:

  • The WebSocket test page in RNTester
  • Live reloading

Differential Revision: D43768835

Pulled By: javache

Summary:
The previous native web socket API, `RCTSRWebSocket`, appears to be an older version of the one provided as part of [SocketRocket](https://github.com/facebookincubator/SocketRocket). The latter has several improvements, such as the ability to respect proxy settings, which has been requested by a user of a React Native app.

Everything translates over pretty easily, and considering that SocketRocket is already a dependency of Flipper, there doesn't seem to be much additional cost to swapping out the libraries. If we wanted to make things even slimmer, it may even be possible to make the WebSocket library be optional for release builds.

## Changelog

[IOS] [CHANGED] - Use SocketRocket for web socket library

Pull Request resolved: facebook#36347

Test Plan:
Validated the following:
* The WebSocket test page in RNTester
* Live reloading

Differential Revision: D43768835

Pulled By: javache

fbshipit-source-id: 4be7de1fce2183133462c0243b4b3309b02043f5
@facebook-github-bot facebook-github-bot added CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. p: Facebook Partner: Facebook Partner fb-exported labels Mar 14, 2023
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D43768835

@javache javache marked this pull request as draft March 14, 2023 10:50
@analysis-bot
Copy link

Platform Engine Arch Size (bytes) Diff
android hermes arm64-v8a 8,519,172 +0
android hermes armeabi-v7a 7,834,700 +0
android hermes x86 8,999,506 +0
android hermes x86_64 8,854,758 +0
android jsc arm64-v8a 9,142,474 +0
android jsc armeabi-v7a 8,333,842 +0
android jsc x86 9,197,229 +0
android jsc x86_64 9,455,335 +0

Base commit: 803bb16
Branch: main

@facebook-github-bot facebook-github-bot added the Merged This PR has been merged. label Mar 15, 2023
@facebook-github-bot
Copy link
Contributor

@javache merged this pull request in 9ee0e1c.

amgleitman pushed a commit to amgleitman/react-native-macos that referenced this pull request Mar 16, 2023
Summary:
Pull Request resolved: facebook#36471

The previous native web socket API, `RCTSRWebSocket`, appears to be an older version of the one provided as part of [SocketRocket](https://github.com/facebookincubator/SocketRocket). The latter has several improvements, such as the ability to respect proxy settings, which has been requested by a user of a React Native app.

Everything translates over pretty easily, and considering that SocketRocket is already a dependency of Flipper, there doesn't seem to be much additional cost to swapping out the libraries. If we wanted to make things even slimmer, it may even be possible to make the WebSocket library be optional for release builds.

[IOS] [CHANGED] - Use SocketRocket for web socket library

Pull Request resolved: facebook#36347

Test Plan:
Validated the following:
* The WebSocket test page in RNTester
* Live reloading

Reviewed By: cortinico

Differential Revision: D43768835

Pulled By: javache

fbshipit-source-id: 11e1ac2700bc92991897c594622e6687339bfcbf
microsoft-github-policy-service bot pushed a commit to microsoft/react-native-macos that referenced this pull request Mar 18, 2023
Summary:
Pull Request resolved: facebook#36471

The previous native web socket API, `RCTSRWebSocket`, appears to be an older version of the one provided as part of [SocketRocket](https://github.com/facebookincubator/SocketRocket). The latter has several improvements, such as the ability to respect proxy settings, which has been requested by a user of a React Native app.

Everything translates over pretty easily, and considering that SocketRocket is already a dependency of Flipper, there doesn't seem to be much additional cost to swapping out the libraries. If we wanted to make things even slimmer, it may even be possible to make the WebSocket library be optional for release builds.

[IOS] [CHANGED] - Use SocketRocket for web socket library

Pull Request resolved: facebook#36347

Test Plan:
Validated the following:
* The WebSocket test page in RNTester
* Live reloading

Reviewed By: cortinico

Differential Revision: D43768835

Pulled By: javache

fbshipit-source-id: 11e1ac2700bc92991897c594622e6687339bfcbf

Co-authored-by: Adam Gleitman <adgleitm@microsoft.com>
amgleitman pushed a commit to amgleitman/react-native-macos that referenced this pull request Mar 21, 2023
Summary:
Pull Request resolved: facebook#36471

The previous native web socket API, `RCTSRWebSocket`, appears to be an older version of the one provided as part of [SocketRocket](https://github.com/facebookincubator/SocketRocket). The latter has several improvements, such as the ability to respect proxy settings, which has been requested by a user of a React Native app.

Everything translates over pretty easily, and considering that SocketRocket is already a dependency of Flipper, there doesn't seem to be much additional cost to swapping out the libraries. If we wanted to make things even slimmer, it may even be possible to make the WebSocket library be optional for release builds.

[IOS] [CHANGED] - Use SocketRocket for web socket library

Pull Request resolved: facebook#36347

Test Plan:
Validated the following:
* The WebSocket test page in RNTester
* Live reloading

Reviewed By: cortinico

Differential Revision: D43768835

Pulled By: javache

fbshipit-source-id: 11e1ac2700bc92991897c594622e6687339bfcbf
microsoft-github-policy-service bot pushed a commit to microsoft/react-native-macos that referenced this pull request Mar 21, 2023
Summary:
Pull Request resolved: facebook#36471

The previous native web socket API, `RCTSRWebSocket`, appears to be an older version of the one provided as part of [SocketRocket](https://github.com/facebookincubator/SocketRocket). The latter has several improvements, such as the ability to respect proxy settings, which has been requested by a user of a React Native app.

Everything translates over pretty easily, and considering that SocketRocket is already a dependency of Flipper, there doesn't seem to be much additional cost to swapping out the libraries. If we wanted to make things even slimmer, it may even be possible to make the WebSocket library be optional for release builds.

[IOS] [CHANGED] - Use SocketRocket for web socket library

Pull Request resolved: facebook#36347

Test Plan:
Validated the following:
* The WebSocket test page in RNTester
* Live reloading

Reviewed By: cortinico

Differential Revision: D43768835

Pulled By: javache

fbshipit-source-id: 11e1ac2700bc92991897c594622e6687339bfcbf

Co-authored-by: Adam Gleitman <adgleitm@microsoft.com>
@javache javache deleted the export-D43768835 branch March 24, 2023 10:24
OlimpiaZurek pushed a commit to OlimpiaZurek/react-native that referenced this pull request May 22, 2023
Summary:
Pull Request resolved: facebook#36471

The previous native web socket API, `RCTSRWebSocket`, appears to be an older version of the one provided as part of [SocketRocket](https://github.com/facebookincubator/SocketRocket). The latter has several improvements, such as the ability to respect proxy settings, which has been requested by a user of a React Native app.

Everything translates over pretty easily, and considering that SocketRocket is already a dependency of Flipper, there doesn't seem to be much additional cost to swapping out the libraries. If we wanted to make things even slimmer, it may even be possible to make the WebSocket library be optional for release builds.

## Changelog

[IOS] [CHANGED] - Use SocketRocket for web socket library

Pull Request resolved: facebook#36347

Test Plan:
Validated the following:
* The WebSocket test page in RNTester
* Live reloading

Reviewed By: cortinico

Differential Revision: D43768835

Pulled By: javache

fbshipit-source-id: 11e1ac2700bc92991897c594622e6687339bfcbf
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. fb-exported Merged This PR has been merged. p: Facebook Partner: Facebook Partner
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants