HTTP 304 is an indication by the web server or CDN that the resource asked for has not changed since a specified time.
The web server responds with a 304 only when the browser sends the If_Modified_Since header, and the resource has not changed since the specified time.
For example, on April 10th the browser asked for a resource that was not in the browser cache. The resource had a caching policy of 7 days, and the browser saved it in its local cache.
On April 12th the browser has a request for the same object. It is found in the cache. The browser then send a request that includes the following header:
If-Modified-Since: Thu, 10 Apr 2014 09:59:23 GMT
As the resource was not modified, the webserver responds with 304
HTTP/1.1 304 Not Modified
Last-Modified: Tue, 02 Mar 2014 11:03:22 GMT
You should never see this error in your Web browser. It should simply present the Web page from its cache - because it believes the page has not changed since it was last cached. If your client is not a Web browser, then it should equally be able to present the page from a cache. If unable to do so, it is not using the If_Modified_Since or related headers correctly.
Important to know:
Your CDN may or may not use the querystring as a caching key, but the browser always uses the querystring.
Comments
0 comments
Please sign in to leave a comment.