users@glassfish.java.net

Re: Two node cluster in-memory session replication not working in 2.1.1.b31g

From: Shreedhar Ganapathy <shreedhar.ganapathy_at_oracle.com>
Date: Wed, 26 May 2010 15:09:15 -0700

On 5/26/10 3:04 PM, glassfish_at_javadesktop.org wrote:
> Thanks for reviewing.
>
> I thought the clustering replication was not dependent at all with an LB in front of the nodes, could you please clarify this.
>
When instances are on the same machine, as you move from one instance to
another, the hostname stays the same, and as a result the cookie sent by
the browser includes the same bits of information including hostname,
session id, etc as the other instance that originally served the
request. So you can see replication working.

When you have instances on more than one machine, and when you point
your browser client from one server on one machine to another server on
another machine to verify session replication, the browser sent cookie
cannot be used by the container to retrieve the session from the second
server as the hostname parameter would have changed.

Fronting the two instances with a load balancer would remove this
problem as the LB would do the required translation when the request
fails over to the other instance on the second machine. You will have to
stop the instance from which the initial request was responded to, in
order to let the LB fail over to the second instance.

Hope this is helpful.

> I will setup a Load Balancer in front, run the test again and then bring down one box to see if the fail over to the other node carries with it the session in order to verify your suggestion. I will post my results as soon as I am done.
>
> Thank you.
> [Message sent by forum member 'chinesco']
>
> http://forums.java.net/jive/thread.jspa?messageID=471596
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe_at_glassfish.dev.java.net
> For additional commands, e-mail: users-help_at_glassfish.dev.java.net
>
>