I suggest you ...

Enable ASP.NET MVC to be self hosted in any .NET application (like WCF, Nancy etc.)

762 votes
Vote
Sign in
Check!
(thinking…)
Reset
or sign in with
  • facebook
  • google
    Password icon
    I agree to the terms of service
    Signed in as (Sign out)
    You have left! (?) (thinking…)
    Ashic MahtabAshic Mahtab shared this idea  ·   ·  Flag idea as inappropriate…  ·  Admin →

    11 comments

    Sign in
    Check!
    (thinking…)
    Reset
    or sign in with
    • facebook
    • google
      Password icon
      I agree to the terms of service
      Signed in as (Sign out)
      Submitting...
      • Ryan RileyRyan Riley commented  ·   ·  Flag as inappropriate

        This should be simple to do using IHttpActionRsult and something like the WebApiContrib.Formatting.Razor project.

      • Victor WooVictor Woo commented  ·   ·  Flag as inappropriate

        Is it possible to write a simple custom Console Application that includes a owin library that can host a Asp.Net Web Application directly (without katana.exe, like CassiniDev's library)?
        Is it possible to let an Asp.Net Web Application including MVC 4, Web API, SignalR features hosted across IIS and owin, without / rarely changing code?

      • Miguel JimenezMiguel Jimenez commented  ·   ·  Flag as inappropriate

        Must be OWIN complaint and maybe expose a self hosting class like Nancy, to embed in windows services and windows forms apps.

      • Damian HickeyDamian Hickey commented  ·   ·  Flag as inappropriate

        @Mark If it's OWIN based, as has been indicated, you'll at least get an entry point that can looks something like this:

        Task ProcessRequest(IDictionary<string, object> environment)

        Though there will probably be a friendlier API in conjunction with this.

      • Mark SeemannMark Seemann commented  ·   ·  Flag as inappropriate

        Very importantly, it should be possible to communicate with the self-host server without going through the network stack.

        As a comparison, the ASP.NET Web API self-host server supports this scenario, which is very important for in-proc acceptance testing, because it enables you to run the automated acceptance test without elevated privileges.

      • Howard DierkingAdminHoward Dierking (ASP.NET, ASP.NET Future Feature Feedback) commented  ·   ·  Flag as inappropriate

        This is one of the scenarios that we're looking at under the umbrella of http://katanaproject.codeplex.com/ - right now, our focus is on making OWIN first class across the different hosting options and on making those scenarios blazingly fast. We'll then shift focus to the framework side of the equation. So this is definitely on our radar.

      • llewellyn falcollewellyn falco commented  ·   ·  Flag as inappropriate

        REALLY LIKE THIS, but think it comes down to allowing the template engine to run under normal context. That in particular I would vote +1,000 for.

      • lfoustlfoust commented  ·   ·  Flag as inappropriate

        It would be great to be able to write Win8 javascript based applications using MVC!

      Feedback and Knowledge Base