Dynamic Media assets are cached by the CDN (Content Delivery Network) for fast delivery to your customers. However, when you make updates to those assets, you want those changes to take effect immediately on your website. Purging or invalidating the CDN cache lets you quickly update assets that are delivered by Dynamic Media. Instead of waiting for the cache to expire using a TTL (Time To Live) value (default is ten hours), you can send a request from within Dynamic Media to have the cache expire within minutes.
The following steps apply only to Dynamic Media - Scene7 mode in Adobe Experience Manager 6.5, Service Pack 6 (Experience Manager 6.5.6) or later. This CDN invalidation feature also requires that you use the out-of-the-box CDN that is bundled with Adobe Experience Manager - Dynamic Media. Any other custom CDN is not supported with this feature.
If you use Dynamic Media in Experience Manager 6.5, Service Pack 5 (Experience Manager 6.5.5) or earlier, follow the steps found in Invalidating the CDN cache by way of Dynamic Media Classic.
To invalidate your CDN cached content for Dynamic Media assets:
Part 1 of 2: Creating a CDN Invalidation template
In Experience Manager 6.5.6 or later, navigate to Tools > Assets > CDN Invalidation.
On the CDN Invalidation template page, do one of the following options based on your scenario:
|I have already created a CDN invalidation template in the past using Dynamic Media Classic.||The Create Template text field is pre-populated with your template data. In such case, you can either edit the template, or continue to the next step.|
|I have to create a template. What do I enter?||In the Create Template text field, enter an image URL (including image presets or modifiers) referencing
If the template contains just
Any presets/modifiers post
Only images - that is,
In this first example, the invalidation template contains
In this second example, the invalidation template contains the full URL of the asset used in your web properties with
Asset formats that are supported in Dynamic Media are eligible for invalidation. Asset file types that are not supported for CDN invalidation include PostScript®, Encapsulated PostScript®, Adobe Illustrator, Adobe InDesign, Microsoft® Powerpoint, Microsoft® Excel, Microsoft® Word, and Rich Text Format.
• When you create the template, but sure you pay careful attention to syntax and typos; Dynamic Media does not do any template validation.
• The CDN Invalidation Template can save text up to 2500 characters.
• Specify URLs for image smart crops either in this CDN Invalidation template, or in the Add URL text field in Part 2: Setting CDN Invalidation options.
• Each entry in a CDN Invalidation template must be on its own line.
• The following CDN Invalidation template example is for demonstration purposes only.
The CDN Invalidation Template can save text up to 2500 characters.
In the upper-right corner of the CDN Invalidation template page, select Save, then select OK.
Part 2 of 2: Setting CDN Invalidation options
In Experience Manager as a Cloud Service, select Tools > Assets > CDN Invalidation.
On the CDN Invalidation - Add Details page, select the assets for CDN invalidation.
If you decide to leave the options Invalidate asset associated image presets in CDN and Invalidate based on template unchecked, then the base URL of the selected assets is formed for invalidation. Use this option arrangement for images only.
|Invalidate asset associated image presets in CDN||(Optional) When you check this option, selected assets and all their associated image preset URLs are auto-formed for cache invalidation.
Assets and their associated pre-defined preset URLs are auto formed for invalidation. This option works only for image assets.
|Invalidation based on template||(Optional) Check this option to use only the defined template for URL formation.|
|Add Assets||Use the Asset Picker to select assets you want to invalidate. You can select either published or unpublished assets.
Caching at the CDN is URL-based, not asset-based. Therefore, it is necessary for you to be aware of the complete URLs that are on your website. After you determine those URLs, you can add them to the template. Then, you can select and add those assets and invalidate the URLs in one step.
Use this option with Invalidate asset associated image presets in CDN, or Invalidation based on template, or both.
|Add URL||Manually add or paste full URL paths to Dynamic Media assets whose CDN cache you want to invalidate. Use this option if you did not create a CDN Invalidation Template in Part 1 of 2: Creating a CDN Invalidation template, and have only a few assets to invalidate.
Important: Each URL that you add must be on its own line.
You can invalidate up to 1000 URLs at a give time. If the number of URLs in the Add URL text field is greater than 1000, you are unable to select Next. In such cases, you must select X to the right of a selected asset or a manually added URL to delete it from the invalidation list.
Specify URLs for image smart crops either in the CDN Invalidation template, or in this Add URL text field.
Near the upper-right corner of the page, select Next.
On the CDN Invalidation - Confirm page, in the URLs list box, you can see a list of one or more URLs generated from the CDN Invalidation Template you created earlier and the assets you just added.
For example, using the CDN Invalidation Template example that was shown in the steps earlier, suppose you added a single asset named
spinset. When you navigate to Tools > Assets > CDN Invalidation, it results in the following five generated URLs in the CDN Invalidation - Confirm user interface:
If necessary, select X to the right of a URL to delete it from invalidation process.
Near the upper-right corner of the page, select Submit to begin the CDN invalidation process.
In all cases, either the entire batch is processed for invalidation, or the entire batch is failed.
|Failed to retrieve URLs for selected assets.||Occurs if any of the following scenarios are met:
- A Dynamic Media configuration is not found.
- There is an exception while retrieving a service user through which the Dynamic Media configuration is read.
- The Publish server or the company root used to form the URLs is missing in the Dynamic Media configuration.
|Some URLs are not defined correctly. Correct and resubmit.||Occurs if the IPS CDN cache invalidation API returns an error that the URL is referring to a different company. Or, if the URL is not valid as per the validation done by the IPS
|Failed to invalidate CDN cache.||Occurs if the CDN cache invalidation request fails for any other reason.|
|No URLs entered to be invalidated.||Occurs if there are no URLs present in the CDN Invalidation - Confirm page, and you select Submit.|