3. Comparing Facelets and JavaServer Pages (JSP)
Contents
>
3. Facelets Concepts
> Comparing Facelets and JavaServer Pages (JSP)
We recommend Facelets over JSP for JavaServer Faces. With a near-zero compile-time
overhead, developing JSF applications with Facelets is simply faster.
JSP Compile-Time Overhead
Every time you edit, save and reload a JSP page, the server's JSP compiler generates
Java servlet code and compiles it into a servlet. This is called the JSP translation process,
and typically it costs between 1-2 seconds, depending on server performance.
Facelets XML Compilation
Unlike JavaServer Pages, Facelets pages are not compiled into servlets. Since Facelets
pages are XML-compliant, the Facelets framework uses a fast SAX-based compiler to build your
views. Also, Facelets can be configured to detect and render changes to your pages
immediately, speeding up your JSF development cycle.
|