MVC Life Cycle – 6th Part

Hi Friends,

In this section, we will continue from the last section and the see the next segment of Action Execution Process. Here, in this case we will see Filters in action. Therefore, before the action method chosen, the Authentication and Authorization filter runs. Filters are nothing but MVC components to inject extra logic in between the MVC pipeline.Therefore, first authentication filter runs and if it succeeds then it will go to Authorization filter otherwise it will again ask user to re-authenticate. However, authorization is the filter which says are you allowed to access particular thing or not.

Continue reading “MVC Life Cycle – 6th Part” »

MVC Life Cycle – 5th Part

Hi Friends,

In this section, we will look at Action Execution event in the MVC life Cycle. Once, controller gets initialized then action invoker has to take decision saying which method to invoke and this piece is done by Action Invoker in the life cycle. Action Invoker based on different method signatures present in controller identifies the exact method to be invoked.

In the above snippet, there are two about methods. In this case, it has become ambiguous for action invoker to figureout to choose which method to pick and hence produced below error. 19th   However, this can be easily fixed by applying any HTTP Verbs or Action Selectors like shown below.  

Continue reading “MVC Life Cycle – 5th Part” »

MVC Life Cycle – 4th Part

Hi Friends,

In this section, we are going to see how Controllers are created and initialized.Basically, controllers does nothing but implement IController interface. IController defines one important method called Execute(). Also, it is important to note that this method is entirely generic which means you can build your controller in a more custom way specific to particular requirement. However, MVC is very powerful framework wherein all the concerns are already addressed. But, you can extend the default implementation for any specific need.

Continue reading “MVC Life Cycle – 4th Part” »

MVC Life Cycle – 3rd Part

Hi Friends,

In this section, we will continue from the previous point and delve further into MVC components. Here, in this case we will look at building custom handler. HTTPHandlers implement IHTTPHandler and generate a response to HTTP-Request. Therefore, we first need to create the Handler and then register the same with the application either through code or via config file. Now, IHTTPHandler exposes two properties.

Continue reading “MVC Life Cycle – 3rd Part” »

MVC Life Cycle – 2nd Part

Hi Friends,

In this section, we are going to delve further around MVC Life Cycle. In the previous section, we have seen basic flow of MVC. However, let us consider the case, wherein you need to inject your custom module and wants to do logging extensively. In this kind of situation you want to execute some custom codes before actually the application starts. In order to achieve this kind of scenario, you need to make use of “PreApplicationStartMethod” @ assembly level. Below is the actual line of code of registering your custom module at PreApplicationStartMethod level.

Continue reading “MVC Life Cycle – 2nd Part” »

MVC Life Cycle – 1st Part

Hi Friends,

In this section, I am going to describe MVC Life Cycle. If you are an MVC developer, then this entire flow should be in your DNA. This not only solves complex problem rather it also makes an app more robust, future proof, maintainable and testable. Below, I have pasted very high level diagram for the same. Therefore, without wasting time, let us get started.


  Continue reading “MVC Life Cycle – 1st Part” »

Learning Angular JS in 2 Hours – 3rd Part

Download Code:-

However, if you would like to learn the stuffs from the scratch and code along. you can refer the below stuffs.

Getting Started with Angular JS :-
Building SPA with Angular and MVC 5:-

Demo Site:-

Thanks for Joining Me!

Rahul Sahay
Happy Coding