This project is not covered by Drupal’s security advisory policy.

This module queues URLs or paths to your Purge queue.

Drupal 8 introduces tag-based cache invalidation which is much more efficient than legacy URL or path based invalidation and leads to less processing and smaller queues. However, when your CDN or external caching system does not support tag-based invalidation, this module is for you!

How it works

The module trains its traffic registry by collecting URLs from requests that miss cache inside Drupal's own page cache. These URLs are stored along with their associated cache tags inside this same traffic registry. Now when Drupal invalidates a set of tags because someone edited a page, these tags are used to fetch URLs from the registry and are added to the Purge queue.


Those that remember the cache expiration module for Drupal 7 are familiar with the side effects of some changes not being automatically detected. This module can guarantee very high accuracy since it simply leverages D8's highly innovative tags based caching architecture, which is thoroughly covered by tests that cover edge cases most site builders wouldn't think off. Examples of things that just work are pagers (/news/?page=10), RSS or Json views (/rss.xml) and any view or view block, like that one dynamic block placed on /contact that shows corporate press releases.

Getting started

  • Setup the Purge module.
  • Make sure that your purger(s) support URL or path invalidations.
  • drush en purge_queuer_url --yes
  • drush cset system.performance 31536000 (year)
  • drush cache-rebuild to empty Drupal's page cache.

To achieve accurate URL based cache invalidation, it is best to take a head start by training the traffic registry that purge_queuer_url maintains:

wget -r -nd --delete-after -l100 --spider http://mydrupalsite/

When this process finished, editing any item on your site should result in several URLs being added to the Purge queue (see drush p-queue-browse). Ordinary website traffic will automatically add new URLs to your traffic registry and won't require any further maintenance.

Supporting organizations: 

Project Information