Last update:2024-07-17 17:20:49
Cache Refresh allows you to force the CDN servers to fetch the latest files from the origin server and cache them, overriding the existing cached files.
Cache Refresh is suitable for the following scenarios:
Cache Refresh supports multiple types: URL Refresh, Directory Refresh, RegEx Refresh and Domain Refresh.
Refresh Types
Refresh Type | Description | Notes |
---|---|---|
URL Refresh | Refreshes the cache at the URL granularity, suitable for a small number of files. | 1. The pushed URLs need to be case-sensitive; 2. URLs should start with a protocol such as http:// or mms:// . For example: http://www.test.com/index.html ; 3. One URL per line, multiple URLs separated by line breaks. |
Directory Refresh | Refreshes the cache at the directory granularity, recommended when the URLs that need updating under a directory exceed 100. | 1. The pushed directories need to be case-sensitive; 2. Directories should start with a protocol such as http:// or mms:// . For example: http://www.test.com/news/ ;3. One directory per line, multiple directories separated by line breaks; 4. If you want to refresh all directories under a domain, enter the root directory of the domain, such as: http://www.test.com/ ;5. If your domain has beed configured with cache host or any other rewriting configurations, please contact CDNetworks Technical Support to confirm how to submit refresh task, we will evaluate it based on your situation. |
Regex Refresh | Refreshes the cache using regular expression-based URLs. | One URL per line, starting with a protocol such as http:// , supporting protocols include http , https , mms . For example, to clear the js files under a certain directory, the submitted URL should be http://www.test.com/test/(.*).js(.*) . |
Domain Refresh | Refreshes the cache at the domain granularity, strongly recommended to contact technical support for evaluation before proceeding. | 1. You can directly enter the domain that needs to be refreshed without any protocol; 2. The system will refresh the cache files by default using the http:// and https:// protocols. If you need to refresh using other protocols, please use Directory Refresh or URL Refresh. |
If your domain has beed configured with cache host or any other rewriting configurations, please contact CDNetworks Technical Support to confirm how to submit refresh task, we will evaluate it based on your situation.
After selecting the refresh type you want, input the configuration items and then submit your refresh task. below are the mainly configuration items.
please noted that different refresh types have different configuration items.
Common URL/Common Directory
Click + Common URL or + Common Directory to select and add commonly used URLs/Directories. Select the commonly used URLs/Directories and click Add to Push Box to automatically input them into the text box for initiating the refresh task. This function provides management of common URLs/Directories, allowing you to add or delete them.
Task Types
All in Lowercase
Log in to CDNetworks Console, navigate to “Products” > “Application Services” > “Content MGMT” > “Cache Refresh”, and click on Task Query. You can query cache refresh tasks based on a specific time, domain, or complete URL, and you will see the following information about the target task.
Success Ratio
Success Rate = Number of successful executions / Total number of executions
A single refresh task needs to be sent to various CDNetworks CDN servers for execution, meaning the refresh task needs to be executed multiple times.
Recurring tasks refer to the tasks set up as recurring cache refresh tasks when creating a cache refresh task. After a task is successfully submitted, you can query and edit all recurring tasks under Timing Management.
When submitting a cache refresh task for the same URL/Directory/Domain within a short period, please make sure to wait for at least 5 minutes between submissions. For example, if the system has not completed the execution of the first URL task and a same URL task is received at that time, the latter task might be ignored by the system.