Events intercepted by ASP. NET and generated during request processing

Source: Internet
Author: User
The following table shows events that can be intercepted using ASP. NET during request processing. All events are listed in the order of occurrence.
The first list displays the events generated before processing the request.
Beginrequest. This event indicates a new request; each request must generate this event.
Authenticaterequest. This event indicates that the configured authentication mechanism has verified the request. Attach this event to the filter to ensure that the request has passed authentication.

Authorizerequest. Like authenticaterequest, this event marks another step in the request processing process and the request has been authorized.

Resolverequestcache. The output cache module uses this event to simplify processing of cached requests.
Acquirerequeststate. This event indicates that each request status should be obtained.
Prerequesthandlerexecute. This event indicates that the request handler will be executed. This is the last event that you can participate in before calling the HTTP processing program of this request.

The next list shows the events generated after processing the request. These events are listed in the order of occurrence:
Postrequesthandlerexecute. This event indicates that the HTTP processing program has completed processing the request.
Releaserequeststate. This event indicates that the request status should be stored because the application has completed processing the request.
Updaterequestcache. This event indicates that code processing has been completed and files can be added to the ASP. NET cache.
Endrequest. This event indicates that all requests have been processed. This is the last event called at the end of the application.

In addition, the following three pre-processing events can be triggered in an uncertain order:
Presendrequestheaders. This event indicates that the HTTP header will be sent to the client. Therefore, you can add, delete, or modify header information before sending the message.
PreSendRequestContent. This event indicates that the content will be sent to the client. This provides an opportunity to modify the content before sending the message.
Error. This event indicates an outstanding exception.

Related Article

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.