Engine.io: Polling transport fires 'close' packet when closed

Skip to first unread message


Jul 25, 2013, 5:10:46 PM7/25/13
to sock...@googlegroups.com
Perhaps this post belongs in the engine.io-client issue list, rather than here:
Is it really a good feature to send a "close" packet when we already have heartbeats?
Seems to me like it complicates things unnecessarily, examples:
1. In a mobile app, if you're told to pause you really should finish up quickly. Starting a new network I/O operation is not a good idea, asking for the OS to crash your app.
2. In the case where we're trying to close due to network issues, starting another request that may hang or take ages to return is a bad idea.
3. Prevents a clean slate when closing, e.g. see https://github.com/LearnBoost/engine.io-client/issues/175.

Just seems to me that polling close() should try pollXhr.abort() and sendXhr.abort() rather than starting a new request.

Reply all
Reply to author
0 new messages