SignalR: The server disconnected before sending a handshake response
See original GitHub issueIssue moved from dotnet/aspnetcore#26032
- Please respond to @mhardy.
From @mhardy on Thursday, September 17, 2020 8:37:33 PM
I have a Blazor Server app that has been working perfect with a small group of 10 users. I’m hosting it on a B1 App Service Plan and using an Azure SignalR Standard Service with 1 Unit. I just rolled it out 200 people, and it only took a few dozen to cause hundreds of exceptions. Memory never exceeds 60%, SignalR service has 120 max client connections, 16 max server connections.
I have SignalR debug logging enabled. Digging through the exceptions I’m seeing hundreds of these:
The server disconnected before sending a handshake response
A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond.
I can’t reproduce the issue locally because it only occurs under load.
.NET Core 3.1 “Microsoft.AspNetCore.SignalR.Client” Version=“3.1.8” “Microsoft.Azure.SignalR” Version=“1.5.1”
Issue Analytics
- State:
- Created 3 years ago
- Comments:14 (4 by maintainers)
I’ve already done significant artillery testing. That’s been helpful but as noted doesn’t take into consideration SignalR. I’ll take a closer look into crank.
By pulling out the custom hub as described above my application has stabilized. It’s now been rolled back out to the wider audience and there have been no exceptions or CPU spikes for two weeks. Thanks for all the feedback.
Thanks for the update, I am closing the issue as the original issue is addressed. Feel free to open another issue if you have further questions for example performance test.