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

Several folks in the computing industry think of 1999 as having been the "Year of the Application Server." But while the term application server itself may be a fairly recent addition to the software computing vocabulary, the application server market has already become one of the fastest-growing markets in n-tier computing. Business analysts estimate its value as being likely to reach the multibillion-dollar level in 2001.

In today's distributed computing environment, the term application server is associated with state-of-the-art technology. Perhaps that's why several vendors sell their products under the category of application servers, regardless of whether the product actually offers the features of a basic application server or not. For example, there are site builders, Web page designers, integrated development environments, Web development tools and enterprise-level development environments. The definition of what comprises an application server is more often than not open for interpretation.

What's an Application Server?
An application server is, by definition, "a computer server that serves applications." More precisely, an application server serves up application services. The main purpose of an application server is to reduce the workload of applications by taking over the responsibility of mundane activities involved in executing the application and making the application's services available to external modules in a reliable manner.

I'd like to take a stab at defining an application server as follows: an application server is a computer program that resides on a server in a distributed network and whose main function is to provide the business logic for an application program; an application server provides a customizable and flexible execution environment for hosting business logic components, thus providing distributed services and integrity for application execution.

Traditionally, the application server has been associated with three-tier applications. To recap, the components of a three-tier application are:

  1. Front-end client: Typically a graphical user interface on a personal computer, laptop or a workstation
  2. Middle-tier application: Typically a business logic application on a LAN or the intranet server
  3. Back-end application: Typically a database/transaction server that provides access to legacy or back-office data
An application server provides an execution environment that decouples front-end clients from back-end data access. The execution environment is supported by an infrastructure that enables integration among different applications. Application servers enable this integration by offering software components that can be used to create business logic for an enterprise application. The supporting infrastructure may include architectural frameworks such as messaging systems, transactional managers and database accessors.

Benefits of Application Servers
The Internet being the most powerful phenomenon driving application development and deployment today, application servers came into existence because of a need in the market to offer flexible, robust, extensible and standards-based enterprise applications that are developed at Internet speeds.

Internet applications are typically shared between multitudes of parties participating in e-business transactions. This necessitates standard architectures and frameworks that allow application hosting. Application servers provide the execution environment for Internet applications. Vendors in the application server market add value to the equation by taking over the burden of application hosting and offering commoditized products that enable organizations to concentrate their resources on building the applications themselves.

In some ways, the application server market is moving toward the space currently occupied by operating systems. Operating systems are developed and maintained by third-party vendors. Companies use operating system services to develop applications in their business niche. In the same way, application server vendors can provide third-party services for use by distributed application developers.

The benefits to an application development vendor of using a third-party application server are:

  • Better product focus
  • Abstraction
  • Indirection
  • Application interoperability
  • Better resource utilization
  • External support and maintenance
"Pre-Web" Application Servers

The first generation of application servers came into existence before the Web became popular. These "pre-Web" application servers may be categorized based on the types of services they offer. Each category of application server decouples the client from the actual source of the service. In some respects, the application server acts as a broker: the client requests a service; the application server then makes a request to the appropriate service provider and passes the results of the request back to the client.

We could categorize application servers based on the services they offer. Some pre-Web application servers are:

  • TP monitors
  • Data servers
  • Document servers
  • Distributed object servers

Back to Web Application Servers
Web application servers have emerged as a result of developments in the computing industry. Principal among these are:

  1. The acceptance of the Internet as the ubiquitous medium for data interchange
  2. The emergence of HTML as the ubiquitous format for data presentation
  3. The evolution of standard distributed component models
  4. The evolution of standard protocols for data transport
The Web is another environment that supports n-tier applications. Consequently, the Web application server is a natural by-product of the evolution of n-tier distributed application development.

Web application servers are a new type of Internet software. They're a result of combining HTTP servers with distributed component frameworks (which are also the basis for the distributed object servers mentioned above). Currently, most application server vendors offer a combination of object application servers and Web application servers. Each of the other categories of application servers mentioned above has also evolved into specific categories of Web application servers.

When you add the Web to an application server, you have, literally, a Web application server. But what does this actually mean? Let's go back to the basics. The Web, in its simplest definition, is a group of computers that communicate via the HTTP protocol — the communication medium being the Internet. Hence, a Web server is basically an HTTP server. Consequently, a Web application server is a server that makes an application's service available to the client over HTTP.

The relationship between Web application servers and Web servers is illustrated in Figure 1.

Figure 1
Figure 1:

The top half of the figure shows an application server with an external Web server. The bottom half of the figure shows an application server with the Web server bundled in. Note that the only difference is in the packaging. In the latter case, the Web application server vendor bundles a Web server with his or her product. Such products should still be able to substitute their proprietary Web server with a third-party Web server.

