Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Unable to register routes in SignalR 2.0.0

I decided to move to the latest version of signalr but i facing a few issues. First of all the way to register routes has entirely changed; so i tried to do it the way that this link http://www.asp.net/vnext/overview/latest/release-notes#TOC13 suggests.

The problem is that although i add

<appSettings>
    <add key="owin:AppStartup" value="xxx.Startup, App_Code"/>
</appSettings>

to the web.config the Configuration is not invoked at all. Does anyone know what i'm doing wrong?

like image 362
ppoliani Avatar asked Jul 12 '13 10:07

ppoliani


2 Answers

I was able to get the 2.0 beta working by

  • Removing all references to the older version of SignalR, ie nuget uninstall of the library and double checking /bin

  • Installed SignalR 2.0.0-beta2 via Package Manager Console Install-Package Microsoft.AspNet.SignalR -Pre

  • Following the steps in the 1.x to 2.0 migration outlined in the ops link

  • And most importantly changing the project config to use Local IIS Web server instead of Visual Studio Developer Server (Cassini).

More info in the question/answer I posted here

like image 32
Jerry Avatar answered Oct 13 '22 01:10

Jerry


Solution !

<appSettings>
    <add key="owin:AppStartup" value="MyNameSpace.Startup, MyNameSpace" />
    <add key="owin:AutomaticAppStartup" value="true" />
</appSettings>

<system.web>
<httpHandlers>
  <add verb="*" path="*" type="Microsoft.Owin.Host.SystemWeb.OwinHttpHandler, Microsoft.Owin.Host.SystemWeb"/>
</httpHandlers>
</system.web>

<system.webServer>
<handlers>
  <add name="Owin" verb="*" path="*" type="Microsoft.Owin.Host.SystemWeb.OwinHttpHandler, Microsoft.Owin.Host.SystemWeb"/>
</handlers>
</system.webServer>
like image 176
Softlion Avatar answered Oct 13 '22 01:10

Softlion