http-extensions
http-extensions copied to clipboard
query: review caching requirements
(follow up to https://github.com/httpwg/http-extensions/issues/2896)
Currently:
The response to a QUERY method is cacheable; a cache MAY use it to satisfy subsequent QUERY requests as per Section 4 of [HTTP-CACHING]). The cache key for a QUERY request (see Section 2 of [HTTP-CACHING]) MUST incorporate the request content. When doing so, caches SHOULD first normalize request content to remove semantically insignificant differences, thereby improving cache efficiency, by:
- Removing content encoding(s) (Section 8.4 of [HTTP]).
- Normalizing based upon knowledge of format conventions, as indicated by any media subtype suffix in the request's Content-Type field (e.g., "+json", see Section 4.2.8 of [RFC6838]).
- Normalizing based upon knowledge of the semantics of the content itself, as indicated by the request's Content-Type field.
Note that any such normalization is performed solely for the purpose of generating a cache key; it does not change the request itself.
Issues:
- "... MUST incorporate the request content" - that's misleading, because any kind of stable indentifier (such as a SHA-256 of (normalized) content) should be good enough
- "When doing so..." means "When responses are cached...", right?
- "...SHOULD first normalize..." is misleading, as all the steps that follow are more or less optional ... "...can normalize..." or "...are encouraged to normalize..." maybe?
- "remove semantically insignificant differences, thereby improving cache efficiency, by" -> "remove semantically insignificant differences, thereby improving cache efficiency. For instance, by"
@mnot - does this make sense?