Overview of an HTTP Request :
The following list describes the request-processing flow :
- When a client browser initiates an HTTP request for a resource on the Web server, HTTP.sys intercepts the request.
- HTTP.sys contacts WAS to obtain information from the configuration store.
- WAS requests configuration information from the configuration store, applicationHost.config.
- The WWW Service receives configuration information, such as application pool and site configuration.
- The WWW Service uses the configuration information to configure HTTP.sys.
- WAS starts a worker process for the application pool to which the request was made.
- The worker process processes the request and returns a response to HTTP.sys.
- The client receives a response.
Detail of a HTTP request inside the Worker Process
ASP.NET Request Flow:
- IIS gets the request
- Looks up a script map extension and maps to aspnet_isapi.dll
- Code hits the worker process (aspnet_wp.exe in IIS5 or w3wp.exe in IIS6)
- .NET runtime is loaded
- IsapiRuntime.ProcessRequest() called by non-managed code
- IsapiWorkerRequest created once per request
- HttpRuntime.ProcessRequest() called with Worker Request
- HttpContext Object created by passing Worker Request as input
- HttpApplication.GetApplicationInstance() called with Context to retrieve instance from pool
- HttpApplication.Init() called to start pipeline event sequence and hook up modules and handlers
- HttpApplicaton.ProcessRequest called to start processing
- Pipeline events fire
- Handlers are called and ProcessRequest method are fired
- Control returns to pipeline and post request events fire