HttpApplication Communication Management

Source: Internet
Author: User

The HttpApplication class defines methods, properties, and events common to all application objects in an ASP. This class is the base class for the application that the user defines in the Global.asax file.

The application executes the events handled by the module or user code defined in the Global.asax file in the following order (for the 19 event delegates used for HttpModule registration):

1. BeginRequest (the first event in an HTTP execution pipeline chain occurs when ASP. NET responds to a request.) )

2, AuthenticateRequest (occurs when the security module has established a user ID)

3. Postauthenticaterequest (occurs when the currently requested user is authorized)

4. AuthorizeRequest (occurs when the security module has authenticated user authorization)

5. Postauthorizerequest (occurs when the currently requested user has been authorized)

6. Resolverequestcache ( occurs when an ASP. NET finishes authorization event so that the cache module serves the request from the cache, bypassing the execution of an event handler, such as a page or XML Web service). )

7, Postresolverequestcache ( occurs when ASP. NET skips the execution of the current event handler and allows the cache module to satisfy requests from the cache.) ).

8. Postmaprequesthandler ( occurs when ASP. NET has mapped the current request to the appropriate event handler.) )

9, AcquireRequestState ( occurs when ASP. NET gets the current state, such as session state) associated with the current request. )

10. Postacquirerequeststate ( occurs when the request state (such as session state) that is associated with the current request has been obtained. )

11 . PreRequestHandlerExecute occurs just before ASP. NET begins executing an event handler (for example, a page or an XML Web services). )

12. PostRequestHandlerExecute ( occurs when an ASP. NET event handler (for example, a page or an XML Web service) finishes executing. )

13. ReleaseRequestState ( occurs after all request event handlers have been executed by ASP. This event causes the state module to save the current state data. )

14. Postreleaserequeststate ( occurs when ASP. NET has completed execution of all request event handlers and the request state data has been stored.) )

15, Updaterequestcache ( occurs when ASP. NET executes the event handler so that the cache module stores the response that will be used to service the subsequent request from the cache.) )

16, Postupdaterequestcache ( This event occurs after ASP. NET completes the update of the cache module and stores the response to service the subsequent requests from the cache.) )

17, Logrequest ( occurs exactly before ASP. NET executes any record for the current request. )

18. Postlogrequest ( occurs after ASP. NET finishes processing all event handlers for the Logrequest event. )

19. EndRequest (The last event in an HTTP execution pipeline chain when ASP. NET responds to a request.) )

Reference:

Https://msdn.microsoft.com/zh-cn/library/system.web.httpapplication%28v=vs.110%29.aspx


This article is from the "Born for the Dragon" blog, please be sure to keep this source http://v587bj4.blog.51cto.com/9579337/1701358

HttpApplication Communication Management

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.