Force uncached resources from CDN

286 Views Asked by At

My job uses Akamai as a CDN for its marketing website. Often times there would be changes to css or js files that are cached on the CDN when accessing the site over the domain.

We're running into issues where updated versions of these files are not served over the CDN even when version strings are used.

For example,

/js/scripts.min.js?201801041618

would still serve the old version of this file after an update when attempting to access over the CDN (the domain).

When accessing the site via the direct endpoint (where the domain points) the latest version of the file is loaded.

One option is to clear the file from Akamai manually, but this is cumbersome and not scalable.

We are using a Symfony 4 PHP 7.2 - other than version strings, is there some server-side solution to indicate that a particular file must be served from it's source, rather than from cache?

0

There are 0 best solutions below