From: Jay Levitt Date: 2007-10-04T05:20:11+09:00 Subject: Re: Recent Criticism about Ruby (Scalability, etc.) On Thu, 4 Oct 2007 03:06:03 +0900, Gary Wright wrote: > I admit to being puzzled by the general fascination > with threads (native or not) for solving scaling > problems. > > Good old processes have always seemed like a reasonable > way to partition problems and take advantage of > concurrency opportunities due to waiting on I/O > (single processor) or the parallel nature of a > CPU-bound calculation (multi-processor). Ayup. At AOL, when we grew beyond the abilities of sendmail to handle incoming mail from the Internet, we rolled our own SMTP server. It had the following characteristics: - Non-threaded, event-driven main loop - Asynchronous DNS calls - Asynchronous database calls - No disk I/O other than logging (which itself might have been async, I forget) - Therefore, no process ever waited on anything The best configuration? One process per CPU. -- Jay Levitt | Boston, MA | My character doesn't like it when they Faster: jay at jay dot fm | cry or shout or hit. http://www.jay.fm | - Kristoffer