HttpSelfHostServer and HttpContext.Current

后端 未结 2 722
一生所求
一生所求 2020-12-01 06:33

I\'m working on a self-hosted ASP.NET web api-application. Everything works fine, but now I\'m struggling with HttpContext:

I need to save session-infor

2条回答
  •  执笔经年
    2020-12-01 07:26

    To get around this problem (I find I am using a lot of components these days that need to work equally well in Web API and MVC), you can try this old shim I wrote to give you back an HttpContext-like interface that works in both flavours. It's on NuGet also, here's the source: Link on github (or Link on Nuget)

提交回复
热议问题