POST OF THE DAY
BEA Systems, Inc.
BEA Software

Format for Printing

Format for printing

Request Reprints

Reuse/Reprint

By Conehead
October 8, 2001

Posts selected for this feature rarely stand alone. They are usually a part of an ongoing thread, and are out of context when presented here. The material should be read in that light. How are these posts selected? Click here to find out and nominate a post yourself!

________________

ECOaccount wrote:
I am having a hard time grasping just what exactly Application Server software is. Can anyone direct me to an online or offline resource that provides a decent example, perhaps a simple example, that even a layman like me can understand.

From what I understand it is like an operating system for businesses trying to run numerous applications on their networks. Does it act like "middleware"?


Yes, application server software is traditionally considered middleware.
It is often compared to any operating system because it doesn't do anything on its own, but instead provides services to developers. Rather than giving a detailed feature list of services provided by an application server, let me give a simple scenario.

Say I know how to write a program that can predict the tomorrow's closing stock price for any given stock. Given the obvious value of this program, how can I offer it to the world?

Well, without an operating system, I can't do anything with my program. Traditionally, a developer would pick an operating system and use tools written by that operating system vendor to make the program work on that operating system. If I picked Windows as my operating system, I might use Microsoft Visual C++ so that my program would work on Windows. Or if I picked Linux as my operating system, I might use the GCC compiler to compile my program for Linux.

But this has its disadvantages. While most home users have Windows, a measurable minority use Mac or Linux. And on the servers used by businesses there are still dozens of active operating systems. (AIX, HP/UX, OS/390, Solaris, Windows2000, and many others.)

So Sun invented the Java platform. By inventing a special layer between the operating system and the program called a JVM, a program written in Java can run on any operating system that has a JVM. (Which is just about every major operating system.) So instead of writing my stock market program for just one operating system, I can now write a Java program that will work on Windows, Mac, Linux, Solaris, and just about every other computer in the world.

But imagine that in order for my program to work, it needs to have access to a high bandwidth connection to a historical database of stock quotes. Since most people don't have access to that kind of information I decide that my users will access my application over the web. I'll install the program on a big Sun UNIX server and charge people to access it with their browsers.

In order to do this, I need to use what's called a web container. Web containers act like a bridge between webservers and Java code. They manage the incoming requests so that Java code only has to process a reasonable number at a time. They also provide an API so that developer's can interface with browsers easily. The webcontainer uses these API's to allow developers to easily interpret requests and generate web page results.

There are dozens of web containers, including BEA's low end version of WebLogic, WebLogic express. And because Sun controls the specifications for what a web container must do, all web containers are more or less interchangeable. I can take my program and run it on Sun's iPlanet Web Server (which has a built-in web container), or I can run it on BEA's WebLogic Express. It depends on who gives me the best price, is the most reliable, and who gives me the most features above and beyond the required features. (Usually called value-add features.) Also, since my program is still Java, it can run on any operating system that the web container is available on.

But now imagine that I want to sell my program as a plug-in component to other companies that want to integrate it with their own programs. I will want to package my application as what is called an Enterprise Java Bean (or EJB). By doing this I also get access to many other built-in features of EJB's:

* Transactions: the ability to ensure that my updates are all or nothing. That I don't leave databases or backends in a half-finished state. Important when you are working with money, for example. when doing a money transfer you never want to add money to account B, until you're sure that you've removed it from account A.
* Remotability: the ability to access my program using a protocol called RMI.
* Declarative Security : the ability to have the container make the decisions about who is able to do what, instead of having to program it myself.
* Deployment Descriptors : the ability for people who use my code to configure it before they use it.

A lot of these features sound very boring or esoteric, but they are very important to companies that are writing the programs that run their businesses. (My stock forecasting program example starts to break down here because it is too simple to need many of these features.) Application servers also tend to offer features that simple web containers do not have. Features like the ability to loadbalance across multiple servers and "cluster" servers so that no information is lost even if one of those servers breaks or is shut down.

In order to use these features, I write my program to the J2EE API's. (Which are also controlled by Sun.) My customers can then use any J2EE application server to run my plug-in application component (EJB).

This is what WebLogic Server does. Like an operating system, it gives my code a place to run. And like an operating system it has an API that allows developers to interact with it. Unlike an operating system, the API is defined by someone else (Sun). And the API that it provides is much more sophisticated than an operating system API. An operating system API just provides mechanisms to do simple things like save a file or open a dialog box on the screen. For example, the J2EE application server API provides the ability to conduct complex interactions with other programs and databases.

DISCLAIMER:
I am long BEA. I also work for Sun, which is both a partner and competitor of BEA.

__________________

TMF Money Advisor
Got money questions? Your answers are just a phone call away! TMF Money Advisor puts you in touch with an objective Financial Planner whenever you need it.