OWIN defines a standard interface between .NET web servers and web applications. The goal of the OWIN interface is to decouple server and application.
Lack of ASP .NetIt had lacked some basic qualities like portability, modularity and scalability
What problems does it solve?
What is Katana?
A Stream with the request body
A string containing the HTTP method of the request (GET, POST etc. )
A string which contains the request path
A stringthe portion of the request path corresponding to the "root" of the application delegate
A stringthe protocol name and version (HTTP/1.0, HTTP/1.1 etc.)
- The environment dictionary is created by the Host and passed to the server.Host also populates this ,prior to passing this to the server,to inform the server about itself.
- Server populates this dictionary to announce its capabilities to other OWIN components, like our application and the server.
- Host passes the dictionary to our application's setup code.
- Our application creates the request pipeline and returns the generic Func delegate.
- Host now starts the server by launching the server startup code with the dictionary and the delegate.
After the above steps have completed the server is ready accept the requests using the delegate passed to it by our application.
As we saw host is responsible for creating the server ,as well as communicating with our application to create the request pipeline.