Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Up to date ASP.Net MVC 3 Request-Handling Pipeline Diagram?

Can anyone point me to an up-to date diagram of the ASP.Net MVC 3 request handling pipeline?

I've got an older version (MVC v1, v2), but it's no longer accurate, given the introduction of IControllerActivator in MVC3 (and possibly other framework changes).

like image 892
James Nail Avatar asked Apr 04 '11 16:04

James Nail


2 Answers

This is somewhat late for an answer but this could help someone (definitely helped me)

ASP.NET MVC Pipeline

Taken from this great article: An Introduction to ASP.NET MVC Extensibility

like image 145
mcabral Avatar answered Nov 14 '22 10:11

mcabral


This is a Request-handling Pipeline for ASP.NET MVC 2: http://ajaxus.net/wp-content/uploads/2010/01/asp_net_mvc_poster.pdf (or see page 228, Pro ASP.NET MVC 2 by Steven Sanderson).

The request pipeline is (maybe) not change in V3, but MVC 3 is extend some point to allow injection in every node of pipeline.

Example:
- At node: Controller factory:
+ ControllerBuilder create an instance of IControllerFactory (ex: the default factory)
+ factory implement Create() of IControllerFactory by:
++ Using an instance of IControllerActivation (activation)
++ Call activation.Create() of IControllerActivation to get instance of controller

So, IControllerActivation is work in DefaultControllerFactory. We can still use DefaultControllerFactory and replace IControllerActivation, or replace the DefaultControllerFactory with custom IControllerFactory (with or without use IControllerActivation)

like image 20
langtu Avatar answered Nov 14 '22 09:11

langtu