Documentation

Learn how to build, publish, and launch your site with Adobe Experience Manager.

Resources

Setup push invalidation for Akamai

Push invalidation automatically purges content on the customer's production CDN (e.g. www.yourdomain.com), whenever an author publishes content changes or a developer pushes code changes to the main branch (changes on other branches do not trigger push invalidation).

Content is purged by url and by cache tag/key.

Push invalidation is enabled by setting up the Akamai Fast Purge credentials in the cdn section of the configuration service.

curl --request POST \
  --url https://admin.hlx.page/config/{org}/sites/{site}/cdn.json \
  --header 'content-type: application/json' \
  --data '{
	"prod": {
		"host": "{production host}",
		"type": "akamai",
		"endpoint": "{akamai host}",
		"clientSecret": "{client_secret}",
		"clientToken": "{client_token}",
		"accessToken": "{access_token}"
	}
}'

Configuration properties:

key value comment
host <Production Host> Host name of production site, e.g. www.yourdomain.com
type akamai
endpoint <host>

Fast Purge API credentials

***.purge.akamaiapis.net

clientSecret <client_secret> Fast Purge API credentials
clientToken <client_token> Fast Purge API credentials
accessToken <access_token> Fast Purge API credentials

AEM push invalidation uses the Akamai Fast Purge API, specifically Delete by URL and Delete by cache tag.

The Fast Purge API credentials consist of

host = akaa-XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX.luna.akamaiapis.net
client_token = akab-XXXXXXXXXXXXXXXX-XXXXXXXXXXXXXXXX
client_secret = XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
access_token = akab-XXXXXXXXXXXXXXXX-XXXXXXXXXXXXXXXX

They can be generated by following the instructions at Create an API client with custom permissions.

Go to Identity & Access Management:

Create API client:



Required group/role permissions:

You can validate the credentials with this tool.

Special Mention - Akamai Edge-Control Headers

AEM uses a fine tuned, production hardened way to supply caching information that applies to the specific CDN, in conjunction with our reliable push invalidation. This allows us to improve cache efficiency and consistency over traditional TTL based approaches.


Every CDN vendor supports a way to directly influence how to instruct caching and we are excited to see standardization efforts like "Targeted Cache Control" (TCC) being on the roadmap for Akamai (see: https://www.akamai.com/blog/news/targeted-cache-control), in the meantime we are using Akamai's long-term supported Edge-Control header.