I am more interested to know in which situations it's a bad idea to use CGI ?
I am more interested to know in which situations it's a bad idea to use CGI ?
As one of the previous comments mentions, operating systems do a better job of caching now, so there's less overhead there. Fast CGI also gets rid of that problem by running your CGI script as a single persistent process.
CGI may not be the best solution for really huge applications that have hundreds of routes or very complex business logic.
That said, it's still incredibly useful. I use it on some personal sites, and it's nice to know that I can drop it into any new site without having to worry about dependencies and without having to do much configuration. It's simple and it works. Those are two big pluses in a world where things have gotten so complex.