Base solution for your next web application
Open Closed

How to enable websocket with ABP.SignalR? #3815


User avatar
0
trendline created

As SignalR provided that it will use below orders to specify a transport webSockets foreverFrame serverSentEvents longPolling

but when I using ABP.SingalR to do a server broadcast to client, it doesn't use websockets as the transport, even with a development environment IIS 10, or windows server 2012 with websocket protocol installed and latest version browsers in client. In the client, IE and Firefox are using longPooling as the transport, Chrome using Server Sent Events as the transport.

Is there some settings needs to be configured to force use websocket?


4 Answer(s)
  • User Avatar
    0
    strix20 created

    Are you using the MVC core version with full framework?

    If so, you cannot use web sockets. SignalR 2.0 is not fully compatible with Asp.Net Core. This has to do with the web sockets middleware. There are some various hacks that MIGHT get it to work for you, but they are messy.

    You can find more about the issue here:

    [https://github.com/aspnet/SignalR/issues/435])

  • User Avatar
    0
    trendline created

    Thanks for your information.

    Yes, I am running SingalR based on ABP.SingalR in .NET Core MVC on full .netframework 461.

    It seems apply the hack is a little complicated and cannot been maintained via nugget package.

    It is a little regretful that .net core mvc could not running SignalR full features.

  • User Avatar
    0
    strix20 created

    It's frustrating, for sure, but SignalR was pretty clear about it.

    The good news is that it looks like SignalR Core progress is moving along smoothly, so we should have Asp.Net Core 2.1 (and SignalR core) along with it by early next year.

  • User Avatar
    0
    ismcagdas created
    Support Team

    Thanks @strix20 for the detailed information, we are also waiting for SignalR to .net core.