Introducing the Ability to Purge by Cache Tag
The new purge by cache tag functionality in Akamai’s Fast Purge is now available to all Akamai content delivery product customers. To get to this point, we went through an exciting, year-long beta with more than 200 participants purging ~200,000,000 tags. During this time, we noted some fascinating (and surprising) ways that customers leveraged tags in their caching strategy -- we’ll share our six favorite here.
But first, some background on cache tags, and why you’ll love this new functionality. Cache tags are a convenient way to update cached content on edge servers. If you have a collection of objects that tend to be refreshed at the same time, you can now associate them collectively with a single cache tag that allows you to purge all content possessing this tag with a single request. Now you can purge cached content by calling it with a natural-language identifier rather than a technical identifier (e.g., URL or CP code) -- a new level of control while making the purge process simpler, faster, and more efficient.
And now, without further ado...our top six purge by cache tag scenarios.
Top use cases
1) Purging content in real time during live events
A high-traffic sports website talked to us about how they are using tags to keep their website updated during live sporting events in real time. The website tracks live scores, player and team dashboards, stats around tournament standings, play-by-play updates, and more across multiple simultaneous sporting events, requiring multiple assets on the website to be updated in real time. In the past, this volume of real-time updates would require the website’s dev team to batch-process 500+ URLs. With cache tags, a single tag can be associated with all of these assets and the website can be seamlessly updated on the fly.
2) Purging content across many clients
A global digital leader with a public-facing service that provides context-based, highly personalized tutorials for their products leverages cache tags to group the content across different clients. The tutorials -- in the form of a JSON Blob -- are consumed by many different mobile and desktop clients. By leveraging a client ID served on request, the clients know how to render these tutorials. When a tutorial is updated (which happens often), the out-of-date content must be invalidated and refreshed. Grouping the content with cache tags allows updates in real time with a single request for a more efficient and dynamic content refresh strategy.
3) Purging product content in online retail
Cache tags play a critical role when it comes to retail websites. Often a single product (identified by a product ID) is spread across multiple domains, catalogs, product lines, and even third-party sites. Keeping track of these various locations can be extremely challenging -- retail participants in our beta program often had tens of thousands of products spread across hundreds of locations. This can be a nightmare when it comes to content updates, particularly those around critical events such as flash sales, new offers, inventory updates, and pricing updates. Our participants leveraged cache tags to tag assets with product IDs so every time a particular product needed an update, the dev team simply purged the product ID tag associated with it.
4) Purging related images
Cache tags are an extremely powerful tool when it comes to image management. Serving web content today often involves dealing with many renditions of a single image -- these variations can include everything from different thumbnail sizes (often tailored to devices or clients), multiple operating systems, the requirements of third-party sites, and more. Updating an image usually means all these variants need to be changed at the same time, making purging groups of related images via a cache tag extremely efficient with both infrastructure and dev resources.
5) Purging sub-customers for software as a service (SaaS) providers
A few of our beta participants were leading SaaS providers who regularly dealt with refreshing content for thousands of customers. NowFloats, a premier Indian SaaS provider that enables businesses to control their online presence, has about 250,000 customers today. The dev team at NowFloats applied the new purge by cache tag functionality to group content for each of these customers by assigning a unique tag and then purging that tag when the content needed to be updated live.
6) Purging content via a Drupal plugin
As author Josh Waihi put it in a recent Acquia blog post, “Cache tags are a game-changer for your caching strategy in Drupal 8.” A number of our beta participants wanted to bring Drupal 8 into their content management system (CMS) strategy and they found that cache tags were the only way to make it happen. Our friends at cloud computing services leader Rackspace went a step further, building an Akamai provider plugin for Drupal 8 to deliver a more seamless content management experience. When editing content in Drupal, the provider that Rackspace built enables node grouping to refresh many dependent nodes at the same time. This ensures that end users are as productive as possible around updating their content in real time.
Learn more
Every day, development teams around the world rely on Akamai’s Fast Purge to help them purge content in a matter of seconds. Now, purging content via cache tags opens up additional cache strategies that give you greater control and allow you to maximize offload, performance, and operational efficiency.
To learn more about how you can leverage tags within your Akamai caching setups, check out Akamai web performance architect Tim Vereecke’s fantastic blog post, "A Technical Deep Dive into Purging by Cache Tag."
In addition, I encourage you to browse these other helpful resources: