-
Notifications
You must be signed in to change notification settings - Fork 26
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Site doesn't ever return a 304 #354
Comments
@ioquatix do you think this is still a relevant issue? |
An we confirm if-none-match is working? |
@ioquatix On localhost, the server returns an ETag, but my browser isn't sending If-None-Match in a subsequent request. Prod does not even return an ETag. Do we care? I feel like ideally this would work. |
It should work, but maybe cloudflare is doing something weird. |
Soooooo....
Does seem to work correctly (returns 304). However, it's not the same etag as generated by If I set:
...there is no etag as you point out and also Is this some kind of feature/function of cloudflare? |
So what I can say is that it seems like the LB at Heroku is doing the right thing but Cloudflare is doing something different. |
@colby-swandale @nateberkopec, any ideas? |
https://www.mnot.net/blog/2007/08/07/etags Reading through this, it seems to imply that if you set |
Hmm. My computer still does a web request even though That article seems to be saying that if the content doesn't change, give the response a Here's the pros / cons list for Ruby API as I see it: max-agepros
cons
ETagpros
cons
I feel like max-age is nice for truly static content. Like at my job, we generate a unique URL for uploaded photos. The data that the URL returns literally will never change. This is a great time to use max-age. For content that's static a lot of the time but can change (during deployments, or data reimports), I don't know if max-age makes sense. |
The response headers don't include an
ETag
, so my browser can't send aIf-None-Match
, so that the server can return a 304.I thought that the
cf-cache-status: DYNAMIC
seemed suspicious.https://support.cloudflare.com/hc/en-us/articles/200172516-Which-file-extensions-does-CloudFlare-cache-for-static-content-
I don't know much about Cloudflare, unfortunately.
The text was updated successfully, but these errors were encountered: