Chrome not caching CloudFront video/audio; CloudFront delivers http 1.0 headersHTTP caching headers: how should must-revalidate work?http headers necessary ensure cloudfront distributed files don't get browser cachedChromium audit says it's not caching static content, yet headers are set - who is wrong?nginx reverse http proxy not caching php-generated imagesNginx not caching when Vary headers not being ignoredNGINX not caching images or sending added headersAWS CloudFront not caching S3 content
If a massive object like Jupiter flew past the Earth how close would it need to come to pull people off of the surface?
Why don't I have ground wiring on any of my outlets?
Can an old DSLR be upgraded to match modern smartphone image quality
Uncommanded roll at high speed
How did early x86 BIOS programmers manage to program full blown TUIs given very few bytes of ROM/EPROM?
Select row of data if next row contains zero
Can non-English-speaking characters use wordplay specific to English?
Is this light switch installation safe and legal?
How to make the POV character sit on the sidelines without the reader getting bored
If a problem only occurs randomly once in every N times on average, how many tests do I have to perform to be certain that it's now fixed?
Is a hash a zero-knowledge proof?
Humans meet a distant alien species. How do they standardize? - Units of Measure
What's the most polite way to tell a manager "shut up and let me work"?
Points within polygons in different projections
Is having a hidden directory under /etc safe?
Why is there a need to modify system call tables in linux?
Where can I find the list of all tendons in the human body?
What does the behaviour of water on the skin of an aircraft in flight tell us?
Can a rogue effectively triple their speed by combining Dash and Ready?
Mother abusing my finances
When a current flow in an inductor is interrupted, what limits the voltage rise?
Why were the Night's Watch required to be celibate?
Differences between “pas vrai ?”, “c’est ça ?”, “hein ?”, and “n’est-ce pas ?”
Biblical Basis for 400 years of silence between old and new testament
Chrome not caching CloudFront video/audio; CloudFront delivers http 1.0 headers
HTTP caching headers: how should must-revalidate work?http headers necessary ensure cloudfront distributed files don't get browser cachedChromium audit says it's not caching static content, yet headers are set - who is wrong?nginx reverse http proxy not caching php-generated imagesNginx not caching when Vary headers not being ignoredNGINX not caching images or sending added headersAWS CloudFront not caching S3 content
.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty height:90px;width:728px;box-sizing:border-box;
With the following response header:
HTTP/1.0 200 OK
Content-Type: video/mp4
Content-Length: 3294545
Connection: keep-alive
Date: Thu, 30 May 2013 21:17:34 GMT
x-amz-meta-s3cmd-attrs: uid:501/gname:staff/uname:americanyak/gid:20/mode:33
152/mtime:1368215923/atime:1369948577/ctime:1
369948245
Cache-Control: no-transform,public,max-age=31536000,s-maxage=31536000
Expires: Fri, 30 May 2014 00:00:00 GMT
Last-Modified: Thu, 30 May 2013 21:16:39 GMT
ETag: "b524b3f434581a1c2daff863cf201540"
Accept-Ranges: bytes
Server: AmazonS3
Age: 1309
Via: 1.0 33c069541cbb3f6e68de8056c044d86e.cloudfront.net (CloudFront)
X-Cache: Hit from cloudfront
X-Amz-Cf-Id: oeZ3EzRFAZggWpgqIbObtJH_MdyrGLMsdxUU3amupI5rkq7sbXPt4A==
What am I missing? Why is this not caching?
cache cdn google-chrome amazon-cloudfront
add a comment |
With the following response header:
HTTP/1.0 200 OK
Content-Type: video/mp4
Content-Length: 3294545
Connection: keep-alive
Date: Thu, 30 May 2013 21:17:34 GMT
x-amz-meta-s3cmd-attrs: uid:501/gname:staff/uname:americanyak/gid:20/mode:33
152/mtime:1368215923/atime:1369948577/ctime:1
369948245
Cache-Control: no-transform,public,max-age=31536000,s-maxage=31536000
Expires: Fri, 30 May 2014 00:00:00 GMT
Last-Modified: Thu, 30 May 2013 21:16:39 GMT
ETag: "b524b3f434581a1c2daff863cf201540"
Accept-Ranges: bytes
Server: AmazonS3
Age: 1309
Via: 1.0 33c069541cbb3f6e68de8056c044d86e.cloudfront.net (CloudFront)
X-Cache: Hit from cloudfront
X-Amz-Cf-Id: oeZ3EzRFAZggWpgqIbObtJH_MdyrGLMsdxUU3amupI5rkq7sbXPt4A==
What am I missing? Why is this not caching?
cache cdn google-chrome amazon-cloudfront
add a comment |
With the following response header:
HTTP/1.0 200 OK
Content-Type: video/mp4
Content-Length: 3294545
Connection: keep-alive
Date: Thu, 30 May 2013 21:17:34 GMT
x-amz-meta-s3cmd-attrs: uid:501/gname:staff/uname:americanyak/gid:20/mode:33
152/mtime:1368215923/atime:1369948577/ctime:1
369948245
Cache-Control: no-transform,public,max-age=31536000,s-maxage=31536000
Expires: Fri, 30 May 2014 00:00:00 GMT
Last-Modified: Thu, 30 May 2013 21:16:39 GMT
ETag: "b524b3f434581a1c2daff863cf201540"
Accept-Ranges: bytes
Server: AmazonS3
Age: 1309
Via: 1.0 33c069541cbb3f6e68de8056c044d86e.cloudfront.net (CloudFront)
X-Cache: Hit from cloudfront
X-Amz-Cf-Id: oeZ3EzRFAZggWpgqIbObtJH_MdyrGLMsdxUU3amupI5rkq7sbXPt4A==
What am I missing? Why is this not caching?
cache cdn google-chrome amazon-cloudfront
With the following response header:
HTTP/1.0 200 OK
Content-Type: video/mp4
Content-Length: 3294545
Connection: keep-alive
Date: Thu, 30 May 2013 21:17:34 GMT
x-amz-meta-s3cmd-attrs: uid:501/gname:staff/uname:americanyak/gid:20/mode:33
152/mtime:1368215923/atime:1369948577/ctime:1
369948245
Cache-Control: no-transform,public,max-age=31536000,s-maxage=31536000
Expires: Fri, 30 May 2014 00:00:00 GMT
Last-Modified: Thu, 30 May 2013 21:16:39 GMT
ETag: "b524b3f434581a1c2daff863cf201540"
Accept-Ranges: bytes
Server: AmazonS3
Age: 1309
Via: 1.0 33c069541cbb3f6e68de8056c044d86e.cloudfront.net (CloudFront)
X-Cache: Hit from cloudfront
X-Amz-Cf-Id: oeZ3EzRFAZggWpgqIbObtJH_MdyrGLMsdxUU3amupI5rkq7sbXPt4A==
What am I missing? Why is this not caching?
cache cdn google-chrome amazon-cloudfront
cache cdn google-chrome amazon-cloudfront
asked May 30 '13 at 22:32
arxpoeticaarxpoetica
1013
1013
add a comment |
add a comment |
3 Answers
3
active
oldest
votes
https://forums.aws.amazon.com/thread.jspa?threadID=124998
Hello,
While we are aware of the issue with range request HTTP/1.0 206 responses and Chrome, we cannot provide an ETA for a fix. Since this issue is specific to range requests, an immediate workaround is to disable range requests on your origin server if this is possible for your use case.
It is also worth mentioning that multiple web proxy and cache application vendors have using HTTP/1.0 as a de facto standard for many years, so you will probably sporadically get similar reports from your end users using Chrome, but not other browsers such as Firefox or Safari. For example, here is a discussion between a Chrome developer on the mailing list for the popular Squid web cache about a similar report:
http://www.squid-cache.org/mail-archive/squid-dev/201204/0113.html
I am not saying that always returning HTTP/1.0 will stick around forever, but it is fairly common in real world situations today.
We are working on a fix for the future.
Regards,
Matt J
They could implement HTTP/1.1. It's only 14 years old now!
– Michael Hampton♦
May 30 '13 at 23:18
add a comment |
I was able to work around the issue by disabling the ETag
header on my origin server.
CloudFront doesn't like ETag
references for some reason.
To this day, requests sent with the Range
header for video/mp4
files via CloudFront cause the entire object to be returned with 200 OK
instead of 206 Partial Content
when the client sends an If-Range
header with a cached ETag
reference.
Removing the ETag
header from the origin server effectively works around the issue, as the client will no longer send If-Range
, and CloudFront will return 206 Partial Content
as expected.
Also, it will prevent cache misses (X-Cache: Miss from cloudfront
), saving you bandwidth and speeding up the CDN requests.
Here's how you that can be done with Express 4 for static files:
// Allow access to site folder
app.use( express.static('./site', etag: false ) );
add a comment |
I had similar problems with the current Chrome version at this date. The Main issue we had was chrome not caching the video that were hosted on s3 and served by Cloudfront. I explain, we are using HTML5 native video player where we use the autoplay and loop features. After that the video finished playing, chrome would request the video from Cloudfront instead of fetching it from the cache in the disk.
Two things that we have noticed, this issue was not happening with Firefox. And, some website that host their videos on their VPS are not experiencing the same issue when we use Chrome.
We are believe that the problem happen when chrome is requesting the partial data to stream the video (206 status) from Cloudfront and it seems like it does not know that the video has been completely downloaded.
We could not find a solution at this point...
add a comment |
Your Answer
StackExchange.ready(function()
var channelOptions =
tags: "".split(" "),
id: "2"
;
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function()
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled)
StackExchange.using("snippets", function()
createEditor();
);
else
createEditor();
);
function createEditor()
StackExchange.prepareEditor(
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader:
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
,
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
);
);
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fserverfault.com%2fquestions%2f512090%2fchrome-not-caching-cloudfront-video-audio-cloudfront-delivers-http-1-0-headers%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
3 Answers
3
active
oldest
votes
3 Answers
3
active
oldest
votes
active
oldest
votes
active
oldest
votes
https://forums.aws.amazon.com/thread.jspa?threadID=124998
Hello,
While we are aware of the issue with range request HTTP/1.0 206 responses and Chrome, we cannot provide an ETA for a fix. Since this issue is specific to range requests, an immediate workaround is to disable range requests on your origin server if this is possible for your use case.
It is also worth mentioning that multiple web proxy and cache application vendors have using HTTP/1.0 as a de facto standard for many years, so you will probably sporadically get similar reports from your end users using Chrome, but not other browsers such as Firefox or Safari. For example, here is a discussion between a Chrome developer on the mailing list for the popular Squid web cache about a similar report:
http://www.squid-cache.org/mail-archive/squid-dev/201204/0113.html
I am not saying that always returning HTTP/1.0 will stick around forever, but it is fairly common in real world situations today.
We are working on a fix for the future.
Regards,
Matt J
They could implement HTTP/1.1. It's only 14 years old now!
– Michael Hampton♦
May 30 '13 at 23:18
add a comment |
https://forums.aws.amazon.com/thread.jspa?threadID=124998
Hello,
While we are aware of the issue with range request HTTP/1.0 206 responses and Chrome, we cannot provide an ETA for a fix. Since this issue is specific to range requests, an immediate workaround is to disable range requests on your origin server if this is possible for your use case.
It is also worth mentioning that multiple web proxy and cache application vendors have using HTTP/1.0 as a de facto standard for many years, so you will probably sporadically get similar reports from your end users using Chrome, but not other browsers such as Firefox or Safari. For example, here is a discussion between a Chrome developer on the mailing list for the popular Squid web cache about a similar report:
http://www.squid-cache.org/mail-archive/squid-dev/201204/0113.html
I am not saying that always returning HTTP/1.0 will stick around forever, but it is fairly common in real world situations today.
We are working on a fix for the future.
Regards,
Matt J
They could implement HTTP/1.1. It's only 14 years old now!
– Michael Hampton♦
May 30 '13 at 23:18
add a comment |
https://forums.aws.amazon.com/thread.jspa?threadID=124998
Hello,
While we are aware of the issue with range request HTTP/1.0 206 responses and Chrome, we cannot provide an ETA for a fix. Since this issue is specific to range requests, an immediate workaround is to disable range requests on your origin server if this is possible for your use case.
It is also worth mentioning that multiple web proxy and cache application vendors have using HTTP/1.0 as a de facto standard for many years, so you will probably sporadically get similar reports from your end users using Chrome, but not other browsers such as Firefox or Safari. For example, here is a discussion between a Chrome developer on the mailing list for the popular Squid web cache about a similar report:
http://www.squid-cache.org/mail-archive/squid-dev/201204/0113.html
I am not saying that always returning HTTP/1.0 will stick around forever, but it is fairly common in real world situations today.
We are working on a fix for the future.
Regards,
Matt J
https://forums.aws.amazon.com/thread.jspa?threadID=124998
Hello,
While we are aware of the issue with range request HTTP/1.0 206 responses and Chrome, we cannot provide an ETA for a fix. Since this issue is specific to range requests, an immediate workaround is to disable range requests on your origin server if this is possible for your use case.
It is also worth mentioning that multiple web proxy and cache application vendors have using HTTP/1.0 as a de facto standard for many years, so you will probably sporadically get similar reports from your end users using Chrome, but not other browsers such as Firefox or Safari. For example, here is a discussion between a Chrome developer on the mailing list for the popular Squid web cache about a similar report:
http://www.squid-cache.org/mail-archive/squid-dev/201204/0113.html
I am not saying that always returning HTTP/1.0 will stick around forever, but it is fairly common in real world situations today.
We are working on a fix for the future.
Regards,
Matt J
answered May 30 '13 at 23:15
ceejayozceejayoz
27.4k66694
27.4k66694
They could implement HTTP/1.1. It's only 14 years old now!
– Michael Hampton♦
May 30 '13 at 23:18
add a comment |
They could implement HTTP/1.1. It's only 14 years old now!
– Michael Hampton♦
May 30 '13 at 23:18
They could implement HTTP/1.1. It's only 14 years old now!
– Michael Hampton♦
May 30 '13 at 23:18
They could implement HTTP/1.1. It's only 14 years old now!
– Michael Hampton♦
May 30 '13 at 23:18
add a comment |
I was able to work around the issue by disabling the ETag
header on my origin server.
CloudFront doesn't like ETag
references for some reason.
To this day, requests sent with the Range
header for video/mp4
files via CloudFront cause the entire object to be returned with 200 OK
instead of 206 Partial Content
when the client sends an If-Range
header with a cached ETag
reference.
Removing the ETag
header from the origin server effectively works around the issue, as the client will no longer send If-Range
, and CloudFront will return 206 Partial Content
as expected.
Also, it will prevent cache misses (X-Cache: Miss from cloudfront
), saving you bandwidth and speeding up the CDN requests.
Here's how you that can be done with Express 4 for static files:
// Allow access to site folder
app.use( express.static('./site', etag: false ) );
add a comment |
I was able to work around the issue by disabling the ETag
header on my origin server.
CloudFront doesn't like ETag
references for some reason.
To this day, requests sent with the Range
header for video/mp4
files via CloudFront cause the entire object to be returned with 200 OK
instead of 206 Partial Content
when the client sends an If-Range
header with a cached ETag
reference.
Removing the ETag
header from the origin server effectively works around the issue, as the client will no longer send If-Range
, and CloudFront will return 206 Partial Content
as expected.
Also, it will prevent cache misses (X-Cache: Miss from cloudfront
), saving you bandwidth and speeding up the CDN requests.
Here's how you that can be done with Express 4 for static files:
// Allow access to site folder
app.use( express.static('./site', etag: false ) );
add a comment |
I was able to work around the issue by disabling the ETag
header on my origin server.
CloudFront doesn't like ETag
references for some reason.
To this day, requests sent with the Range
header for video/mp4
files via CloudFront cause the entire object to be returned with 200 OK
instead of 206 Partial Content
when the client sends an If-Range
header with a cached ETag
reference.
Removing the ETag
header from the origin server effectively works around the issue, as the client will no longer send If-Range
, and CloudFront will return 206 Partial Content
as expected.
Also, it will prevent cache misses (X-Cache: Miss from cloudfront
), saving you bandwidth and speeding up the CDN requests.
Here's how you that can be done with Express 4 for static files:
// Allow access to site folder
app.use( express.static('./site', etag: false ) );
I was able to work around the issue by disabling the ETag
header on my origin server.
CloudFront doesn't like ETag
references for some reason.
To this day, requests sent with the Range
header for video/mp4
files via CloudFront cause the entire object to be returned with 200 OK
instead of 206 Partial Content
when the client sends an If-Range
header with a cached ETag
reference.
Removing the ETag
header from the origin server effectively works around the issue, as the client will no longer send If-Range
, and CloudFront will return 206 Partial Content
as expected.
Also, it will prevent cache misses (X-Cache: Miss from cloudfront
), saving you bandwidth and speeding up the CDN requests.
Here's how you that can be done with Express 4 for static files:
// Allow access to site folder
app.use( express.static('./site', etag: false ) );
edited Oct 24 '15 at 14:55
answered Oct 24 '15 at 11:14
Elad NavaElad Nava
21329
21329
add a comment |
add a comment |
I had similar problems with the current Chrome version at this date. The Main issue we had was chrome not caching the video that were hosted on s3 and served by Cloudfront. I explain, we are using HTML5 native video player where we use the autoplay and loop features. After that the video finished playing, chrome would request the video from Cloudfront instead of fetching it from the cache in the disk.
Two things that we have noticed, this issue was not happening with Firefox. And, some website that host their videos on their VPS are not experiencing the same issue when we use Chrome.
We are believe that the problem happen when chrome is requesting the partial data to stream the video (206 status) from Cloudfront and it seems like it does not know that the video has been completely downloaded.
We could not find a solution at this point...
add a comment |
I had similar problems with the current Chrome version at this date. The Main issue we had was chrome not caching the video that were hosted on s3 and served by Cloudfront. I explain, we are using HTML5 native video player where we use the autoplay and loop features. After that the video finished playing, chrome would request the video from Cloudfront instead of fetching it from the cache in the disk.
Two things that we have noticed, this issue was not happening with Firefox. And, some website that host their videos on their VPS are not experiencing the same issue when we use Chrome.
We are believe that the problem happen when chrome is requesting the partial data to stream the video (206 status) from Cloudfront and it seems like it does not know that the video has been completely downloaded.
We could not find a solution at this point...
add a comment |
I had similar problems with the current Chrome version at this date. The Main issue we had was chrome not caching the video that were hosted on s3 and served by Cloudfront. I explain, we are using HTML5 native video player where we use the autoplay and loop features. After that the video finished playing, chrome would request the video from Cloudfront instead of fetching it from the cache in the disk.
Two things that we have noticed, this issue was not happening with Firefox. And, some website that host their videos on their VPS are not experiencing the same issue when we use Chrome.
We are believe that the problem happen when chrome is requesting the partial data to stream the video (206 status) from Cloudfront and it seems like it does not know that the video has been completely downloaded.
We could not find a solution at this point...
I had similar problems with the current Chrome version at this date. The Main issue we had was chrome not caching the video that were hosted on s3 and served by Cloudfront. I explain, we are using HTML5 native video player where we use the autoplay and loop features. After that the video finished playing, chrome would request the video from Cloudfront instead of fetching it from the cache in the disk.
Two things that we have noticed, this issue was not happening with Firefox. And, some website that host their videos on their VPS are not experiencing the same issue when we use Chrome.
We are believe that the problem happen when chrome is requesting the partial data to stream the video (206 status) from Cloudfront and it seems like it does not know that the video has been completely downloaded.
We could not find a solution at this point...
answered Feb 10 '17 at 22:48
fenecfenec
101
101
add a comment |
add a comment |
Thanks for contributing an answer to Server Fault!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fserverfault.com%2fquestions%2f512090%2fchrome-not-caching-cloudfront-video-audio-cloudfront-delivers-http-1-0-headers%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown