Flushing Caches

Last Updated: Nov 22, 2021
documentation for the dotCMS Content Management System

To maximize performance, dotCMS automatically caches content in a number of different cache regions. While this significantly improves performance, especially for large sites, it also means that if content has changed very recently, an older version of the content may be displayed instead of the most recent version, since the older version is pulled from the cache.

To ensure that dotCMS displays the most recent version of content, you may flush the cache. This can be useful during development (when content is being changed frequently) and when troubleshooting certain types of issues where the content on your site does not display as you expect it to.

Flushing All Caches

If the content on your site is not displaying correctly, or you have multiple areas of your site which aren't displaying correctly due to recent changes, you may wish to flush the entire cache on your site. To flush all cache regions:

  1. Select System -> Maintenance from the navigation sidebar.
  2. Select the Cache tab.
  3. Select “All Caches” in the Action section.
  4. Press the Flush button.

Flushing the Cache

Important: After you flush the cache, the performance of your site may be temporarily reduced, as all content will be fetched again from the database rather than the cache. This is normal, and performance will increase as the cache is re-filled with content.

Flushing Individual Cache Regions

You may select a specific cache region to flush, rather than flushing the entire cache.

For example, if you have made updates to a Page (or a Template or Container used by the Page) and the updates are not displaying, it is likely because the contents of the page being cached. Although you can likely solve this problem by changing the Cache TTL property of the page to 0 (to prevent caching for the page completely), you may not wish to change the page properties for a number of reasons. Instead, you can flush the Page cache and force the contents of all pages to be re-read from the database.

To flush a specific cache region:

  1. Select System -> Maintenance from the navigation sidebar.
  2. Select the Cache tab.
  3. Select the cache region you wish to flush in the Action section.
  4. Press the Flush button.

On this page

×

We Dig Feedback

Selected excerpt:

×