Cloudfront invalidation does not clear compressed version of object

0

I have a cloudfront distribution in front of an S3 bucket to serve a website. A certain S3 object is updated and then an invalidation matching the path is completed.

After that, requests with header 'accept-encoding: gzip, deflate, br' get a stale version of the object, whereas requests without that header get the fresh version. The same edge location is serving the content in both cases.

I assume this has got something to do with cloudfront storing compressed vs uncompressed versions. Why doesn't the invalidation clear the compressed version?

Jon
asked 10 months ago215 views
1 Answer
0

https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/Invalidation.html indicates "When you invalidate a file, CloudFront invalidates every cached version of the file regardless of the header values", so Cloudfront should have invalidated both.

profile picture
answered 10 months ago
  • My observations do not match that documentation. The context in which it is happening for me is reasonably complicated - a Wordpress site which is statically published to S3/Cloudfront. But I might have look to see if I can re-create the problem using simple command line tools.

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions