Use this task to configure the ObjectGrid-based HTTP session manager
to replace the default HTTP session manager that ships with the Java 2 Platform,
Enterprise Edition (J2EE) server that you are using.
Before you begin
Configure your application to use the ObjectGrid HTTP session manager
after you develop your application, but before deploying the application.
The application must contain web modules that use HTTP sessions as governed
by the J2EE specification. When you switch to using session management over
the ObjectGrid topology, the sessions for this application are served by the
ObjectGrid HTTP session manager and are persisted in the underlying ObjectGrid
server topology.
About this task
Consider
using the ObjectGrid session manager in the following scenarios:
- Your environment is in a classic migration scenario that consists of application
servers that are at different versions of WebSphere Application Server or
WebSphere Extended Deployment.
- Your environment has deployments using application servers that are from
different vendors. For example, you might be developing applications on an
open source application server, but hosting the applications on WebSphere
Application Server. Consider this scenario also when you are moving applications
from staging phase to production phase. You can seamlessly migrate the application
while all HTTP sessions are active and serviced.
- Your environment requires session persistence with higher quality of service
(QoS) levels and better session availability during server failover than the
default session manager.
- Your environment cannot guarantee session affinity, or affinity in your
environment is controlled by a third-party load balancer that needs a customized
affinity mechanism.
- You need to offload the overhead of session management and storage to
an external Java virtual machine (JVM).
- You want session failover in multiple cell environments.
For more information
about the ObjectGrid session manager, see
ObjectGrid HTTP session manager
.
Procedure
- Copy the sessionobjectgrid.jar and ogclient.jar files
from the WebSphere Extended Deployment product into the application servers
that are hosting the new ObjectGrid-based HTTP session management enabled
application.
- If you are using a WebSphere Application Server Version 6.x installation:
Copy the sessionobjectgrid.jar and ogclient.jar files
into the /classes folder. Restart the server.
- If you are using WebSphere Application Server Version 5.x or a third-party
application server: Copy the sessionobjectgrid.jar and ogclient.jar files
into the WEB-INF/lib folder of the deployed application
on the application server file system. You might need to restart the server
and application.
- Modify your application to use the new HTTP session manager over
ObjectGrid. See Modifying an application
to use the ObjectGrid HTTP session manager for more information.
- Deploy your application to the application servers.
- Verify that the objectgrid.cluster.xml file
has been customized according to the details of the ObjectGrid server cluster
and is available at the application Web deployment description location.
- If you are running a remote ObjectGrid server or cluster topology,
start up the ObjectGrid server or cluster.
- Start the application and the application server.
- Start accessing the application with a browser or any other HTTP
client.
Results
The HTTP sessions in your environment are managed by the ObjectGrid
HTTP session manager. The sessions are persisted in ObjectGrid. If an application
server that is serving HTTP requests fails, the on demand router (ODR) routes
those requests to an alternate server.