SignalR icon indicating copy to clipboard operation
SignalR copied to clipboard

Many "Failed connection handshake" errors per second

Open rfrancisco opened this issue 8 years ago • 7 comments

We have multiple servers with an average of 30-40K connections each. We connect the clients using the Typescript signalR client. One thing that we notice in our logs is that we have many "Failed connection handshake" erros being logged. Is this normal? If so should this be being logged as an error?

We started using signalR in RC1, and we saw this behaviour, now we updated to the final version and the behaviour is still the same.

rfrancisco avatar Jun 05 '18 14:06 rfrancisco

Could you fill out the Diagnostics Guide

BrennanConroy avatar Jun 05 '18 15:06 BrennanConroy

Closing this as we haven't heard from you. Please feel free to comment if you're able to get the information we're looking for and we can reopen the issue if we're able to identify the problem.

analogrelay avatar Jun 18 '18 15:06 analogrelay

Hello, I have a similar problem. I've created my API with ASP CORE 2.1 and SignalR on Windows machine. Now I published the API to the server with Linux and in the chrome console I see only errors like this:

image

My server reports: image

Maciejszuchta avatar Jul 20 '18 13:07 Maciejszuchta

Can you file a new issue please? Please include details such as the exact server configuration you are using (for example, are you using a proxy like nginx or Apache?) and follow the Diagnostics Guide to provide server and client-side logs in text format (screenshots are very difficult to work with)

analogrelay avatar Jul 20 '18 16:07 analogrelay

I had this problem with SignalR behind an nginx proxy. proxy_set_header Connection "Upgrade"; resulted in a lot of failed handshakes per hour. proxy_set_header Connection ""; resulted in relatively few failed handshakes per hour. proxy_set_header Connection $http_connection; fixed it entirely (over an hour).

krvi avatar Jul 28 '18 17:07 krvi

It looks like setting proxy_set_header Connection $http_connection; or proxy_set_header Connection "Upgrade";

fixes the issue.

Maciejszuchta avatar Jul 30 '18 06:07 Maciejszuchta

I had to specify both of the following on my nginx proxy location for the signalr endpoint:

proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection $http_connection;

kspearrin avatar Aug 21 '18 16:08 kspearrin