HTTP Caches - All the web caches layer explained on one page

About

This article is talking about cache in the Web which is a feature of HTTP that:

Cache Implementation Step by Step

The how-to page gives a step-by-step idea of how to configure and test the HTTP cache.

More … How to implement and check a Web / HTTP cache ?

Chain

There is three component in the route of an HTTP request/response, mainly:

Each below section is talking about this process related to the cache.

Server

A web server does not cache any resource (the application on the server may cache) but controls how the resources (HTML, Javascript, …) that it send are cached via the several control cache Header.

The client (browser) and proxy will read this control cache Headers and implements their cache accordingly.

To understand and see the cache headers that have an impact on the cache, see this article: HTTP - Cache (Cache-Control Header, Bursting, )

Note that by pre-rendering a page, you may also implement an internal cache

Intermediate / Proxy

On the network, you can have proxy that may have their own cache store.

Client

Browser cache

The web browser cache will also read the control cache headers and implements its cache accordingly.

Service workers

If for many reason such as:

  • disk space limitations,
  • browser internal implementation,
  • and limitations in the expressiveness of the HTTP cache specification (ie control cache headers)

the browser cache may not fulfill your requirement, you can always implements your own cache strategy with service worker for instance.

Specifications

The HTTP cache specification is covered in this two specifications:





Discover More
(HTTP|HTTPS) - Hypertext Transfer Protocol

Hypertext Transfer Protocol (HTTP) is the transfer protocol to exchange or transfer web resource between nodes (host). The H in HTTP means an hypertext (ie HTML). The protocol was first designed...
Map Of Internet 1973
A Content delivery network delivers Static resources such as image locally worldwide

A description for the search page result engine
Firefox Browser Cache
Browser Cache - Management and usage

How to clear and manage the browser cache.
Data System Architecture
Data - Cache

In computer science, a data cache is a component that aims to: improve performance reduce load on the server. The cache will: store transparently a request response and use it to for later...
Map Of Internet 1973
Data Cache - Time to Live (TTL) or hop limit

The TTL is the maximum timespan of data in a cache. Once the timespan has elapsed, data is discarded or revalidated. A DNS record has a TTL attached A HTTP cache with the max-age and s-max-age...
Http Cache Partitioning Example
HTTP - Cache Store

A cache store is an http cache component that caches the http response if the cache control header permits it. There is two type of cache: intermediate cache (proxy) client cache (user-agent cache...
Windows Internet Properties Proxy
HTTP - Forward Proxy

A forward proxy is a proxy application that is configured to intercept and forward every internal Http request to an destination website, hence the name Forward Proxy. It's also known as man-in-the-middle...
HTTP - Gateway (Reverse Proxy)

A reverse proxy (or gateway) is a proxy that is configured to appear to the client just like an ordinary web server. Traffic from the internet at large enters system through reverse proxy, which then...
HTTP - PATCH Method

PATCH is an HTTP method that: update a resource provide only the data to be changed can't be cached is unsafe
HTTP - Proxy

An HTTP proxy is a proxy that re-routes the HTTP message (request and response). It sits between the client and the origin server. There is two kinds of proxy but they are just the same application,...



Share this page:
Follow us:
Task Runner