Perlbal 1.37

Brad Fitzpatrick brad at
Mon Aug 29 20:52:21 PDT 2005

New Perlbal release, leading up to 1.40:

This version has been in production on LiveJournal for 5 or 6 days
now.  (along with XS headers, version 0.18)

Notice the huge number of changes from 1.36 to 1.37:

1.37 (beta for 1.40) 2005-08-29

    -- "use <name>" command to set the direct object for future commands

    -- AccessControl plugin to allow/deny by default or on IPs or

    -- ClientManage could spin in its inherited event_write, causing
       99.9% cpu usage.  Bug is arguably Danga::Socket's, but also
       ours because it's documented what we should do and we didn't.
       The fix is to shut down watching writability when we're done

    -- make accept_client and its callers deal with the possibility
       that accept_client fails not because the backend is bogus, but
       because the client is.  so now accept_client can close the
       client and callers have to be aware of that.

    -- after running this version on production on for
       a bit, we discovered some cases that we'd flag as should never happen,
       but actually do, so updated the comments and behavior to
       do the right thing and not just crash with an assertion.

    -- fix misspellings of trusted_upstream_proxies that didn't
       come along for the renaming ride earlier

    -- webserver mode now ignores URL arguments when looking up

    -- remove warnings accessing undefs in ranges and vhosts

    -- new --version and --help flags.  also a usage message on bogus
       options (or when --help).  props to Jacques Marneweck
       <jacques at> for the help and motivation.

Known issues:

Two warnings come up occasionally (every couple minutes) that should never happen.  They used to crash the server, but for now they just complain to stderr and close the respective connections.  These two warnings are:


INTERNAL ERROR: event_read called on when we're expecting no more bytes.  len=286, content=[GET /userpic/33753813/1028465 HTTP/1.0
Accept-Encoding: gzip, deflate
        Perlbal::ClientProxy::event_read('Perlbal::ClientProxy=ARRAY(0x8d38778)') called at /usr/share/perl5/Danga/ line 476
        Danga::Socket::EpollEventLoop('Perlbal::Socket') called at lib/ line 999
        eval {...} called at lib/ line 997
        Perlbal::run() called at /usr/bin/perlbal line 102



Undef client_ip (Perlbal::ClientProxy=ARRAY(0x8d261e0)) in assign_client.  Closing. at lib/Perlbal/ line 177.

I'd like to get those fixed before a 1.40 release.

I also plan to do some profiling to see if there are any obvious
opportunities for performance improvements, and to check that I didn't
introduce any new performance problems.

- Brad

More information about the perlbal mailing list