optimizing worker processes usage
manlio_perillo at libero.it
Mon Sep 24 15:45:54 MSD 2007
Doing some tests with mod_wsgi, I have found some "problems" with worker
I have worker_processes set to 2 (and I have a Dual Core CUP).
When a WSGI app "quickly" return a chunk of data (and write it at once),
nginx seems to use only one process, serializing all the requestes.
How can I optimize the code so that nginx can use all the worker processes?
I have found that if the WSGI app calls, as an example, sleep(0.01),
then nginx will use all of its worker processes (but this slow down the
response time: 159.52 req/sec vs 2848.19 req/sec)
Thanks Manlio Perillo
More information about the nginx