A critic view on JSF Framework
April 28, 2008 13 Comments
JSF is becoming more popular framework for user interface layer development, many architects and companies assuming that Struts is becoming outdated and JSF is catching up the market. I am not sure whether it is true at this point of time. However I would like express my critic on the advantages and disadvantages of JSF.
- Big vendors (Oracle, IBM, JBoss, etc) backing JSF implementation like EJB. Can expect good level of support and quality components from these vendors.
- By design and concept it allows to create reusable components. That will help to improve productivity and consistency.
- Many quality and ready to use components are available from Apache, Richfaces, Infragistics, Oracle, etc.
- The concept of action and action listener for button invocation is good.
- Has very good support for EL expression that improves the user interface code readability.
- The concept the validator and converter is excellent. Unlike struts JSF keeps the validation logic very close to the component declaration.
- There is no benchmarking report or promise from Sun Microsystems about the performance of JSF framework. By seeing their concept I believe it is not suitable for high performance application.
- The specification doesn’t consider bookmarking facility.
- Hardly a very few examples available for developing dynamic pages including new component and removing a component from a page based on business rule.
- Every button or link clicked results in a form post. That’s just wrong – why can’t I have true links like the web is supposed to? Form submission for page navigation make complex coding for simple requirement like Cancel button. Read here to know the work around.
- Datatable component requires same data from bean on restore view phase. If the data retrieved from database, this will have impact on performance. Click here to know more about this issue.
- There is no tight coupling between managed bean and phase listener. This is a major drawback of JSF which makes JSF phase listener feature unusable.
- Default error message is not good. Need to customize the default error message.
- Not Scalable. It uses session object to store the component state across the request. In server farm environment it is too costly to replicate the session data.
JSF simplifies user interface development, and increases complexity on request processing lifecycle. At this point of time I don’t see JSF as a matured solution.
- JSF default timezone and date pattern
- JSF Best Practices
- Don’t let hype push you select wrong technologies