Skip to content

TRANSPORT_HANDSHAKE_ERROR #5325

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

Open
sridhard opened this issue Apr 6, 2025 · 0 comments
Open

TRANSPORT_HANDSHAKE_ERROR #5325

sridhard opened this issue Apr 6, 2025 · 0 comments
Labels
to triage Waiting to be triaged by a member of the team

Comments

@sridhard
Copy link

sridhard commented Apr 6, 2025

Describe the bug
I am using socketio with eiows and fastify
We are running socketio on AWS EC2 instance behing loadbalancer.
Few of the users(Approx 1%) are not able to connect to socketio server and getting TRANSPORT_HANDSHAKE_ERROR.

I have printed the logs like below:

    fastify.io.engine.on("connection_error", (err) => {
      console.error("Socket connection error: code: " + err.code); // the error code, for example 1
      console.error("Socket connection error: message: " + err.message); // the error message, for example "Session ID unknown"
      console.error("Socket connection error: context: " + JSON.stringify(err.context)); // some additional error context
    });

Below are the logs:

Socket connection error: code: 3
Socket connection error: message: Bad request
Socket connection error: context: {"name":"TRANSPORT_HANDSHAKE_ERROR"}

To Reproduce
I am not sure about the reproduction condition. It is happening for few users and we dont have the user details to connect to them,

Socket.IO server version: 4.8.1

Expected behavior
Socket connection should be success

@sridhard sridhard added the to triage Waiting to be triaged by a member of the team label Apr 6, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
to triage Waiting to be triaged by a member of the team
Projects
None yet
Development

No branches or pull requests

1 participant