- Whenever event occurs on the web page, the request is sent to the web browser; in our case, let the web server be IIS.
- The IIS picks up this request and looks for the server extensions. Each server extension is actually mapped to the IIS. Now, if the server extension of this request is .aspx, it maps to aspnet_isapi.dll. After this .dll is invoked, it hosts the ASP.NET worker process that initializes the Http Pipeline.
- If the HttpApplication object does not exist for the application, it creates one—or else it picks it from the pool of these HttpApplication objects and passes the incoming request to it to handle.
- The worker process calls the HttpRuntime.ProcessRequest() method.
- The HttpRuntime creates the HttpContext and calls the HttpApplicationFactory.
- The HttpApplicationFactory creates an instance of the web page object from a dynamically created assembly and selects the appropriate HttpApplication object that can serve the incoming request.
- The HttpApplication instance processes the request and, in turn, selects the appropriate PageHandlerFactory.
- The PageHandlerFactory now creates the page instance by making use of the page handler of the web page. It does this to return the page instance to the HttpRuntime through the HttpApplicationFactory.
- The HttpRuntime uses this page instance and calls the ProcessRequest() method of the web page.
- The ProcessRequest() method first calls the FrameworkInitialize() method and then calls the page life cycle methods.
Application Life Cycle Events in ASP.NET architecture
Application Life Cycle Events
Hot on Web: