Introduction
IBM® WebSphere Application Server V8 (hereafter Application Server) is the first JEE 6 certified enterprise application server. It supports the latest technology such as EJB 3.1, Sevlet 3.0, JPA 2.0, and JAX-WS 2.2 as well as the OSGI, SCA, Batch and CEA programming models. Moreover, Application Server performance has been improved from 20-26% compared to version 7 and about 85% compared to version 6. It also includes new features for operational efficiency, security and speed of development and delivery of applications to enterprise platform.
WebSphere eXtreme Scale (hereafter eXtreme Scale) is a high-speed distributed caching solution, which can be used to reduce the application path length or the distance that data has to travel and provides a range of scaling requirements from simple-in process caching to very complex distributing caching requirements and can be used in variety of caching requirements such as side cache, HTTP session cache, inline backend cache as well as for extreme transaction processing. It is very quick for development and deployment and provides high ROI, and supports a variety of application environments such as Java SE, Java EE, .NET and REST .It can be configured in standalone or along with Application Server.
When eXtreme Scale is integrated with Application Server, it can use all the non-functional features provided by Application Server for high availability: failover, transactions, security etc. All the configurations required for caching are provided by the admin console itself. A single console can be used to manage and configure both the Application Server and eXtreme Scale environments.
HTTP session management
Session management is the technique used by web developers to enable the stateless HTTP protocol to support session state. For example, after a user has authenticated to the web server, subsequent HTTP request (GET or POST) should not cause the web server to ask for the account and password again. An HTTP cookie can be used to maintain session state. The session information is stored on the web server using the session identifier called session ID, which is generated as a result of the request from the user running a web browser.
When multiple web servers must share knowledge of session state, which is typical in clustered environments, session information must be shared between the cluster nodes that are running the web server. Session information can be shared between nodes by using memory replication, by storing session information in a database, or by storing the information in a distributed cache. WebSphere eXtreme Scale provides support for a distributed cache management solution.
The eXtreme Scale HTTP session manager provides session replication capabilities for an application. The session replication manager works with the web container's session manager to create HTTP sessions and manage the life cycles of HTTP sessions that are associated with the application. These life cycle management activities include the invalidation of sessions based on a timeout or an explicit servlet or JavaServer Pages (JSP) call and the invocation of session listeners that are associated with the session or the web application.
When eXtreme Scale manages HTTP sessions, the session manager persists its sessions in an ObjectGrid instance. This instance can be a local, in-memory instance or a fully replicated, clustered, and partitioned instance. The latter provides HTTP session failover support when application servers are shut down or end unexpectedly.
eXtreme Scale usage scenario's for session management
Usage scenarios include:
- Environments that use application servers at different versions of Application Server.
- Deployments that use application servers from different vendors.
- Environments that require the user to persist sessions with higher quality of service levels and better guarantees of session availability during server failover
- Environment where session affinity cannot be guaranteed or environments in which affinity is maintained by a third-party load balancer and the affinity mechanism must be customized to that load balancer.
- Environment that must offload session management and storage to an external Java process
- To enable session failover between cells
Prerequisites
The example described in this article uses the PlantsByWebSphere sample application (see Figure 1). For this example, the following must be installed:
- WebSphere Application Server V8
- WebSphere eXtreme Scale V7
- The PlantsByWebSphere sample application
Figure 1 The PlantsByWebSphere application on WebSphere Application Server V8
Installation of WebSphere eXtreme Scale
Question: should the following be plural (same servers rather than same server)?
You must install eXtreme Scale on the same server as Application Server. On Windows systems, it can be installed using the install.bat script. On UNIX and Linux platforms, the install.sh script can be used for installation. For this example, we specify C:\WebSphere8\AppServer as the installation directory.
Figure 2: Specifying the installation location for eXtreme Scale
You also need to specify which eXtreme Scale features to install. See Figure 3.
Figure 3: Selecting features to install
During installation, you can augment Application Server profiles with eXtreme Scale features (see Figure 4). Any existing Application Server profile can be augmented, or you can create new profiles with eXtreme scale features. For this example, we augmented the existing profile AppSrv01.
Figure 4: Augmenting profile for eXtreme Scale
After installation of eXtreme Scale, when the profile is started, confirm the installation of eXtreme Scale by accessing the AppSrv01 profile – represented by server1 application server on the admin console (see Figure 5).
Figure 5: Application Server profile with eXtreme Scale features installed
Configuring an application for HTTP session management
All web applications installed on Application Server can now use the eXtreme Scale features. In our example, we configure the sample application PlantsbyWebSphere for eXtreme Scale HTTP Session management.
From the Application Server admin console, select Applications –> WebSphere enterprise applications. This lists all applications installed on Application Server. PlantsbyWebSphere is listed as pbw.ear in the installed applications list. See Figure 6.
Figure 6: Admin console listing the PlantsbyWebSphere application
Select pbw.ear from the application list. All the properties that can be configured for the application are listed, as shown in Figure 7. To configure HTTP Session management for the application, Select Session Management under Web Module Properties.
Figure 7: Configurable properties for PlantsbyWebSphere
When an Application Server profile is augmented with eXtreme Scale, a new option, eXtreme Scale session management settings, is shown on the Session management configuration page under Additional Properties.
Figure 8: Configuring HTTP Session Management
In the eXtreme Scale session management settings page, select Embedded eXtreme Scale data grid to use the eXtreme Scale instance installed on the server (see Figure 9). When you select this option, PlantsbyWebSphere uses the caching flexibility provided by eXtreme Scale to manage HTTP Sessions. If you browse through the PlantsbyWebSphere application, you notice the performance improvement. The magnitude of the performance improvement can be calculated by using any performance benchmarking tools.
Figure 9: eXtreme Scale management option for session management
Conclusion
The distributed caching solution provided by WebSphere eXtreme Scale can be integrated along with latest version of WebSphere Application Server for HTTP session management. This HTTP session management improves application performance signficantly. A single admin console can be used for managing Application Server and eXtreme Scale for making configuration changes.
Resources
WebSphere Extreme Scale 7 Info center
http://publib.boulder.ibm.com/infocenter/wxsinfo/v7r0/index.jsp
WebSphere Extreme Scale Solutions Architecture Redbook
http://www.redbooks.ibm.com/abstracts/redp4602.html
WebSphere Application Server 8 Info center
http://publib.boulder.ibm.com/infocenter/wasinfo/v8r0/index.jsp
WebSphere Application Server Features and Benefits
http://www-01.ibm.com/software/webservers/appserv/was/features/
댓글 없음:
댓글 쓰기