history of Nginx

Igor Sysoev is at rambler-co.ru
Wed May 7 23:33:57 MSD 2008

On Wed, May 07, 2008 at 12:32:38PM +0200, Manlio Perillo wrote:

> Igor Sysoev ha scritto:
> >On Sun, May 04, 2008 at 12:21:13PM +0200, Manlio Perillo wrote:
> >
> >>The next week I will present a talk about my WSGI module for Nginx at 
> >>Pycon Due - http://www.pycon.it/ (an Italian conference dedicated to 
> >>Python), and I would like to talk about the history of Nginx.
> >>
> >>Igor, can you please provide some informations like:
> >>- when did you started Nginx
> >>- why did you started Nginx
> >>- a rationale about the choice of the architecture
> >
> >In spring 2001 I had written Apache mod_accel that is enhanced replacement
> >of mod_proxy. But it was clear that Apache has low scalability.
> >I had read http://kegel.com/c10k.html, had investigated existent servers
> >httpd, boa, etc. and had decided that I need something like these servers,
> >but with SSI, proxy, and cache support. Also it should has flexible
> >configuration like Apache and supports online upgrade and quick log 
> >rotation. I planed it as portable server including native Win32 support 
> >(not
> >Cygwin). Initially I plan to use master process and single worker with
> >several threads.
> >
> What are the difference between the Apache and Nginx multiprocess model?
> Nginx used a master process and all the worker call accept on the same 
> sockets.
> But what about Apache?

Grzegorz's answer is right.

> >[...]
> >>- know limitations with the current architecture
> >
> >Embed interpreters are limited to non-blocking operations.
> >[...]
> >It's difficult to write complex modules those interact with many
> >sources and destinations simultaneously.
> >
> Do you have considered corutines?
> There are some libraries that implement coroutines in C, using POSIX 
> setcontext, longjmp or custom ASM code.

The corutines is almost the same as user-land threads, so every corutine
requires its own stack. It's not easy to say how much stack space should be
reserved. Now it's not a problem in 64-bit world, but in 32-bit world it
was simply impossible to reserve, for example, 40000 128K stacks -
it takes 5G address space.

And also it much easy for me to write and to debug FSM.

Igor Sysoev

More information about the nginx mailing list