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
 

IMHO: Blueprinting Java, by Ajit Sagar

Last year Sun came out with a new set of design guidelines for building enterprise applications using enterprise Java APIs. These APIs are available as a set of documents called the J2EE Blueprints. They include architectural design guidelines for developing enterprise applications using the Java 2, Enterprise Edition APIs.

The Silver Bullet
The primary benefit of the Blueprints is that after five years and several releases of Java platform products and APIs, there's finally a comprehensive story of how all these technologies offered by Java can plug and play together in enterprise-level applications. Using the Blueprints as guidelines also helps architects and developers make choices between alternative technologies and products, based on the constraints of their business and operating environments.

The J2EE Blueprints address enterprise application development using the design pattern MVC (Model-View-Controller) to build the underlying framework. Designing Enterprise Applications with the Java 2 Platform, Enterprise Edition (Addison-Wesley) covers the Blueprints in detail. A PDF of the Blueprints as well as a sample "Pet Store" application can be downloaded from Sun's web site, http://java.sun.com/j2ee/download.html. The sample illustrates how the Blueprints can be applied in a distributed business application.

The Whole Enchilada?
This is great stuff. You now have a single source to get all the information you need to develop enterprise-level, distributed, transactional applications using only Java technologies. Select your application server, download the appropriate APIs, and off you go. If you can, use Java APIs to create all the building blocks in your application. If you can't, there are well-defined integration points to connect to the outside world.

The real questions you should ask yourself are how much of this do you want to build in-house, and how much do you want to buy off the shelf? If you were developing the Pet Store application in the real world, you could probably build everything using your development resources. However, if you're dealing with applications that span multiple business scenarios, chances are you'll soon run into issues such as resource allocation and maintenance if you decide to build all the pieces yourself. Of course if you're in the business of building frameworks and application servers, it's a great idea to do it all yourself. However, that will be your main product, not the business applications you build on top of such frameworks.

Let's look at the presentation layer. You can use a combination of JSP, servlets, and XML to create your presentation layer. JSP can be used to create the presentation templates and guide the flow of pages by designing the layout manager for your site. Servlets can send the appropriate content into syndicated columns. And XML serves as a great format for exchanging data with the outside world. The combination of these technologies can be used to create a presentation layer for your application.

What happens when you want this framework to be generic so it can be applied across a variety of business scenarios? How much effort will be required to further abstract your design to provide templates that can be configured for different applications? This is where you'll start running into maintenance and resource problems.

If It sounds too good to be true...
Don't get me wrong. It's not that the Blueprints mislead the development community into believing that everything should be done in-house. It's just that they can be interpreted in different ways. Typically, if you were working on applications that span several business scenarios and applications, you would depend on technology vendors such as application server providers to implement the frameworks that make it all possible. And dare I say it, you would also look outside the Java world for some of your needs. A large part of the existing presentation and personalization products in the market are built on Web scripting technologies that complement Java environments. For example, companies such as Allaire, BroadVision, Vignette, and ATG provide the frameworks required to build such applications. That's the very reason they're in business.

Author Bio
Ajit Sagar is the founding editor and editor-in-chief of XML-Journal. A senior solutions architect with VerticalNet Solutions based in San francisco, he's well versed in Java, Web, and XML 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.