Cloudfront randomly removes Range header

0

I am trying to use CloudFront for partial GET requests (with Range header) with caching enabled. I added Range header to the cache key settings in the cache policy. When a partial GET request is sent with proper Range header value, it works as expected most of the time. But in some cases, CloudFront drops the Range header from the Origin request and Origin (API Gateway) returns "Integration response of reported length 691691016 is larger than allowed maximum of 10485760 bytes" because of this. This behavior seems to be completely random. When I resend the exact same request, it returns a successful response with HTTP code 206. When I disable caching, this behavior does not occur.

  1. Is it necessary to add the Range header to cache policy for partial requests to work or is it forwarded automatically?
  2. What other settings can affect this behavior?

Thank you!

已提问 3 个月前88 查看次数
没有答案

您未登录。 登录 发布回答。

一个好的回答可以清楚地解答问题和提供建设性反馈,并能促进提问者的职业发展。

回答问题的准则