When is In-Memory Session Data Replicated on Oracle GlassFish Server v3.1.1 ?
(Doc ID 1354459.1)
Last updated on MAY 31, 2019
Applies to:Oracle GlassFish Server - Version 3.1.1 and later
Information in this document applies to any platform.
In GlassFish 3.1.x, a web application can be configured to use distributed sessions with replicated persistence type, and deployed with --availabilityenabled=true. After this is done the session is replicated between two instances (Ref: GlassFish 3.1 Development Guide) provided Group Management Service (GMS) and network multicast work between the instances.
Observe the following scenario:
- Let say there are two nodes in a GlassFish cluster, n1 and n2.
- The web application is using replicated persistence type and deployed with --availabilityenabled. It is tested that replication works.
- A web session s1 is created in n1 by accessing the web application at n1
- It is observed that the session is replicated to n2. This can be seen by enabling logger "org.shoal.ha.cache.command.level=FINE"
- Next, shutdown n1.
- Now send a another request with session s1, it should land on n2. (due to the load balancer)
- The web session s1 is found on n2.
- Start node n1 and wait for it to start up completely and wait for 2 minutes before going to step 9.
- Shutdown node n2 and wait for it to completely shut down.
- Throughout step 6-9, no new HTTP request is issued
- Now send a HTTP request with web session s1
- Web session s1 is lost in node n1. A new web session is created.
The thing to observe is that web session s1 is lost.
To view full details, sign in with your My Oracle Support account.
Don't have a My Oracle Support account? Click to get started!
In this Document