Re:Web CGI programs aren't particularly slow these days
by markstos on Monday January 08, 2024 @03:11PM
(#38917439)
CGI is a good fit if you don't maintain the server it runs on. You've got a basic "user" account and can just upload a CGI script. For example, you've got a static website and need a simple contact form handler.
Apache had an option to run the scripts as your user, rather than default of "nobody". That allows segmenting the processes of different users on the same server.
Re:Web CGI programs aren't particularly slow these days
by anonacct37 on Monday January 08, 2024 @10:33PM
(#38921964)
No memory leaks (unless you use shared memory).
No weird connection pooling and caching issues or delays in picking up a config change. Every request is a fresh start, enforced by the OS.
Buggy code (like image processing can only crash the current request).
Re:Web CGI programs aren't particularly slow these days
by randomdata on Tuesday January 09, 2024 @12:04AM
(#38922555)
If you avoid writing the simple server you can assert your familiarity with serverless on your resume.
So that's a reason not to not use it; but are there any reasons to use it?
Even in TFA, he demonstrates using a simple Golang CGI binary; but writing a simple Golang server that you pass through as a reverse proxy is just as simple.