monitor: switch to non-blocking HTTP device checks
Net::HTTP::NB is usable with Danga::Socket and may be used to
make HTTP requests in parallel.
The new connection pool supports persistent connection pooling
similar to LWP::ConnCache. Total connection capacity is
enforced to prevent out-of-FD situations on the workers.
Unlike LWP::ConnCache, MogileFS::ConnectionPool is designed for
use with concurrent, active connections. It also supports
queueing (when any enforced capacity or system limits are
reached) and relies on Danga::Socket for scheduling queued
connections.
In addition to total capacity limits, MogileFS::ConnectionPool
also supports limiting concurrency on a per-destination basis to
avoid potentially overloading a single destination.
Currently, we limit ourselves to 20 connections from a single
worker (matching the old LWP limit) and also limit ourselves
to 20 connections to a single host (again matching our previous
LWP behavior).