[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[bug#52805] [PATCH] substitute: Add a ‘--clear-cache’ option.
From: |
Ludovic Courtès |
Subject: |
[bug#52805] [PATCH] substitute: Add a ‘--clear-cache’ option. |
Date: |
Wed, 12 Jan 2022 22:04:37 +0100 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/27.2 (gnu/linux) |
Hi,
Tobias Geerinckx-Rice <me@tobias.gr> skribis:
> Caching is never to my advantage: it is ‘saving’ only the work I asked
> it to perform, against my wishes. ‘Look how fast I fed you possibly
> bogus data against your will!’ is not an impressive boast.
>
> Is my concern clear? Reasonable?
It’s clear, but I’m not sure it’s reasonable. :-)
When do you have to worry about caches?
‘guix weather’ can cache negative replies (404s) for
%narinfo-negative-ttl = 10mn, unless the server provides a different
‘Cache-Control’ TTL. So there’s a possibility that during that time
window it’ll tell you “nope” when in fact the thing has just arrived.
I think that’s acceptable (there’s a slight delay but nothing’s
“bogus”), and it’s kind to server admins.
(It’s possible for admins to run ‘guix publish --negative-ttl=0’ if they
don’t mind extra traffic from users.)
That said, if you find it sufficiently annoying, what about adding
‘--clear-cache’ to ‘guix weather’?
HTH!
Ludo’.