2 ms·
I tried the "run a C program as cgi" on the web. Request per second per server dropped significantly. Later converted those into fcgi and throughput increased
by habibur 4y ago
I tried the "run a C program as cgi" on the web. Request per second per server dropped significantly.
Later converted those into fcgi and throughput increased drastically, like an increase of 10 times over previous.
But fcgi is a little bit tricky as your memory and resource leaks will accumulate, and if your program crashes, it will fault on subsequent requests too, and not just that one request as happens in cgi.
- samus 4y agoThat part has an easy infrastructural solution: a TCP loadbalancer in front that switches backend every X days, and two backend processes that are restarted after the other took over. Can be on a single machine if high availability is not a concern.