Sun engineers discuss the relevance of JavaServer Faces What is the JavaServer Faces specification all about? Why is it important to Web development?Among other things, JavaServer Faces technology is a framework that simplifies user interface (UI) development for Web applications. It helps users assemble reusable UI components on a Webpage, manage its state, handle events, and easily connect them to backend data sources.It’s important to Web developers because it saves them time, enables them to build more powerful applications, and makes their lives easier. It brings some of the capabilities of rich client user interface programming to the Web. It is difficult to program high-quality Web-based user interfaces for several reasons: the Web has no notion of state, so one user interface view can’t convey itself to another; there’s no way to convey events; and there’s no notion of components. JavaServer Faces helps developers deal with this inhospitable environment. It provides the fundamental building blocks of user interactions, and allows for the reuse of components. The technology is attractive to tool vendors because, for the first time, there is a standard for Web user interface components—a standard that was designed through the Java Community Process. Which makes Web development even easier.There have been many other technologies in the space, and tool vendors have had to chase these other technologies, including Struts, Tapestry, and Velocity. Now tool vendors can converge on the standard, and, as a result, developers find Web applications that are created in one tool have the ability to be altered in another. Additionally, these tools are supported in many different environments.Developers reap the benefits of standardizing tools and components for JavaServer Faces. With standards, developers can pick and choose tools and components from a variety of vendors that best fit their needs. Many of the JavaServer Faces-enabled tools come from vendors that developers are already familiar with. When compared to components built from scratch, JavaServer Faces components are more powerful and of better quality. What’s the status of the JSR?The specification, reference implementation, and technology compatibility kit for Java Specification Request (JSR) 127 were released in March 2003. A maintenance release came out at the end of May 2004. The maintenance work involved some bug fixes and performance work in the reference implementation, and some clarifications to the specification. The specification is available from the Java Community Process Website and the reference implementation is available at java.sun.com.The reference implementation is also included in the Java 2 Platform, Enterprise Edition (J2EE) SDK, which provides an application server with JavaServer Faces built right in. The main thrust of the JavaServer Faces 1.2 JSR will be to make JavaServer Pages (JSP) and JavaServer Faces technologies more cohesive. Originally, JavaServer Faces 1.0 was dependent on JSP 1.2 and Servlet 1.3, and there was no way to use JSP’s new expression language. The JavaServer Faces expert group crafted an expression language that was very similar to JSP, but added a few new concepts to satisfy new requirements. To remedy the overlap, JavaServer Faces 1.2 will depend on JSP 2.1, which is being defined in JSR 245. The main goal of the two new JSRs is to roll JavaServer Faces’ new concepts back into the expression language in JavaServer Pages. Using the same expression language for JavaServer Pages and JavaServer Faces will make it easier for developers to access application data stored in JavaBeans components. Of course, there will also be bug fixes and performance improvements.We’re also looking ahead to JavaServer Faces 2.0, which has not yet been filed with the JCP. It will cover additional new features as requested by the community and customers, especially features that focus on improvements in tools.Why did you elect to build Java Studio Creator on JavaServer Faces? What advantages did it offer? Java Studio Creator makes new inroads in ease of development. Its mission is to make Java technology and Web technology more accessible, and it was built to take advantage of the foundation and standards in JavaServer Faces. Java Studio Creator is an easy-to-use Web application and Web services tool for developers, and thus JavaServer Faces was a great fit.Java Studio Creator takes the JavaServer Faces technology and makes it even easier to develop applications, making it accessible for an even larger audience of developers. It leverages the underlying framework of JavaServer Faces, utilizing the application framework for functionality such as navigation. Java Studio Creator carries ease-of-development one step further. For example, developers have a richer experience using the tool because of extra design-time information that is built in.JavaServer Faces and Java Studio Creator are great examples of how Sun invests in innovation and open standards, and generates revenue from that investment. Sun has built a top-quality competitive product on top of the standard. Sun was also the first to support a JavaServer Faces implementation when it was incorporated into the Sun Java System Application Server Platform Edition 8. What advice can you offer developers who are trying to take advantage of JavaServer Faces in their work?Continue to focus on the customers for whom you are building your user interface. JavaServer Faces lets you spend less time worrying about the complexity of Web interactions and more time thinking about customer tools.Secondly, take advantage of tools that utilize JavaServer Faces, like Java Studio Creator. Finally, investigate the rich and growing market of components that are available for use in your JavaServer Faces application. It’s much easier than creating the functionality from scratch.It’s also possible to write a JavaServer Faces application without a tool, if you’re so inclined. It’s roughly the same amount of work as if you were using another framework, such as Struts.What advice do you have for developers who have already used other frameworks, such as Struts? If you’re starting a new project, try using JavaServer Faces. It does nearly everything Struts does, and component vendors will provide the rest.Struts works well with JavaServer Faces. If you have an existing Struts application, you can easily migrate the user interface portion to JavaServer Faces by using the Struts/Faces integration library.How can a developer get started writing components for JavaServer Faces? There’s a lot of information on creating components in the J2EE 1.4 Tutorial. The article “Guidelines for Designing Reusable Custom Components Using JavaServer Faces Technology” should also prove helpful. After you have created a custom component, we recommend testing it with the JavaServer Faces Reference Implementation, or even better, test it on the J2EE SDK, where you can leverage the capabilities of Sun’s free Java System Application Server.How can developers get more involved in JavaServer Faces?There are many avenues for community involvement. Most simply, you can use the technology, file bugs, and request features. There’s a Web-based issue tracker where you can post feature requests on java.net. Community members can also contribute patches by sending them to java.net.After you’ve built up a history of high-quality patches, we will grant write access to the code if you’re willing to play by the rules. We’re a firm believer in test-driven development—we use a test-first strategy like that described in extreme programming—and we require code reviews and unit tests before committing code.Also, you can comment on the development of the specification during the Early Draft and Public Draft stages of the Java Community Process. We’re very open to suggestions and involvement from the community, and we welcome your comments. Java