Monday, February 18, 2008

HTTP PipeLine and Application / Page Events


See the below three figures...









1. The ASP.NET HTTP pipeline relies on IIS to receive the request.

2. When IIS receives an HTTP request, it examines the extension of the file.

3. If the file extension is associated with executable code, IIS invokes that code, in order to process the request.

4. Mappings from file extensions to pieces of executable code (.exe) are recorded in the IIS metabase.

5. When ASP.NET is installed, it adds entries to the metabase (associating various standard file extensions, including .aspx and .asmx), with a library called aspnet_isapi.dll.

6. When IIS receives an HTTP request for one of these files, it invokes the code in aspnet_isapi.dll, which in turn funnels the request into the HTTP pipeline.

7. Aspnet_isapi.dll uses a named pipe to forward the request from the IIS to an instance of the ASP.NET worker process, aspnet_wp.exe.

8. The aspnet_wp.exe worker process uses an instance of the HttpRuntime class to process the request.



Below the diagrammatic representation of mixing Page-Events with Application-Events.








This life cycle of the ASP.NET page starts with a call to the ProcessRequest() method. This method begins by initializing the page's control hierarchy.

The life cycle of Page ends by handing off the Web page's HTML markup to the Web server, which sends it back to the client that requested the page.

1

Application_Start

2

Application_BeginRequest

3

Application_AuthenticateRequest

4

Application_AuthorizeRequest

5

Application_ResolveRequestCache

6

Session_Start

7

Application_AcquireRequestState

8

Application_PreRequestHandlerExecute

 

Page Life Cycle occurs, and at the end generated HTML is sent to the server. This HTML is then rendered by the client/browser.

This is the place where the Page events mentioned at the right side of figure 2 occurs.

9

Application_PostRequestHandlerExecute

10

Application_ReleaseRequestState

11

Application_UpdateRequestCache

12

Application_EndRequest

13

Application_PreSendRequestHeaders

14

Application_PreSendRequestContent

 

Form Displays



Blogged with Flock

HTTP PipeLine and Application / Page Events


See the below three figures...









1. The ASP.NET HTTP pipeline relies on IIS to receive the request.

2. When IIS receives an HTTP request, it examines the extension of the file.

3. If the file extension is associated with executable code, IIS invokes that code, in order to process the request.

4. Mappings from file extensions to pieces of executable code (.exe) are recorded in the IIS metabase.

5. When ASP.NET is installed, it adds entries to the metabase (associating various standard file extensions, including .aspx and .asmx), with a library called aspnet_isapi.dll.

6. When IIS receives an HTTP request for one of these files, it invokes the code in aspnet_isapi.dll, which in turn funnels the request into the HTTP pipeline.

7. Aspnet_isapi.dll uses a named pipe to forward the request from the IIS to an instance of the ASP.NET worker process, aspnet_wp.exe.

8. The aspnet_wp.exe worker process uses an instance of the HttpRuntime class to process the request.



Below the diagrammatic representation of mixing Page-Events with Application-Events.








This life cycle of the ASP.NET page starts with a call to the ProcessRequest() method. This method begins by initializing the page's control hierarchy.

The life cycle of Page ends by handing off the Web page's HTML markup to the Web server, which sends it back to the client that requested the page.

1

Application_Start

2

Application_BeginRequest

3

Application_AuthenticateRequest

4

Application_AuthorizeRequest

5

Application_ResolveRequestCache

6

Session_Start

7

Application_AcquireRequestState

8

Application_PreRequestHandlerExecute

 

Page Life Cycle occurs, and at the end generated HTML is sent to the server. This HTML is then rendered by the client/browser.

This is the place where the Page events mentioned at the right side of figure 2 occurs.

9

Application_PostRequestHandlerExecute

10

Application_ReleaseRequestState

11

Application_UpdateRequestCache

12

Application_EndRequest

13

Application_PreSendRequestHeaders

14

Application_PreSendRequestContent

 

Form Displays



Blogged with Flock

Untitled

A quick guide to == , Equals(x,y),

 

= =

RefererenceEquals(x,y)

Virtual Equals(x)

Static Equals(x,y)

Value Types

Check for Value Equality

Checks for Reference Equality.

 

Will always return false.

Reason: Boxing is required and hence boxing will result into two different objects.

Overridden for ValueTypes: Hence Checks for Value Equality.

 

But, But, But,,,, using ‘==’ for structs [Again a Value Type] willl result in compliation error as there is no overloaded version is present of ‘==’ for value types.

 

Reference Types

Check for Reference Equality & never checks objects based on their contents.

 

Will return False, if both objects are different.

 

Will return True, if both objects are same, i.e points to same location.

Check for Reference Equality & never checks objects based on their contents.

 

Will return False, if both objects are different.

 

Will return True, if both objects are same, i.e points to same location or both are null.

 

 

Problem: Cannot be overridden to compare objects by value.

 

Check for Reference Equality & never checks objects based on their contents.

 

Will return False, if both objects are different.

 

Will return True, if both objects are same or null, i.e points to same location.

 

 

Problem: Can be overridden to compare objects by value, but will throw an exception if either of them is null.

 

Check for Reference Equality & never checks objects based on their contents.

 

Will return False, if both objects are different. Or either if them is null.

 

Will return True, if both objects are same, i.e points to same location or both are null.

 

 

 

String Types

Same as Value Types

Overridden for String Types:  Hence Checks for Value Equality.

 

Blogged with Flock

Thursday, February 14, 2008

Training sessions in globallogic Presentation slides and demos

Hi,
i would be hosting the ppt slides on .net presentations on WPF , WCF ,WF Cardspace and Silverlight on http://docs.google.com/.

Send me an email to get a copy or add you as collaborative editor on the related document ppt slides.

I have also hosted the files here.

The related quick demos built during the training session are here.

Blogged with Flock

Kick start !!!

After a long hibernation, i have decided to blog on silverlight 1.0 and .net 3.5 technologies. The humble intention would be to collaborate the efforts of various people who like to learn and share the ideas on the subject.

I will try to be as regular as possible on this one. Reason 1 being that this is one area where things are moving really fast!!

Reason2 being that as the frameworks are moving from Alpha, beta and RTC the changes that happen along with breaks the previous code sometimes and to keep track a blog is better place that any code repository!! ( No Pun intended!!) :)

so.. looking forward for your comments and suggestions, as always.

Blogged with Flock