Problem/Motivation
Bunny needs a "CDN-Tag" header to be able to purge cache based on tags. This modules adds the needed tag using an Event Subscriber which takes the tags available in the response's cache metadata.
The Purger module has a similar mechanism based on PurgeTagsHeader plugins. Somme issues (eg. #2952277: Minify the cache tags sent in the header) are extending this plugin system to alter tags before putting them in the header. By implementing our own logic here, we prevent these alterations to be effective.
Proposed resolution
Replace the event subscriber by a PurgeTagsHeader plugin.
| Comment | File | Size | Author |
|---|
Issue fork bunny_cdn-3592362
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
Comments
Comment #3
duaelfrAttached patch for composer.
Comment #4
duaelfrComment #5
dieterholvoet commentedIs this
PurgeTagsHeaderplugin enabled automatically? If not, we'll need to add an update hook that enables this on existing installations, so the header doesn't disappear for them after updating the module.Comment #7
dieterholvoet commentedI tested and it automatically adds the header when using the Bunny CDN purger plugin, no extra configuration necessary.
Comment #9
duaelfrThank you for your review and commit.
You're absolutely right. This plugin is dependent of the Bunny purger plugin so it's enabled automatically. Isn't it convenient? ;)