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

Support using just the websocket transport #142

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

taion
Copy link

@taion taion commented Dec 19, 2016

This works when using the JS client. That client starts off using just the first transport: https://github.com/socketio/engine.io-client/blob/1.8.2/lib/socket.js#L227. There's a few extra LoC to properly set the timeout on the WebSocket transport, but I believe otherwise things work like this.

@taion
Copy link
Author

taion commented Dec 19, 2016

The motivation here is that we have some Socket.IO servers where we're not using any of the fallback methods, but where (for the moment) the abstraction offered by Socket.IO is valuable enough to justify paying the overhead of Engine.IO, even though we're not getting anything out of it.

We don't want to have to deal with sticky LB sessions, so we only enable the websocket transport.

@taion
Copy link
Author

taion commented Dec 22, 2016

How does this look?

@taion
Copy link
Author

taion commented Jan 18, 2017

Following up here. Is there anything I'm missing for this PR?

@taion
Copy link
Author

taion commented Jan 23, 2017

@invisibleroads Ping!

@invisibleroads
Copy link
Owner

@taion
If I understand correctly, your pull request lets a client connect directly using the websocket transport, bypassing the initial xhr polling. Is that right?

@taion
Copy link
Author

taion commented Jan 23, 2017

That's the idea. This brings things a bit closer to the logic on the Engine.IO JS client side, which doesn't special-case any of the transports on initial connect (it always tries the first listed transport, then negotiates available upgrades with the server).

@taion
Copy link
Author

taion commented Feb 2, 2017

Any updates here?

@taion
Copy link
Author

taion commented Apr 6, 2017

Ping.

@taion
Copy link
Author

taion commented Apr 17, 2017

Any update here? This has been sitting around for a while now. This is a use case that is present in the JS client, and is essentially required when not using sticky sessions on the backend.

@taion
Copy link
Author

taion commented Jun 6, 2017

What's blocking this PR?

@taion
Copy link
Author

taion commented Jul 15, 2017

Any updates?

@taion
Copy link
Author

taion commented Jul 25, 2017

Ping.

@chirag04
Copy link

chirag04 commented Nov 1, 2017

@invisibleroads any updates on this?

@taion
Copy link
Author

taion commented Nov 15, 2017

Ping!

@akimul
Copy link

akimul commented Jun 11, 2020

@invisibleroads Any update on this PR?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants