Closed NightAngell closed 6 years ago
We changed how some of this worked in 2.2 which will most likely resolve the issues you're seeing. Can you try out the nightly bits on the client and server?
I use WebSockets instead of LongPooling (on Windows 10 instead of 7 [WebSockets transport not available on win7 IIS Express]) and it work (Chrome: F12->Network->Offline dont work, but this is probably bug related to chrome tools and localhost (client and server are on localhost)*, I test it better when I deploy project to external hosting in the future [For now i write project for studies and I don
t plan deploy]). I just want notify about problem, but I see this problem is known and probably resolved, then I think this issue can be closed.
*Because when is set Client as offline using chrome tools, client still can send and receive messages from server
Server NuGets: Microsoft.AspNetCore.App (2.1.1) include Microsoft.AspNetCore.SignalR (1.0.1) Client NPM Packages: "@aspnet/signalr": "^1.0.4" Client: TypeScript (Angular7) Server: IIS Express Operating System (Client and Server): Windows 7 Browser: Chrome
Problem: Hub method OnDisconnectedAsync(Exception exception) not fired when:
Expected behaviour: OnDisconnectedAsync(Exception exception) fired Actual behaviour: OnDisconnectedAsync(Exception exception) not fired
Steps to reproduction: Backend
Startup.cs
addservices.AddSignalR();
andYourHub : Hub
Task OnDisconnectedAsync(Exception exception)
OnDisconnectedAsync
(For Debugging purpose)Frontend
.then(()=>{ console.log("Connected!") });
Logs: Chrome.log ChromeNetwork.har.log ASPNETCOREBUG.log