[Mongrel] Design flaw? - num_processors, accept/close

Zed A. Shaw zedshaw at zedshaw.com
Tue Oct 16 01:42:00 EDT 2007

On Mon, 15 Oct 2007 12:51:47 -0400
"Evan Weaver" <evan at cloudbur.st> wrote:

> Ah, no, they are only marked operational until the retry timeout is
> elapsed. So I guess if you had extremely small timeouts in Apache and
> Mongrel both it would work ok.
> Someone else respond, because clearly I don't know what I'm talking about. :)

I'm confused, isn't the point of a balancer that it tries all available backends multiple times before giving up?  If m_p_b is aborting on the first accept that's denied then it's broken.  It should try every one, and possibly twice or three times before giving up.  Otherwise it's not really a "balancer", but more of a "robinder".

Also, the proposed solution probably won't work.  If my crufty late night brain is right, this would mean that the backend will attempt a connect to a "sleeping" mongrel and either have to wait until the TCP timeout or just get blocked.  Eventually you're back at the same problem that you have tons of requests piling up, they're just piled up in the OS tcp stack where no useful work can be done.  At least piling them in mongrel means some IO is getting processed.

And, it sounds like nobody is actually trying these proposed solutions.  Anyone got some metrics?  Tried Lucas Carlson's Dr. Proxy yet?  Other solutions?  Evented mongrel?

Zed A. Shaw
- Hate: http://savingtheinternetwithhate.com/
- Good: http://www.zedshaw.com/
- Evil: http://yearofevil.com/

More information about the Mongrel-users mailing list