Skip to content

Websockets not supported through Socket.io #47

Closed
tsenart opened this Issue Feb 16, 2011 · 8 comments

6 participants

@tsenart
tsenart commented Feb 16, 2011

They get dropped to xhr-polling even if I have websockets enabled.
Logs: https://gist.github.com/41818db314c949435693

@koto
koto commented Feb 18, 2011

I encountered very similar issue on socket.io based app.

On the client, when I force the socket.io transport to be 'websocket' - the browser never receives any updated from the sent websockets handshake (server is a black hole)

However, when I change it to xhr-multipart, all works correctly.

@koto
koto commented Feb 18, 2011

I think it's because nodester uses lib/3rdparty/node-http-proxy.js file to forward requests from port 80 to appropriate app. WebSockets requests are not HTTP requests (although they look very similar) , so they are either stripped (and become invalid in the target app) or not handled at all by the proxy.

I don't have the infrastructure to test this, but it looks as there needs to be some special handling for WebSockets traffic to be forwarded correctly.

@davglass
davglass commented Mar 4, 2011

This should be working now, can you test it now to make sure?

@nodester
Owner
nodester commented Mar 4, 2011
@koto
koto commented Mar 4, 2011

I confirm, everything works perfectly! Thanks!

@mkilling

It seems the problem has reappeared. socket.io falls back to XHR polling. Possibly related: The chat example at http://chat.nodester.com is stuck at 'connecting'.

@moduleitor

... http://chat.nodester.com it's not working!!!

@nodester
Owner
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.