[
https://issues.apache.org/jira/browse/HTTPCLIENT-1361?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13670242#comment-13670242
]
Jon Moore commented on HTTPCLIENT-1361:
---------------------------------------
Validation is defined in RFC2616:
http://www.w3.org/Protocols/rfc2616/rfc2616-sec13.html#sec13.3
Specifically, this refers to issuing a conditional request using a cache
validator to check on the validity of a (stale) cache entry. RFC2616 only
identifies Last-Modified and Etag as cache validators. For a response that
doesn't have either of these headers, there's technically no way for the cache
to _update_ its entry; it must discard it and _replace_ it with the result of a
(blocking) unconditional response.
I'm undecided on this change: on the one hand, I don't think the relevant RFCs
allow this according to a strict reading, because the resulting asynchronous
requests wouldn't technically be validations. On the other hand, this change is
clearly in-line with the spirit of stale-while-revalidate and has clear utility.
Let me talk to Mark Nottingham, who authored the stale-while-revalidate RFC--we
can just get clarification on his intent!
In any event, I think this should be marked as an Improvement rather than as a
Bug.
> stale-while-revalidate should work also without last-modified nor etag
> ----------------------------------------------------------------------
>
> Key: HTTPCLIENT-1361
> URL: https://issues.apache.org/jira/browse/HTTPCLIENT-1361
> Project: HttpComponents HttpClient
> Issue Type: Bug
> Components: Cache
> Affects Versions: 4.3 Beta1
> Reporter: Francois-Xavier Bonnet
> Priority: Minor
>
> Currently stale-while-revalidate mechanism works only if the cache entry
> contains a last-modified or a etag header. It should work also for cache
> entries with expires or max-age.
> The specification is not very clear about what a revalidation is, but in the
> example there is no last-modified nor etag, only a cache-control: max-age
> http://tools.ietf.org/html/rfc5861
> If everybody agrees, I can work on a fix.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]