Not sure where else to go with this question. I've got an ember app with compiled and hashed asset bundles (ie: app-8d27918d2e995f44e1ddc1921ccfeea5.js
). The response headers properly set the cache controller headers for a really really long time: Cache-Control public, max-age=31536000
However, every time my browser requests those files, it sets a header in the request to ignore the cache: Cache-Control max-age=0
and so the resource respond with a 200 every time and re-downloads the files.
This happens in any browser so my guess is that it's the that there is something else the headers from the server that is telling the browser to do that?
For reference, here is the full headers for a request and response:
Status Code:200 OK
Response Headers
cache-control:public, max-age=31536000
content-encoding:gzip
content-type:application/javascript
date:Thu, 23 Jul 2015 14:17:30 GMT
server:NetDNA-cache/2.2
status:200 OK
vary:Accept-Encoding
version:HTTP/1.1
x-cache:HIT
Request Headers
:host:***
:method:GET
:path:/assets/vendor-139f929387d1eebee2f7ddffeb9e0748.js
:scheme:https
:version:HTTP/1.1
accept:*/*
accept-encoding:gzip, deflate, sdch
accept-language:en-US,en;q=0.8
cache-control:max-age=0
cookie:ajs_anonymous_id=%2246086221-0a60-4c00-a823-264402381c53%22; _gat=1; ajs_group_id=null; _ga=GA1.2.1468325632.1437660905; ajs_user_id=%221%22
dnt:1
user-agent:Mozilla/5.0 (Macintosh; Intel Mac OS X 10_10_4) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/44.0.2403.89 Safari/537.36
Aucun commentaire:
Enregistrer un commentaire