MVC or event-driven component-oriented web frameworks?

Go To StackoverFlow.com

5

This question intends to be technology-agnostic. Which kind of web framework do you prefer, and when: Pure MVC or event-driven component-oriented?

Just to make the point in "technology-agnosticism", here I name a few MVC vs. component web frameworks, in diverse technologies / languages:

  • Struts vs. Java Server Faces / Tapestry
  • The new ASP.NET MVC vs. "classic" ASP.NET
  • Cake PHP vs. PRADO
2008-09-19 06:10
by Pablo Marambio


5

I'm a php dev by day; however, I strongly prefer Wicket and/or Lift, especially the latter. The problem with Prado seems to be that the controller is tied to the page, rather than the logical controls on the page, otherwise, it still seems better than most other options in PHP land. I think all boils down to reusability, unless you have components that are backed by controllers, you can't separate the display all that well from the backing control logic.

MVC as implmented by all these 'MVC' frameworks seems to suck, you get a logical page with a tonne of controls and you have to handle all those on page controllers, wow, thanks, now I have MVC / n, where n is the number of controls. Most 'MVC' systems that I've seen so far, have been a mish-mash of brain-dead tag libraries, contorting request response into a single controller that has to be aware of everything on the page.

xhtml templates with js, and css wonderfully separated. Along with a few classes backing those components, and all of a sudden you're not busy wondering how complex pages are going to work, or if you want to take piece x, and drop it somewhere else.

2009-02-27 00:27
by Saem


2

Right now, the 'new hotness' trend is towards the MVC approach. I personally prefer the conventions of MVC frameworks, as a lot of the scut work that takes up valuable development time is done away with. That being said, the constraints tend to be fairly rigid, and a more traditional component-based approach might be needed in certain situations. All in all, it's a right tool for the job sort of choice.

2008-09-19 06:15
by Misplaced


2

The technology used is usually not matter of choice and especially in a big company you don't have many options.

If I were able to choose a technology, in Java I would pick Wicket. I have been using Spring MVC and it is good, but Wicket has a neat features that Spring MVC has not: server-side state management and encapsulation, rich component model, no unnecessary XML mapping files - just pure Java and HTML.

2008-09-19 06:29
by Petr Macek


1

I'm primarily an ASP.Net developer, but I find MVC is a better way of creating functionally complex websites (typically Line-of-Business type sites) since it allows for better separation of business logic and rules from the markup used to display data to the end-user. For quick and dirty sites (typically with a direct connection to the database) or richer interfaces, the "event-driven component-oriented" model is more effective.

2008-09-19 07:25
by NoName
(...) typically with a direct connection to the database <-- I guess you are thinking about DataProviders in ASP.NET, huh? Yeah, they tend to disorganize the development. Either you use them everywhere, or you don't use them at all - Pablo Marambio 2009-03-01 17:06


1

Personally I would say MVC is the way to go for web sites. You have a lot more control over the HTML and CSS and at the same time the controller pattern works very well with HTTP. Event driven web programming is great for small sites or for people who are not that clued up with HTML and CSS and more low-level concepts.

2008-09-19 10:10
by Mladen Mihajlovic
Quora is event driven and huge. Friendfeed acquired by Facebook (Cofounder Brett Taylor is now Facebook's CTO) was based on an event driven architecture. LinkedIn Mobile I believe works with node. I don't think event driven web programming is for small sites. I think it depends more on whether your site/application is extremely dynamic independent of user interaction - ckarbass 2013-02-14 23:56


0

I loosely follow these guidelines:

  • Web Forms/SQLDataSource- Quick and dirty app for internal use to show reporting or some other such data.
  • MVC- Simple to complex business logic for a core product.
  • MVC/REST Web Services/jQuery- HTML/Whatever type of client RIA's (when user experience reigns supreme).
  • Flash/Flex RIA- Useful when an extremely rich client is needed (think multimedia manipulation here).

There are a lot of gaps in this list of course but that just represents how complicated a question it is.

2008-09-19 06:28
by Justin Bozonier