Skip to main content

Clear cache

Last update:

Clearing the cache may be necessary:

  • if the content on the source has been updated;
  • the data is not displayed correctly.

The cache can be cleared selectively or completely.

The clearing time depends on the number of files and may take up to 15 minutes. You can clear the cache no more than once a minute.

Clear cache completely

warning

During a full cache flush, the load on the content source may increase.

  1. In the Control Panel, on the top menu, click Products and select CDN.

  2. In the CDN Resources section, under the resource, select Clear Cache.

  3. Select the cleaning type Full.

  4. Click Clear cache.

  5. Click Clear cache. It takes about a minute for the purge request to be generated. When the request is generated, clearing begins, and the resource changes to PROCESSING status . Clearing is complete when the resource is ACTIVE.

Clear cache selectively

  1. In the Control Panel, on the top menu, click Products and select CDN.

  2. In the CDN Resources section, under the resource, select Clear Cache.

  3. Select the cleaning type Selective.

  4. Specify relative paths to the files you want to delete from the cache. To add relative paths correctly, compose them according to the rules of composing a relative path. Specify each path on a new line. You can add up to 300 paths at a time.

  5. Click Clear cache. It takes about a minute for the purge request to be generated. When the request is generated, clearing begins, and the resource changes to PROCESSING status . Clearing is complete when the resource is ACTIVE.

Relative path rules

Specify * or / characters at the beginning of the path. The * character replaces any number of characters.

In a single path, you can specify a specific file, directory, or group of files with the same extension.

All versions of one file

File path:

/path/to/file.jpg

File with query parameter

The path to the file with the query parameter:

/path/to/file.jpg?VERSION

Directory files

A path mask without a domain name that is wrapped in the * operator:

*/path/to/directory/*

Files with a specific extension

The * operator and file extensions:

*.jpg

Directory files with a specific extension

A path mask without a domain name, which is wrapped in the * operator, specifying the extension:

*/path/to/directory/*.jpg

Relative path example

Suppose you want to remove the file.jpg file in the specified directory from the cache, as well as all .jpg files contained in the directory and its child folders. In this case, the list of links will look like this:

/path/to/file.jpg
*/directory/*.jpg