WWW-Changes archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

CVS commit: htutils/cgi-src/gnats



Module Name:    htutils
Committed By:   riastradh
Date:           Thu May 14 01:52:41 UTC 2026

Modified Files:
        htutils/cgi-src/gnats: query-full-pr

Log Message:
query-full-pr: Factor out common logic; extend up-to-date criteria.

- Don't duplicate the PR generation logic in two branches of a
  conditional.  (There's another copy in gnats-precook-prs -- TBD.)

- Consider the cached PR rendering to be up-to-date only if it is
  newer than the PR content _and_ the PR rendering scripts and
  configuration.

This is pretty kludgey.  It would be better if we used standard HTTP
caching semantics by generating ETag from the latest mtime of any
relevant file, and implementing If-None-Match to validate a client's
cached ETag; then we can defer caching to another layer, like apache
mod_cache or the Fastly CDN.

But for now, this should fix the problem where we've been serving
stale caches of rendered PRs for nearly a decade since the header and
footer were tweaked for the first time after the cache was
implemented.


To generate a diff of this commit:
cvs rdiff -u -r1.48 -r1.49 htutils/cgi-src/gnats/query-full-pr

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



Home | Main Index | Thread Index | Old Index