[Mongrel] Multiple mongrels for one app

Philip Hallstrom mongrel at philip.pjkh.com
Tue Aug 22 15:37:33 EDT 2006

>> http://rubyforge.org/pipermail/mongrel-users/2006-August/000930.html
>> //jarkko
> So what happens when the mongrel gets more than one request at a time?
> When I run httpref against it, the mongrel process can serve up large
> number of rails pages before it gets bogged down.
> And when it does break, it says "mongrel timed out this thread: too
> many open files".  So it must be doing some threading, even if rails
> isn't threadsafe.
> If it was 1 request per mongrel process, 1 process shouldn't be able
> to serve up very many per second.  httpref tells me its prettty fast
> though.

Search the lists... I don't remember the exact details but basically 
mongrel is threaded... right up till it hands the request off to rails, 
then it locks, does the rails request, gets the response, and goes back 
into threaded mode.

So technically you can't process more than 1 rails request at a time, but 
since many requests are way under a second you get the appearance that you 

Or something like that :)

More information about the Mongrel-users mailing list