Leverage Akamai's purge request tracking API

Created on 21 July 2014, over 10 years ago
Updated 29 July 2024, 3 months ago

The Akamai CCU REST API now supports purge request tracking. For some use cases, it may be beneficial for a site to verify that a purge for a URL or set of URLs has completed, either for auditing purposes, or to ensure that duplicates of previously requested URLs that haven't yet been purged aren't re-requested until the preceding request for a given URL has been verified by Akamai.

As an anecdotal example, a client site shares a single Akamai purge queue amongst several properties. Depending on the number of requests in the queue at any given time and/or the load on Akamai's network, we've seen purge requests from these sites take anywhere from minutes to several hours to complete. In the latter case, it'd be useful not to "dogpile" on the purge request queue with a number of URLs that might already be pending a purge.

We are likely going to implement some type of purge request tracking for a client site and are happy to lead an effort to contribute this to the contrib module, but wanted to check in and see if this feature might be useful to other users of this contrib module before we proceed. If we're not duplicating work already in progress, it would be nice to get some feedback/guidance from the module maintainers as to whether or not this would be more useful as a sub-module, as an optional feature in the main akamai module, or as a separate sandbox module.

A high-level description of the feature might look something like:

* Admins enable the optional feature of Akamai purge request tracking
* Admins may also enable the purge request tracker's "do not request duplicates" feature
* When purge tracking is enabled, individual URLs are tracked with the associated purge request tracking ID returned by the Akamai API and the Akamai-provided "should be complete by" timestamp
* On cron runs, the module will check Akamai for all unconfirmed purge requests whose "should be complete by" timestamp is in the past.
* Verified purges are marked as such in the log table
* Confirmed purges older than a configurable threshold date are purged to keep the log data size in check
* If "do not request duplicates" is enabled, each purge request is checked for URLs that are associated with an unconfirmed/pending purge request. When found, duplicate URLs are stripped from the purge request sent to Akamai. If only duplicate URLs were in the purge request, no request is sent to Akamai.

One note is that this feature assumes that there is no automatic de-duplication of requested URLs in its queue. We'll be sure to verify this with Akamai before adding the client-side deduplication option.

✨ Feature request
Status

Closed: outdated

Version

2.0

Component

Code

Created by

πŸ‡ΊπŸ‡ΈUnited States bdurbin

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

Production build 0.71.5 2024