Evolution of Application Servers

An application server is designed to make it easier for developers to focus on developing the business logic in their applications (usually through components) and to develop three-tier applications. Application servers connect database information (usually coming from a database server) and the end-user or client program (often running in a Web browser) with sophisticated features like Connection Management, Transaction Management, and Security Management. But application servers are not limited to these features. Depending on their usage, application servers also need to be scalable and robust. To address these requirements, many application servers offer additional features, such as clustering and failover, load balancing, and so on. The following sections describe some of these application server features.

Business Logic Components

Components are the "building blocks" of applications. Business logic components are the pieces of code written by a developer that perform business functions such as validation or calculations on the data or accessing and processing data from the database. The application server provides a well-defined environment for developing and deploying application business logic components. Moreover, the application server provides features such as resource reusability, transactions, security, and so on to the application components, thereby removing the burden on the developer to code these in the components.

Connection Management

Connecting to a database for accessing enterprise data is an expensive operation for an application server. The application server minimizes repetitive opening and closing of database connections by application components by maintaining a pool of connections that is shared among all the application components. Whenever a database operation is required by any application component, it obtains a connection from the application server connection pool. All database activities (such as retrieving or persisting data) are carried out using this connection. At the end of the operation, the connection is returned to the server pool.

Transaction Management

A transaction is a unified series of steps in a program and is an indivisible unit of work. Transactions are sequences of operations on resources operations such as read, write, or update that transform one consistent state of the system into a new consistent state. Data changes occurring as a result of transaction execution can be either committed after a successful execution or rolled back in case of a system failure. Transaction management involves maintaining the integrity of data manipulated by transactions during system failures. Because multiple application components and resources participate in a transaction, it is necessary for the Transaction Manager within an application server to establish and maintain the state of the transaction as it occurs. This is done using a transaction context an association between the transactional operations on the resources and the components invoking the operations.

Security Management

Application servers provide the ability to define authentication information, access control, and an authentication mechanism to enable access to resources within or outside the application server. Application servers also have methods to reuse the existing security and authentication mechanisms, such as the operating system authentication, digital certificates, and so on.

Component Instance Pooling

High-end application servers also provide advanced features such as component instance pooling. Because component creation or instantiation is an expensive task, servers provide component pooling (similar to connection pooling) to provide better performance.

Load Balancing and Fail-safe Mechanisms

Quite often, to handle a huge load of user requests, multiple application servers are grouped together, often on different machines, with a single point of entry for incoming user requests. This is called clustering. Clustering enables harnessing of the processing power of multiple machines to service user requests. Load balancing involves the use of additional software, such as a request dispatcher that routes requests to the least-busy server that it identifies in the cluster. Thus, it enhances scalability of the deployed applications by ensuring a good response time for user requests by the application server cluster. Normally, load balancing is supported by sophisticated application servers with specialized software.

Fail-safe mechanisms in a server cluster consist of rerouting incoming requests to another application server in the cluster in case a server in the cluster fails. This failure can be either a software failure or a hardware failure. Advanced fail-safe techniques, such as maintaining the session integrity across servers in a cluster, are also provided by some application servers. This is done by storing the session data of all servers in the cluster in a persistent storage such as a database.

Declarative and Programmatic Approaches

Application components executing within an application server utilize the features you just studied in two ways:

  • Declarative Deployment tools supplied with the application server are used to define and set up the parameters and information for connection management, transaction management, security, and so on. The developer is free to focus on developing the application. The downside of this is that a developer is restricted to using proprietary tools and, in some cases, proprietary mechanisms of deployment.

  • Programmatic The developer includes the code for connection handling, transaction, and security/authentication within the application code. With this, a developer has control over invoking and using these features, with the application server reduced to providing adapters for this. The downside is that clarity of code is reduced, creating inflexible and difficult to maintain components.

Now you will take a look at what WebLogic Server 7.0 offers.



Sams Teach Yourself BEA WebLogic Server 7. 0 in 21 Days
Sams Teach Yourself BEA WebLogic Server 7.0 in 21 Days
ISBN: 0672324334
EAN: 2147483647
Year: 2002
Pages: 339

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net