WSGI Module
Jurie-Jan Botha
juriejanbotha at gmail.com
Wed Sep 1 20:55:34 MSD 2010
> It is quite simple.
> For each request whose location is handled by the wsgi module, an user
> defined Python function is called.
>
> When the Python function is called, an entire process is blocked until
> the function return; Nginx process will be not be able to serve other
> requests.
I see. I also read that Apache's mod_wsgi has a mode where it
dedicates
processes to running the python requests. So if you include this
option then
that won't be a problem any more.
> The suggested usage is to *always* (unless you know what you are doing)
> place a "normal" Nginx instance as frontend, and put the Nginx instance
> with the WSGI module as a backend, using the http proxy module.
>
> The only thing similar is the Perl module, that allows you to execute
> Perl code inside Nginx.
> But the intended usage it to execute small scripts; the intended usage
> of the WSGI module is, instead, to execute WSGI applications.
I'll keep on running my Nginx and FCGI combination then. The idea
of hooking up Nginx straight to a python file with an WSGI app inside
was very alluring to me, but I'll just have to wait. I don't really
want
to switch to Apache.
More information about the nginx
mailing list