Re:Web CGI programs aren't particularly slow these days
by rootusrootus on Monday January 08, 2024 @12:06PM
(#38914955)
It's a good point, though, for the many developers who are writing software for a limited audience, such as internal tools. Can't be reached by HN, can't be hugged to death.
Re:Web CGI programs aren't particularly slow these days
by j45 on Monday January 08, 2024 @12:36PM
(#38915354)
Speed of iteration is most important for most development in the beginning.
Re:Web CGI programs aren't particularly slow these days
by mrweasel on Monday January 08, 2024 @12:43PM
(#38915437)
The site is running as a cgi script, according to the article, and hitting the HN front page doesn't seem to have slowed it down in any way that I've noticed. So I think the point is well made.
Re:Web CGI programs aren't particularly slow these days
by Retr0id on Monday January 08, 2024 @12:58PM
(#38915628)
The page was served to me with `Last-Modified: Thu, 28 Dec 2023 04:02:49 GMT`, which to me implies either aggressive caching, or that the publishing system acts like a static site generator.
Re:Web CGI programs aren't particularly slow these days
by siebenmann on Thursday January 11, 2024 @03:19PM
(#38958390)
The publishing system takes some pains to provide an accurate last-modified value for HTTP caching purposes (and an ETag too); internally it tracks the most recent modification time of all components that go into the page as it's (dynamically) assembled from various pieces.
(I am the author of the linked-to article and also the author of the software it's running. Said software also has (on-disk) caching, but that's not why the last-modified is back in December of last year.)
Re:Web CGI programs aren't particularly slow these days
by benhoyt on Monday January 08, 2024 @02:40PM
(#38916980)
Actually, an article of mine was on the front page of HN the other day, and it only got ~10,000 hits over a day. At its peak it was less than 1 per second. I've been #1 on HN before, and you still only get about 30k hits total with a peak of several per second. So even if your responses take 200ms and you can only handle one at a time, you'll be fine. The HN/Slashdot effect is not hard to handle!
Re:Web CGI programs aren't particularly slow these days
by Retr0id on Monday January 08, 2024 @03:18PM
(#38917526)
I was also on the front page earlier in the week, and I agree with your numbers. Let's call it 1/s peak.
If a page is using CGI, it's often (but not always) because it's interactive in some way. If users are interacting and generate 10 requests total, on average, you're down to only 100ms per request (which is about how long it takes my system to spin up a new python3 process and `import numpy`).
It's slightly ironic to be reading this phrase via the front page of HN.