Commit Graph

4 Commits

Author SHA1 Message Date
Tim Yung d0a26a75fb RN: Fix Exponential WebSocket Growth from DevTools
Summary:025281230de2e316f2770a2db71f8bec6fe43a07 changed `WebSocket` to fire both `onerror` and `onclose`.

However, `setupDevtools` assumed that only one of the two handlers would ever be invoked. When the handler is invoked, it re-invokes itself to keep a socket open. But since both handelrs are invoked, a series of closed or failed sockets can cause an exponential increase in sockets opened.

Symptoms of this bug include eventually reaching the maximum number of file descriptors allowed by the operating system, or a non-responsive system. Within React Native applications, symptoms include a failure to load resources from the React Native server or application crashes.

Reviewed By: frantic

Differential Revision: D3022697

fb-gh-sync-id: 8131ecbd6d8ba30281253340d30370ff511a5efd
shipit-source-id: 8131ecbd6d8ba30281253340d30370ff511a5efd
2016-03-07 19:20:25 -08:00
Alex Kotliarskyi 9a93a3cba4 Use pre-bundled elements inspector
Reviewed By: spicyj

Differential Revision: D2588448

fb-gh-sync-id: 278631c1de78cac2bfd9950809feddbe3f630ad0
2015-10-29 11:21:32 -07:00
Gabe Levi 874f39bf7f [Flow] Clean up react-native for Flow v0.15.0 2015-09-04 16:51:18 -08:00
Jared Forsyth 9e4af68d91 [react-native] enable react devtools from JavascriptCore 2015-07-23 17:14:09 -08:00