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

HTTP2 + WebSockets #3330

Closed
lenovouser opened this issue Jul 17, 2015 · 4 comments
Closed

HTTP2 + WebSockets #3330

lenovouser opened this issue Jul 17, 2015 · 4 comments
Labels

Comments

@lenovouser
Copy link

Hello,

I am trying to use a HTTP2 web server for proxying NodeBB. Right now there is no implementation of the WebSocket standard in HTTP2. Would it be possible to make socket.io somehow only do HTTP/1 or HTTP/1.1 requests to the WebServer? Theoretically it should work then.

The issue on the web server project's bug tracker is caddyserver/caddy#189

Cheers,

ApfelUser

@julianlam
Copy link
Member

Hey there @Apfeluser, you may want to consider playing around with the socket.io hash in config.json.

@lenovouser
Copy link
Author

I don't understand how you could make NodeBB use < HTTP/1.1 for WebSockets using the config.json? Is there something I am maybe misunderstanding?

@julianlam
Copy link
Member

Ah, I misread. You'll need to use a regular HTTP/1.1 server (nginx?) to proxy websocket requests to NodeBB... I do not have much experience with this, so I'm afraid I cannot help much.

@lenovouser
Copy link
Author

Well. What I am trying to do is actually using HTTP/2. So that is not an option 😄 I want to get HTTP/2 and WebSockets working. So thats why I was asking if you know of an option to force a HTTP version in socket.io or actually general javascript. I searched on Google and Stackoverflow etc. - it seems like there is no real option to force a HTTP version in javascript. Maybe there is one, but in that case it is not very well documented. I'll probably open another issue on socket.io but I guess they can't answer it either.

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

No branches or pull requests

3 participants