tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Sandy McArthur <Sa...@McArthur.org>
Subject Re: Questions on mod_jk, session affinity, etc
Date Wed, 10 Nov 2004 05:36:21 GMT
On Nov 9, 2004, at 10:00 PM, Jess Holle wrote:

> is there any hope/possibility/interest of trying to balance the number 
> of active sessions per Tomcat instance (i.e. sending new requests to 
> the instance with the fewest active sessions)?

We (UF, I cannot claim to represent the tomcat devs) are happy with a 
simple round robin distribution for new requests. We have 8 tomcat 
clones for simple load balancing and given enough users it all evens 
out. We've gutted the existing balancing code in mod_jk because it was 
broken and put in our own more simple algorithm that doesn't do load 
factors. Hopefully the balancing code back ported from the mod_proxy 
efforts will do the trick and we can ditch our own stuff.

Anyway, trying to be too smart in sending new requests to clones with 
the fewest number of sessions would probably create this weird flow 
where new users gravitate to the same clone as a batch of users 
sessions expire.

Even if that isn't the case, it's in our interests to separate new 
sessions between clones. Typically for us the first request a user 
makes after login is the most cpu/time intensive because we need lookup 
extended info about the user and generally setup their session.

-- 
Sandy McArthur

"He who dares not offend cannot be honest."
- Thomas Paine

Mime
View raw message