Closed
Bug 1364441
Opened 7 years ago
Closed 7 years ago
Use Cache-Control immutable
Categories
(Socorro :: Infra, task)
Socorro
Infra
Tracking
(Not tracked)
RESOLVED
FIXED
People
(Reporter: peterbe, Assigned: peterbe)
Details
Attachments
(3 files)
Firefox, as of version 49, supports 'Cache-Control: immutable'. It means that the server doesn't even bother to send a GET with 'If-Modified-Since ' (to which our Nginx most likely will respond 304 Not Modified). Basically, if you reload the page (e.g. to see if the data has changed) the client will send a GET for every single asset and Nginx will respond 304 for each one. For example, loading https://crash-stats.mozilla.com/search/?product=Firefox&version=54.0b&_dont_run=1 and hitting the Reload button will make 28 GET requests that all got a 304 response. If you use `Cache-Control: immutable` the browser doesn't even bother sending those GETs again (...to see if they've changed). Ultimately, this makes reloads faster for the users and less requests to your Nginx.
Assignee | ||
Comment 1•7 years ago
|
||
SHIFT-Reload first.
Assignee | ||
Comment 2•7 years ago
|
||
Regular Reload (before adding 'immutable')
Assignee | ||
Comment 3•7 years ago
|
||
Regular Reload (after 'immutable' has been added and 1 Shift-Reload was done). Note! I also had a `tail -f /tmp/socorro.access.log` running when I did this reload. Only the HTML document and the one (or two) XHR requests appeared there. Before, it was a whole page (of 304 requests).
Assignee | ||
Comment 4•7 years ago
|
||
PR https://github.com/mozilla/socorro-infra/pull/307
Assignee | ||
Comment 5•7 years ago
|
||
Here's a good article about the feature: https://www.keycdn.com/blog/cache-control-immutable/
Comment 6•7 years ago
|
||
Commit pushed to master at https://github.com/mozilla/socorro-infra https://github.com/mozilla/socorro-infra/commit/3fd949bf16506792f1174bfc02c0b7d2a72582e3 fixes bug 1364441 - Use Cache-Control immutable (#307)
Updated•7 years ago
|
Status: NEW → RESOLVED
Closed: 7 years ago
Resolution: --- → FIXED
You need to log in
before you can comment on or make changes to this bug.
Description
•