I have W3TC setup to use Cloudfront as a CDN, which is working fine, except when I need to make a change to a file.
When I upload a new version of the CSS, I can push this to Amazon S3 fine, CloudFront obviously doesn't request this new file for a while.
Amazon say it's best practice not to replace files on CF, but to add versioned files, which I kinda expected W3TC to do.
So my question is, how do people deal with this? What's the best way?
Adding a query string version number doesn't really help, because a visitor is likely to request the new file before it actually exists on CF, so when it does exist on CF the old version will already be cached with that version number.
I can invalidate the file on CF, which speeds up the process somewhat, but it still takes some time, and obviously this is a manual process.