Last post Sep 05, 2014 03:51 AM by Kevin Shen - MSFT
Sep 04, 2014 03:42 AM|yaapelsinko|LINK
I'm running into an error with a SignalR service.
Initially it was self-hosted SignalR service (windows service), then I've changed hosting to web-app (so uninstalled Host.HttpListener and installed Host.SystemWeb). It seems to be able to initialize, start and work - until I try to connect.
Application uses a class derived from PersistentConnection. So app.MapSignalR<MyConnection>("/path") call is used. When I'm trying to connect to it with .NET SignalR client, I receive status code 500 in response. When I use just app.MapSignalR("/path"),
I can connect, but, I assume, not to MyConnection at all. So probably there is some error happens inside MyConnection class. I can't figure out - how to catch errors that are server-side (server started locally from VS in debug mode)? Breakpoints are all over
the place already...
Also, this MyConnection class works fine inside win-service with self-hosted SignalR, it hasn't been changed at all, but refuses to work properly inside web-app. I've read some tutorials, but all of them are very simple - you just inherit PersistentConnection
in your class, do app.MapSignalR<T>(path) and it works. Probably there must be something simple, like absent assembly (maybe I forgot to connect something), etc...
Sep 05, 2014 03:51 AM|Kevin Shen - MSFT|LINK
500 error is a very generic error that could have a wide variety of causes.
The details of the error should appear in the server's event log, or can be found through debugging the server.
You can refer to the link for cause which can lead to your issue:
please check the link below regarding to handle errors:
Here is example about how to use PersistentConnection class: