Saturday, April 18, 2015

OWIN and Katana

Open Web Interface for .NET (OWIN) defines an abstraction between .NET web servers and web applications. By decoupling the web server from the application, OWIN makes it easier to create middleware for .NET web development. OWIN itself does not have any tools, libraries or anything else. It is just a specification.

Two design goals of OWIN are

  • New components could be more easily developed and consumed.
  • Applications could be more easily ported between hosts and potentially entire platforms/operating systems.

    Prior to OWIN, when you are building ASP.NET application, you are inheritably bound to IIS due to the heavy dependency on System.Web assembly.

    System.Web is something that exist ever since ASP (non .NET version) and internally contains many things that you might not even need (such as Web Forms or

    URL Authorization), which by the default run on every request, thus consuming the resources and making ASP.NET applications in general lot slower than it's counterparts at i.e. Node.js.

    Katana on the other hand, is fully developed framework made to make a bridge between current ASP.NET frameworks and OWIN specification developed by Microsoft still open source.These components include both infrastructure components, such as hosts and servers, as well as functional components, such as authentication components and bindings to frameworks such as SignalR and Asp.Net Web API.

    The project has the following three high level goals:

    • Portable – Components should be able to be easily substituted for new components as they become available. This includes all types of components, from the framework to the server and host. The implication of this goal is that third party frameworks can seamlessly run on Microsoft servers while Microsoft frameworks can potentially run on third party servers and hosts.
    • Modular/flexible – Unlike many frameworks which include a myriad of features that are turned on by default, Katana project components should be small and focused, giving control over to the application developer in determining which components to use in her application.
    • Lightweight/performant/scalable – By breaking the traditional notion of a framework into a set of small, focused components which are added explicitly by the application developer, a resulting Katana application can consume fewer computing resources, and as a result, handle more load, than with other types of servers and frameworks. As the requirements of the application demand more features from the underlying infrastructure, those can be added to the OWIN pipeline, but that should be an explicit decision on the part of the application developer. Additionally, the substitutability of lower level components means that as they become available, new high performance servers can seamlessly be introduced to improve the performance of OWIN applications without breaking those applications.
    Technorati Tags: ,

  • No comments:

    Post a Comment