Skip to content

socket.io-client-cpp does not connect to node app on Heroku #221

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

Closed
akontsevich opened this issue Dec 11, 2018 · 4 comments
Closed

socket.io-client-cpp does not connect to node app on Heroku #221

akontsevich opened this issue Dec 11, 2018 · 4 comments

Comments

@akontsevich
Copy link

akontsevich commented Dec 11, 2018

socket.io-client.cpp does not connect to node app on Heroku while Node JS socket.io-client does without any problem. Error is:

[2018-12-11 19:32:43] [connect] Successful connection
[2018-12-11 19:32:43] [error] handle_read_http_response error: websocketpp.transport:7 (End of File)
[2018-12-11 19:32:43] [info] Error getting remote endpoint: system:107 

How to fix? Any workaround?

@akontsevich
Copy link
Author

Changed URL from https to http://myapp.heroku.com - works now. Is it possible to connect via https as well. JS socket.io-client allows this.
https://stackoverflow.com/q/53736781/630169

@akontsevich
Copy link
Author

akontsevich commented Dec 12, 2018

Built app with SIO_TLS in DEFINES (-DSIO_TLS) - connects via https fine now!

Solution found here: #137

@pampas93
Copy link

pampas93 commented Mar 31, 2019

@akontsevich I'm still trying to connect to a simple node js server hosted locally (which is using http) build using express, and implemented a simple socket.io on it. But I'm still stuck in connecting, and getting the following error.

[2019-03-30 19:37:34] [connect] Successful connection
[2019-03-30 19:37:40] [error] Server handshake response error: websocketpp.processor:20 (Invalid HTTP status.)
Connection failed.

I'm trying to run the console example app, and using VS 2017 and 141v toolset. I also pointed the submodules (rapidjson and websocketpp) to their head. Any other change I need to make?

@akontsevich
Copy link
Author

I'm trying to run the console example app, and using VS 2017 and 141v toolset. I also pointed the submodules (rapidjson and websocketpp) to their head. Any other change I need to make?

@pampas93 also get following error today trying to connect to local node.js server:

[connect] Successful connection
[2019-09-11 16:22:31] [error] handle_transport_init received error: TLS handshake failed
[2019-09-11 16:22:31] [info] asio async_shutdown error: asio.ssl:336462231 (shutdown while in init)

cause for production I've built with DEFINES += SIO_TLS in .pro file (-DSIO_TLS compiller switch). Commented this out for now for local unsecure run.

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

No branches or pull requests

2 participants