Documentation?

Brad Fitzpatrick brad at danga.com
Wed Apr 2 00:23:41 UTC 2008


On Tue, Apr 1, 2008 at 3:51 PM, Mark Smith <smitty at gmail.com> wrote:

> Round robin doesn't really solve anything in a web environment unless
> you can guarantee that all requests cost the same to process.  I don't
> know that I've ever seen a situation in which I thought it'd be a good
> idea.  (Not to say they don't exist!  Just they seem rare.)


Yeah, +1 to what Mark said.

Perlbal's load balancing is "if you're free, you get a request".  And then
just keep a bunch of connections open to the backends.

When an incoming request comes in, and there's no free connection, a new
connection to a backend is started.  But IMPORTANTLY:  that request is NOT
TIED to that initiated connection.  If another backend connection frees up
in the meantime, that now-free connection gets the request that initially
started the other connection.  And then the second connection finally sets
up, and finds nothing to do, it'll just chill for awhile and maybe get
something later.

It's really pretty much perfect load balancing, as long as you don't set
your MaxClients (in Apache speak) higher on your backends than they're
actually capable of.  If you're at 100% CPU non-stop on your backends, turn
down their MaxClients.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.danga.com/pipermail/perlbal/attachments/20080401/aef9597a/attachment.html 


More information about the perlbal mailing list