users@glassfish.java.net

Re: how to setup loadbalancing on glassfish?

From: Kshitiz Saxena <Kshitiz.Saxena_at_Sun.COM>
Date: Thu, 24 Apr 2008 21:52:32 +0530

Glassfish cluster provide high-availability. If a single instance
crashes, there will be complete session loss. You can enable session
replication within cluster, making your system highly available.

Load-balancer apart from basic load-balancing, stickiness and fail-over
provides many other features like application/instance quiescing,
idempotent url etc.. Please take a look at load-balancer features
available @ http://docs.sun.com/app/docs/doc/819-3679/abdhs?a=view

Thanks,
Kshitiz

glassfish_at_javadesktop.org wrote:
> Yes the architecture is LVS->HTTPD->Glassfish.
>
> Glassfish servers don't need to run in cluster mode, LVS can handle so called connection stickiness.
> When a connection is made and it is decided which real server should handle it, a template is created for the given source IP (with configurable netmask). After connection is closed and new created, LVS finds the template, and sends packet to the server that handled the original request. Connection stickiness timeout is configurable. You would normally set it to your session timeout.
> If the original server fails and a packet arrives, it is not sent to the dead server but to a new one - in this case user will probably think he was logged out.
>
> Heartbeat ensures the balancer IP address moves to another backup balancer when master dies.
>
> LVS can also use so called firewall-marks (by iptables), which are marks in packets that are visible only in the server. So you can mark TCP port 80, 443, some other TCP port your app needs, some UDP port, with the same mark and all that transfer will go to the same real server.
> [Message sent by forum member 'jarol1' (jarol1)]
>
> http://forums.java.net/jive/thread.jspa?messageID=271013
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe_at_glassfish.dev.java.net
> For additional commands, e-mail: users-help_at_glassfish.dev.java.net
>
>