Create your own awesome maps

Even on the go

with our free apps for iPhone, iPad and Android

Get Started

Already have an account?
Log In

Introduction to ASP.NET MVC by Mind Map: Introduction to
0.0 stars - reviews range from 0 to 5

Introduction to ASP.NET MVC

Product Information

Creator: Scott Guthrie (Scott Gu)

Program Manager @ Microsoft - Phil Haack

Release Timeline

Version 1.0 - March 2009

Version 2.0 - March 2010


Common Gateway Interface (CGI)

Browser (Client) >> Sends Request to >> Executable Program (On Server) >> Sends HTML Output back to Browser

Active Server Pages (ASP)

Introduced "templating" in web pages

HTML & dynamic script lived side by side leading to spaghetti code


Separated web page into aspx (HTML & dynamic server controls in XML format) and Code Behind (aspx.cs)

Overcomplicated ASP.NET Page Life Cycle, determining the right location in the life cycle for code was not intutive

Unit testing impossible or too difficult as everything was tightly coupled with the UI (System.Web)

View State did not scale well for large applications

Huge collection of ready to use controls

Automatic State Management


Implements the Model View Controller web presentation pattern

Clear separation of concerns, Data Model, Application Logic, Data Presentation

Postback cycle & Viewstate no longer necessary

What is MVC ?

Acronym for Model-View-Controller

Model, Contains the logic for the application data, In most cases writes model state to and from the database

View, Displays application's UI, UI is normally created from model data, Does not handle user inputs

Controller, Handle user interaction, Work with the Model to perform data manipulation, Selects a view and passes it the model data to be rendered

It is a "presentation" design pattern

Key principle is Seperation of Concerns (SoC)

Each component has a single responsibility

SRP: Single Responsibility Principle

DRY: Don't Repeat Yourself

Allows you to concentrate on a single aspect (e.g. UI) of the application without having to worry about the other

Easily testible due to loose coupling between elements

Elements can be tested in isolation from framework and other components


Can we mix ASP.NET & ASP.NET MVC in an application ?


ASP.NET MVC sits on top of ASP.NET (3.5)

It is not a replacement for webforms, rather an alternative

Does not replace ASP.NET (3.5) libraries or functionality

Phased migration from ASP.NET to ASP.NET MVC is possible by adding the MVC libraries and the routing data

Note that ASP.NET MVC works well with Web Application Projects (and not websites)

URL Routing HTTP Module in web.cofig decides who gets to process the request

If route is found >> ASP.NET MVC

If no route is found >> Webforms

Features of ASP.NET MVC

Test Driven Development (TDD)

All core contracts are interface based allowing them to be easily mocked

Loose coupling of elements allows for quick and easy unit testing

Any Unit Testing framework that is  compatible with .NET can be used

Highly Extensible & Pluggable

Interface based architecture

Very few sealed classes or methods

Easily replace components of the system with custom solutions

e.g. you can plug in your own view engine (instead of the winform template view engine)

URL Routing

User and Search Engine Optimization (SEO) friendly URLs

URLs do not need file extensions anymore

REST (Representational State Transfer) addressing

Heavy on Convention & Guidance (Convention over Configuration)

Built on top of ASP.NET, hence inherits all its features like Profiles / Membership / Security etc

Supports Post Redirect Get (PRG) pattern


Use Web Forms when ...

You want built in state management & postback mechanism

You need out of the box functionality. There is a huge pool of Server Controls for ASP.NET

You need rapid application development for small projects

Less code is needed in ASP.NET (than MVC) for smaller applications

ASP.NET uses Page Controller pattern (functionality in individual pages)

Use ASP.NET MVC when ...

You need complete control over application behavior (no default view state or post back)

You want to handle complexity by breaking the system into M-V-C

You need TDD (test driven development)

MVC uses Front Controller (single controller) pattern (supports rich routing infrastructure)


Description: This Mind Map introduces ASP.NET MVC to web developers

Created by: Preeti Edul

Visit my blog for more ASP.NET MVC mind maps