[webkit-dev] X-Purpose on prefetching requests

Alexey Proskuryakov ap at webkit.org
Sat Sep 25 21:23:24 PDT 2010


24.09.2010, в 22:26, Gavin Peters (蓋文彼德斯) написал(а):

> I think I might be missing this point.  For the purposes of
> prefetching, I think that once you send out a "Vary: X-Purpose"
> header, you've basically opted out of permitting prefetching.


I've been working from an overly broad idea that servers might want to do "something different" for prefetch requests. But it seems that the only reasonable responses to a prefetch request are:
- break the connection;
- send a 404 or 5xx response;
- send exactly the same response as for a non-prefetch request. And if the server bothers to count accesses to this resource, it must have Cache-control set to must-revalidate.

There is no need to send a Vary header field in response for these.

(Note that if any server won't send Cache-control: must-revalidate, then this creates a way to potentially fool enterprise network monitoring tools. One one hand, they'll need to ignore prefetch resources (since prefetching doesn't imply viewing), but on the other hand, viewing won't generate a request at all!)

- WBR, Alexey Proskuryakov



More information about the webkit-dev mailing list