Skip to main content

3. Examples

The following is an example of a minimal cache hit:

Cache-Status: ExampleCache; hit

However, a polite cache will give some more information, e.g.:

Cache-Status: ExampleCache; hit; ttl=376

A stale hit just has negative freshness, as in this example:

Cache-Status: ExampleCache; hit; ttl=-412

Whereas this is an example of a complete miss:

Cache-Status: ExampleCache; fwd=uri-miss

This is an example of a miss that successfully validated on the backend server:

Cache-Status: ExampleCache; fwd=stale; fwd-status=304

This is an example of a miss that was collapsed with another request:

Cache-Status: ExampleCache; fwd=uri-miss; collapsed

This is an example of a miss that the cache attempted to collapse, but couldn't:

Cache-Status: ExampleCache; fwd=uri-miss; collapsed=?0

The following is an example of going through two separate layers of caching, where the cache closest to the origin responded to an earlier request with a stored response, and a second cache stored that response and later reused it to satisfy the current request:

Cache-Status: OriginCache; hit; ttl=1100,
"CDN Company Here"; hit; ttl=545

The following is an example of going through a three-layer caching system, where the closest to the origin is a reverse proxy (where the response was served from cache); the next is a forward proxy interposed by the network (where the request was forwarded because there wasn't any response cached with its URI, the request was collapsed with others, and the resulting response was stored); and the closest to the user is a browser cache (where there wasn't any response cached with the request's URI):

Cache-Status: ReverseProxyCache; hit
Cache-Status: ForwardProxyCache; fwd=uri-miss; collapsed; stored
Cache-Status: BrowserCache; fwd=uri-miss