Alexandr Sulimov
Alexandr Sulimov

Reputation: 1924

Asp .Net Core 2 + SignalR (1.0.0-alpha2-27025) + /signalr/negotiate 404 Error

I add SignalR to ASP .Net Core 2 app

packages

public IServiceProvider ConfigureServices(IServiceCollection services)
{
    services.AddSignalRCore();
    services.AddSignalR();
}

and

public void Configure(IApplicationBuilder app, IHostingEnvironment env, ILoggerFactory loggerFactory, IServiceProvider serviceProvider)
    app.UseSignalR(routes =>
    {
        routes.MapHub<ManageHub>("manageHub");
    });
}

url:port/signalr, url:port/signalr/negotiate... return 404

url:port/manageHub return 400 with "Connection ID required"

I not found .MapSignalR()

How use SignalR in ASP .Net Core?

Upvotes: 5

Views: 6504

Answers (2)

Ahmed Abuelnour
Ahmed Abuelnour

Reputation: 472

First of all, make sure you installed the last official version of SignalR for ASP.NET Core 2.0

Second follow that link How to get SignalR Working in ASP.NET Core 2

Upvotes: 3

Pawel
Pawel

Reputation: 31620

You seem to be using the old client. SignalR for ASP.NET Core does not use the /negotiate endpoint anymore. The new SignalR server is not compatible with old client and the new clients are not compatible with the old SignalR server. Take a look at the announcement and samples

Upvotes: 8

Related Questions