- Icefaces 2
- Primefaces
- Richfaces
I will focus on efficiency : page size, ajax request/response size, server load, and not on features.
JSF can call a getter more than once per request.
For example in the following JSF file :
<html>
<body>
<h:dataTable var="car" value="#{carService.cars}">
<h:column>
<f:facet name="header">
Model
</f:facet>
<h:outputText value="#{car.model}"/>
</h:column>
<h:column>
<f:facet name="header">
Year
</f:facet>
<h:outputText value="#{car.year}"/>
</h:column>
<h:column>
<f:facet name="header">
Manufacturer
</f:facet>
<h:outputText value="#{car.manufacturer}"/>
</h:column>
</h:dataTable>
</body>
</html>13:39:40 DEBUG : CarService.getCars:17 - qtp17489534-18
13:39:40 DEBUG : CarService.getCars:17 - qtp17489534-18
13:39:40 DEBUG : CarService.getCars:17 - qtp17489534-18
A getter obviously returns a value. This value can be a bean property or a calculated value.
If the value is calculated, this can potentially be a problem.
I googled a bit and found some workarounds.
For me, the last workaround is the best one because you do not have to modify the view.
And thanks to Spring, it's quite simple to add AOP with a few annotations.
This article has been published first on Javalobby
I use JSF and especially Richfaces for 1 year. During this year I had a few issues with Richfaces popups.
One of my coworker said richfaces popup component doesn’t scale because each sort of popup requires a specific declaration. The team had create a JSF fragment file that contains all the popup components whatever their domains or the business logic location in package and module.
My opinion is that a popup should be part of the UI logic. It should not be a component you add like a textbox but it would rather be a window you create with a createPopup method.
Ok let's try to improve popup logic.