FastCGI Request Processing

The documents on www.fastcgi.com are not clear about this (to me), so I hope someone can give me a definitive answer.

I wrote a FastCGI application in C ++ to do a crunch. When the application first loads (when apache starts), it performs some caching of MySQL data into a vector, which takes about a minute (therefore, using FastCGI instead of CGI ;-)). He then waits for a request to start crunching the number.

Usually the user makes a request, the FastCGI application starts without problems and returns the correct data. However, I'm not sure what happens when multiple requests are triggered at about the same time. Does FastCGI launch these requests and wait for the previous launch to complete before responding to the next request? Or is FastCGI processing requests in parallel? Can you customize this, and are you customizing it in your application or in apache configurations? What is the default?

My application only implements

while(FCGX_Accept( &in, &out, &err, &envp)>=0){}

and executes the number curled up inside the while loop.

Appreciate any help, welcome bros.

+3
source share
1 answer

-, FastCGI, , , Apache . , .

+4

All Articles