Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What are the advantages of MVC over 3-Layer Architecture in web applications?

Please note that I'm referring to 3-layer (logical layering) and not 3-tier (physical).

Also don't get it wrong I'm not obsessed with design patterns. I'm a computer science student and they've asked me this trick question so I'm trying to find a smart answer.

Thanks for you answers in advance!

like image 286
Plamena Avatar asked Jun 21 '10 09:06

Plamena


2 Answers

They're not competing idealogies, MVC traditionally deals with the presentation layer of an app, i.e. one of the three layers.

like image 166
JonoW Avatar answered Sep 23 '22 17:09

JonoW


MVC is all about seperation of concerns - but deals with specifics in that the View is loosely-coupled to the model and controller; with 3-tier this is not explicitly required.

Yes - you can (and should) have all three tiers loosely-coupled but that's not explicitly required by 3-Tier; with MVC it is.

As an aside: MVC is a specific pattern that looks at a specific issue, I would be careful when referring to it as an "architecture".

An advantage of Microsofts ASP.NET MVC implementation is that is offers various integration points and flexibility which aren't so easily accessible with "standard" ASP.NET - which I guess you could say was/is traditionally used when build web-based 3-trie systesm in the MS space.

like image 42
Adrian K Avatar answered Sep 26 '22 17:09

Adrian K