Remove "immutable" from long-term responses
We had a bug recently which sent out some bad "immutable" responses. We need to have a better process around cutting releases before we can be sure it doesn't happen again.
This commit is contained in:
@ -20,7 +20,7 @@ function serveHTMLModule(req, res) {
|
||||
.set({
|
||||
'Content-Length': Buffer.byteLength(code),
|
||||
'Content-Type': getContentTypeHeader(req.entry.contentType),
|
||||
'Cache-Control': 'public, max-age=31536000, immutable', // 1 year
|
||||
'Cache-Control': 'public, max-age=31536000', // 1 year
|
||||
ETag: etag(code),
|
||||
'Cache-Tag': 'file, html-file, html-module'
|
||||
})
|
||||
|
@ -14,7 +14,7 @@ function serveJavaScriptModule(req, res) {
|
||||
.set({
|
||||
'Content-Length': Buffer.byteLength(code),
|
||||
'Content-Type': getContentTypeHeader(req.entry.contentType),
|
||||
'Cache-Control': 'public, max-age=31536000, immutable', // 1 year
|
||||
'Cache-Control': 'public, max-age=31536000', // 1 year
|
||||
ETag: etag(code),
|
||||
'Cache-Tag': 'file, js-file, js-module'
|
||||
})
|
||||
|
@ -35,7 +35,7 @@ function serveMetadata(req, res) {
|
||||
|
||||
res
|
||||
.set({
|
||||
'Cache-Control': 'public, max-age=31536000, immutable', // 1 year
|
||||
'Cache-Control': 'public, max-age=31536000', // 1 year
|
||||
'Cache-Tag': 'meta'
|
||||
})
|
||||
.send(metadata);
|
||||
|
@ -15,7 +15,7 @@ function serveStaticFile(req, res) {
|
||||
.set({
|
||||
'Content-Length': req.entry.size,
|
||||
'Content-Type': getContentTypeHeader(req.entry.contentType),
|
||||
'Cache-Control': 'public, max-age=31536000, immutable', // 1 year
|
||||
'Cache-Control': 'public, max-age=31536000', // 1 year
|
||||
'Last-Modified': req.entry.lastModified,
|
||||
ETag: etag(req.entry.content),
|
||||
'Cache-Tag': tags.join(', ')
|
||||
|
Reference in New Issue
Block a user