Skip to content

Caching

Michael Harrison edited this page Sep 3, 2020 · 1 revision

CMS Static Files

Django manages static files through a command called collectstatic, which should be run at each deployment. This bundles the static assets from the local code and all contrib modules and puts them in the S3 bucket for serving. Sometimes these caches need to be cleared (it's at least a good starting debugging step when assets are not working as expected). To do this, login to the AWS console, go to Cloudfront, and clear the caches for the d3bxy9euw4e147.cloudfront.net domain. This can take awhile to complete.

API Caching

We are using Cloudfront to cache the API responses in the CMS. These caches are shared with REX (they are for the entire top level openstax.org domain). If you are not seeing expected changes in the CMS on the FE, it's always a good idea to try to clear the caches. These are being cleared on every PAGE save (note, a snippet/setting/banner is not a page). To trigger a cache clear, save any page.

Clone this wiki locally