This week's book giveaway is in the OO, Patterns, UML and Refactoring forum. We're giving away four copies of Refactoring for Software Design Smells: Managing Technical Debt and have Girish Suryanarayana, Ganesh Samarthyam & Tushar Sharma on-line! See this thread for details.
You can't compare JSF and JSP like you are trying to do. JSF uses JSP. Now, if you mean JSF as a framework vs Servlet/JSP programming, then we can have a discussion. One of which that has been discussed many many times before.
Frameworks allow you to get your work done quicker. Frameworks take care of mundane details that you would have to create from scratch if using straight JSP/Servlets.
I doubt JSP/Servlet development will ever disappear. I feel that in order to use any J2EE based framework, you need to know how the underlying system is working. You need to know how JSP's and Servlets work without the framework.
I have not messed around with JSF yet, but from what I've read so far JSF and Struts are pretty much the same idea... a MVC (Model 2) architecture. Now, JSF is supposed to provide a "rich component set". What does that mean? How do these components work within the browser, do they run in an applet container?
JSF because it adds many benefits of a front controller, but at the same time gives you the flexibility of the Page Controller. JSF can have several event handlers on a page while Struts is geared to one event per request. In addition, with Struts, your ActionForms have to extend Struts classes, creating another layer of tedious coding or bad design by forcing your model to be ActionForms. JSF, on the other hand, gives developers the ability to hook into the model without breaking layering
Navigation is a key feature of both Struts and JSF. Both frameworks have a declarative navigation model and define navigation rules inside their XML configuration file. There are 2 types of navigation: static navigation - when one page flows directly to the next; and dynamic navigation - when some action or logic determines which page to go to.
JSF Static Navigation
JSF supports navigation by defining navigation rules in the faces configuration file. The example below shows a navigation rule defining how one page goes to the next.
Originally posted by Kevin Arouza: I have not messed around with JSF yet, but from what I've read so far JSF and Struts are pretty much the same idea... a MVC (Model 2) architecture. Now, JSF is supposed to provide a "rich component set". What does that mean? How do these components work within the browser, do they run in an applet container?
Struts can not be placed on the same pedestrial as JSF. JSF is a componenet based framework which is built on top of the raw Http protocol, just like Tapestry. Though, still at its infancy, if comparisons of frameworks are to be made then JSF should be compared to frameworks such as Tapestry. On the other hand I do not see JSP going away, as a good grasp of Servlet/JSP would be necessary for effective use of these java based web frameworks.