HomeDigital EditionSys-Con RadioSearch Java Cd
Advanced Java AWT Book Reviews/Excerpts Client Server Corba Editorials Embedded Java Enterprise Java IDE's Industry Watch Integration Interviews Java Applet Java & Databases Java & Web Services Java Fundamentals Java Native Interface Java Servlets Java Beans J2ME Libraries .NET Object Orientation Observations/IMHO Product Reviews Scalability & Performance Security Server Side Source Code Straight Talking Swing Threads Using Java with others Wireless XML

OpenSymphony is a collection of Java open source projects that provides a foundation for building J2EE applications. Each application tends to build from another OpenSymphony component in a loosely coupled manner, providing a best-of-breed option.

The OpenSymphony initiative has been running strong for about three years now and has been in a state of production readiness from almost the beginning. Many developers use the OpenSymphony projects as an alternative to the Apache-Jakarta project due to its "if you build it they will come" attitude. OpenSymphony developers take a much different approach to their projects: add code that is fully unit tested and ready for production, as opposed to code that might fulfill a bullet-list requirement immediately.

One of the more popular OpenSymphony projects is SiteMesh. Imagine, for example, that you need to maintain a collection of pages for a particular Web site where each page shares the same look and feel in navigation. SiteMesh enables the developer to quickly apply a decorator to a specific page that would cascade the changes through the entire page set. This works by using the servlet filter API to analyze the HTTP request by mapping specific page requests to decorators that are defined in a configuration file. One of the more common uses of this would be for a header and footer.

OSCache is an API used to perform fine-grained dynamic caching of JSP content. Of course, you can use OSCache for much more, such as caching search results or another type of dynamic data on your model layer. The most powerful feature of the package is in the JSP taglib section. With the JSP taglib code, the developer has the ability to cache everything, from the whole page to a specific section! OSCache allows you to immediately hit the ground running with the easy-to-use API in any Java application.

WebWork does much of the same as Apache-Struts but provides a much cleaner and simpler approach. One of the key advantages of the framework is the decoupling of the controller from the traditional view technologies such as JSP, Velocity, and XML/XSLT. WebWork can easily be plugged into a standard Java application, SOAP, or testing suite, such as JUnit. The modularization of the project makes WebWork an easy choice when deciding on a controller for building a J2EE application.

OpenSymphony is not without its faults, though. The documentation and examples for the WebWork and OSWorkFlow projects are more than lacking. However, the community and teams have recognized their weaknesses and are actively working on providing better documentation and examples for upcoming releases.

Don't let the lack of documentation hold you back, though. All the projects are extremely valuable and integrate with each other flawlessly at a production-quality level that other open source projects should follow. The up-front investment time to learn OpenSymphony will pay for itself many times over and will leave you wondering why you didn't start using the projects sooner.

Reference

  • OpenSymphony Project: www.opensymphony.com

    Author Bio
    Justen Stepka is an enterprise system architect for digital @ JWT Minneapolis. He develops Web-based applications for Fortune 500 companies and is actively involved in the design and research of emerging Web technologies. [email protected]

    All Rights Reserved
    Copyright ©  2004 SYS-CON Media, Inc.
      E-mail: [email protected]

    Java and Java-based marks are trademarks or registered trademarks of Sun Microsystems, Inc. in the United States and other countries. SYS-CON Publications, Inc. is independent of Sun Microsystems, Inc.