Last post Aug 04, 2017 06:42 AM by gtscdsi
Jul 13, 2017 03:58 PM|Andy Dalton|LINK
We recently experienced a connection issue (a few times) using the .NET Client that would be good to see if anyone else has encountered and worked around.
We have a console app (C# 4.6.1) on an Azure VM that uses SignalR .NET Client (Version 2.2.2) to connect to our web app (C# MVC5). We maintain a single connection and handle the Closed event of the hub connection to attempt to call start again after a short
On a couple of occasions the web app has become unresponsive for a short while and this causes a disconnect, i.e. the closed event is raised and after a few seconds we attempt to reconnect. On reconnect it seems to get stuck when calling start. Even though
the web app becomes responsive it requires a restart of the console app before it will connect successfully.
Looking through the code I can see the following change was made to the DefaultHttpClient that sets both the long and short running HTTPClients to have infinite timeouts.
As both the start and negotiate calls use the short running HTTPClient it seems strange that it would be set to never timeout. It has been raised an issue (https://github.com/SignalR/SignalR/issues/3566)
but has no feedback. I can implement our own DefaultHttpClient with the normal timeout on the short running client but I assume that the infinite timeout was added for good reason.
Does anyone have any suggestions?
Aug 02, 2017 05:35 AM|Billy Liu|LINK
Hi Andy Dalton,
Our engineers are already working on your problem.
The solution will be posted to you as soon as they work it out.
Aug 04, 2017 06:42 AM|gtscdsi|LINK
Thanks for your post.
Could you please help to collect the network trace by using Network monitor for further investigation?
Network monitor: https://www.microsoft.com/en-us/download/details.aspx?id=4865
Please help to collect for working scenario and non-working scenario.
Please upload to workspace:
If you have any question, feel free let me know.