Win a copy of Re-engineering Legacy Software this week in the Refactoring forum
or Docker in Action in the Cloud/Virtualization forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

MVC architecture

 
rai talari
Ranch Hand
Posts: 34
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
can any one explain the difference between MVC type1 and MVC type2 architure.if not can u provide any links to the articles regarding the above mentioned .thank you
 
Manuel Palacio
Ranch Hand
Posts: 45
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Model 1 embeds navigation in the JSPs. It tends to be brittle when the number of pages gets large.

Model 2 combines JSPs with a servlet, usually a single front controller, which handles the navigation chores and leaves the JSPs to concentrate on presentation. All requests are sent from JSPs to the front controller servlet.
Some purists argue that because of missing out on the push aspect (the view pulls the data from the model in order to display tables, etc) of the true Model-View-Controller pattern, the Model 2 architecture shouldn't be called MVC. Nevertheless, the term "web MVC" is here to stay.

Struts and Java Server Faces are based on model 2 MVC.
 
Pradeep bhatt
Ranch Hand
Posts: 8927
Firefox Browser Java Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The Model 2 architecture shouldn't be called MVC

Is it Model 1 ?
 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 64633
86
IntelliJ IDE Java jQuery Mac Mac OS X
 
ak pillai
author
Ranch Hand
Posts: 288
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Good article here:

http://www.javaworld.com/javaworld/jw-12-1999/jw-12-ssj-jspmvc.html


Model 2 is what, you should be more interested in and it is good to know, what model 1 is.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic