Initially, the JSF server side code is a lot cleaner, shorter, and simpler. As far as lines of code, it is. The difference is that much of the code you see in the Stripes server side code is scattered across a couple of places for JSF. For example, all the validation for simple form fields will be specified in the JSP and the page flow or navigation is in the faces-config.xml. Stripes has no external configuration for such things. It's all encapsulated in one place. This is largely due to annotations.As a result of this and JSF's component model for rendering, the JSP used for JSF is also more complicated compared to Stripes. Part of what inspired this was a conversation in which had "proponents for JSF jumping in claiming that JSF is 'good enough.' It's interesting that a lot of the comments from JSF proponents in several threads I've been keeping an eye on were things like '...it has its issues but...' and '...a workaround for that is...' With JSF being the standard web framework in Java EE, a common set of well-known flaws are a problem. Some JSF experts can (and have) shown various ways to modify JSF's phases and presentation layers such that nearly anything can be done within JSF's overall framework, but just because something can be done doesn't mean that it should be done. What's your opinion on this?
Gregg Bolinger has written "Stripes and JSF: A Brief Comparison" on his blog, offering a quick bird's-eye view of some of the differences between the frameworks. He's a Stripes proponent, although he is being fair in his comparison. In terms of the data model, Gregg says that
- Posted by: Joseph Ottinger
- Posted on: January 04 2007 10:07 EST
- Re: Stripes and JSF: A Brief Comparison by random fletch on January 04 2007 11:04 EST
- Stripes and JSF: A Brief Compariso by Adrian Mitev on January 05 2007 06:52 EST
- Stripes, what else? by David Rozenberg on January 07 2007 10:04 EST
This is a pretty superficial comparison because Stripes and JSF have different goals. Stripes is a classic page oriented model 2 web application framework whereas JSF is a component based web framework. Stripes is tidy because it takes advantage of annotations to reduce the amount of configuration historically required to build web applications but doesn't support a reusable component model. JSF allows you to build web applications out of reusable components but is relatively configuration heavy.
However you can configurate your JSF application with anotation too using Shale tiger extensions or JBoss Seam.
And with JSF RI implementation you don't have to use much jars like in myFaces.
Stripes is a sub-project of Struts. So, it inherits some well known issues with Struts. I would not praise one over another. It seems to me that theserverside.com is the right place to collect opinions and/or ptovide reviews on why we need that many frameworks for a pretty simple task of creating a web application (a small set of web pages with simple navigation between them plus some code on the server side to basically construct the dynamic content of those pages, if any, plus some persistence related code). Any ideas or suggestions?
Stripes is a sub-project of Struts. So, it inherits some well known issues with Struts.I generally don't like to comment in opinion threads about Stripes since I wrote most of it, but I can't let this stand. Stripes is absolutely not a sub-project of Struts - it's not even an Apache Project. Neither does it contain any code from the Struts (or Struts 2) code bases. It's a completely independent project that competes directly with Struts 1 and 2. Cheers. -Tim Fennell Stripes: Because web development should just be easier
I would not praise one over another.