Recipe for a Web Application Server
Let's take a look at what it takes to cook up a typical Web application server. As we've seen earlier in this article, a Web application server needs a Web server and an application execution environment. The application execution environment hosts business objects. The functionality of these business objects is exposed outside the application server in the form of programming interfaces. The execution environment itself comprises the following frameworks and services:

  • Object containers
  • Naming/directory services
  • Messaging/event framework
  • Communications framework
  • Security framework
  • Transaction framework
  • Data access framework
Figure 2 illustrates how these frameworks fit in an application server.

Figure 2
Figure 2:

The Web client accesses the business objects of the Web application server via a Web browser. The request is made to the Web server, which forwards the request to the object container using the Naming Framework to find the business object. The Internet client uses a distributed communications protocol such as RMI, IIOP or DCOM (depending on the computing environment) to get to the application server. It also finds the desired object via the Naming Framework. The business objects exist in the context of an object container. Object containers expose the interfaces of the objects to the external world. The Communications Framework is used by the object containers for interobject communications. The application server interacts with other remote systems via the messaging, transaction and security frameworks. Data from the back-end tier is accessed via a Data Access Framework.

Application Server Computing Platforms
In some ways, operating systems can be considered as the "0th" generation of application servers. When life was simpler, the operating system hosted the application and handed computing resources to applications when required. The application developer had a certain degree of control over the execution environment. However, application development required knowledge of system-level programming. This knowledge was not portable — that is to say, application developers had to learn about completely new systems if they changed the computing platform. Application servers abstract application developers from the gory details of the operating system's execution environment. They do this by managing the interaction with the operating system for using system resources and offering these resources as application server services. Desired features of the runtime environment such as load balancing, fault tolerance, persistence and so on are offered by application servers for optimally running the application. Since application servers abstract the platform or operating system, one logical way to classify them is on the basis of the computing platform in which they execute.

Currently, there are two camps in the application server industry — the Windows (Microsoft) camp and the Java camp. Note that here we refer to the Java software platform, not Java the programming language, and so the comparison is between software computing platforms. The Windows platform enforces the operating system and corresponding hardware. On the other hand, the Java platform is a virtual platform that enforces the programming language but can run on a variety of operating systems and hardware platforms. In both cases, the application servers offered by these platforms meet the criteria of abstracting the application hosting details from the application providers.

Web and Java Application Servers
As mentioned earlier in this article, the class of application servers that comprises a component of Web architectures comes under the umbrella of Web application servers. Simply put, Web application servers serve application services over HTTP (Hypertext Transfer Protocol). A Web application server is always associated with a corresponding Web server. Today's distributed applications that leverage the features of the Sun Microsystems Java platform often base their architecture on one or more Web application servers. Similarly, when someone mentions application servers today, it's more than likely that they're talking about application servers that support the Java platform. Such application servers are often called "Java Application Servers." The application servers discussed in previous articles are all either based on the Java platform or integrate with the Java platform.

Java Platform Application Servers
Java application servers are a by-product of Java's increasing presence in server-side middleware and the definition of Java Enterprise APIs by Sun Microsystems in collaboration with its industry partners. Java Enterprise APIs define enterprise-level services for server-side deployments. As described earlier in this article, the appearance of application servers in the market dates back to when the concept of multitiered computing became popular. These application servers provided a hosting environment for middleware components. Before the stabilization of the Java Enterprise APIs, however, the definition of middleware components for a ubiquitous software platform was not uniform across operating systems. So the application servers were operation-system—specific.

Consequently, each of these application servers provided middleware services in a proprietary way, making portability and reuse of the components difficult. The emergence of the Java Enterprise APIs has enabled the definition of a standard architecture for middleware components composed of business objects. This architecture clearly defines well-formed interfaces between the application server's object containers and the objects or components themselves. In Java this is made possible by:

  • A standards object model (EJB) for designing business objects
  • Uniform APIs for accessing the business objects (remote interfaces)
  • Container APIs for interacting with the vendor's mechanisms for accessing system resources (home interfaces)
  • APIs for finding the business objects (JNDI)
  • Standard means of accessing these components through a distributed protocol (Java servlets, RMI)
  • Standard APIs for connecting to back-office data sources
The above elements form the components for a basic Java application server. This is illustrated in Figure 3.

Figure 3
Figure 3:

Note that this is a version of Figure 2 with Java-specific technologies. (Not all of the technologies that play a part in Java application servers are shown in the figure.)

Trading Places
The application server market is evolving rapidly. In a couple of years, the survivors of the current "app server wars" will emerge. Java has been instrumental in getting application servers the attention that they're currently receiving — because Java adds hardware platform independence for the implementation and use of application servers, vastly enhancing their scope. As J2EE and the EJB model matures and industrial-strength applications are developed using this model, Java application servers will continue to play a crucial role in the development of enterprise-level distributed applications.

Author Bio
Ajit Sagar is a senior solutions architect in a firm specializing in B2B market places. A Sun-certified Java programmer with nine years of programming experience, including three in Java, Ajit holds an MS in computer science and a BS in electrical engineering. [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.