I'm trying to understand Nginx+PHP scalability running Windows with, lets say, 100 requests doing a medium-term operations.
Analyzing source code I saw:
-
Nginx start a spawns itself several times depending on
configuration and/or server processors count. -
Altough it uses I/O completion ports, each worker only creates
one thread to handle requests. -
When a PHP request is done, Nginx communicates with PHP using FastCGI
At this point, although NGinx can continue scaling, I cannot see in standard PHP fastcgi sapi code that scales using multiple threads/processes and completion ports.
For unix/linux, PHP-FPM come to solve the problem because it forks child processes to complete tasks altough not sure about the performance.
But back into Windows, still in PHP-FPM, I don't see specific code to mantain the whole webserver performance high.
Is there an alternative for Windows? Is something wrong in my research?
Best Answer
The scalability of nginx on Windows is limited, so it's not a recommended platform for a production web site.
From the nginx web site: