httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jess Holle <>
Subject Re: mod_proxy / mod_proxy_balancer
Date Wed, 06 May 2009 08:35:57 GMT
Rainer Jung wrote:
> In most situations aplications need stickyness. So balancing will not
> happen in an ideal situation, instead it tries to keep load equal
> although most requests are sticky.
> Because of the influence of sticky requests it can happen that
> accumulated load distributes very uneven between the nodes. Should the
> balancer try to correct such accumulated differences?
> Other applications are memory bound. Memory is needed by request
> handling but also by session handling. Data accumulation is mor
> eimportant here, because of the sessions. Again, we can not be perfect,
> because we don't get a notification, when a session expires or a user
> logs out. So we can only count the "new" sessions. This counter in my
> opinion also needs some aging, so that we won't compensate historic
> inequality without bounds. I must confess, that I don't have an example
> here, how this inequality can happen for sessions when balancing new
> session requests (stickyness doesn't influence this), but I think
> balancing based on old data is the wrong model here too.
An ability to balance based on new sessions with an idle time out on 
such sessions would be close enough to reality in cases where sessions 
expire rather than being explicitly invalidated (e.g. by a logout).

Of course that redoes what a servlet engine would be doing and does so 
with lower fidelity.  An ability to ask a backend for its current 
session count and load balance new requests on that basis would be 
really helpful.  Whether this ability is buried into AJP, for instance, 
or is simply a separate request to a designated URL is another question, 
but the latter approach seems fairly general and the number of such 
requests could be throttled by a time-to-live setting on the last such 
count obtained.

Actually this could and should be generalized beyond active sessions to 
a back-end health metric.  Each backend could compute and respond with a 
relative measure of busyness/health and respond and the load balancer 
could then balance new (session-less) requests to the least busy / most 
healthy backend.  This would seem to be *huge* step forward in load 
balancing capability/fidelity.

It's my understanding that mod_cluster is pursuing just this sort of 
thing to some degree -- but currently only works for JBoss backends.

Jess Holle

View raw message