Refactor of Varnish image purge and reduce the number of requests

Created on 21 September 2020, about 4 years ago
Updated 26 February 2024, 10 months ago

Problem/Motivation

I have a migration of products that have some images per product. The Varnish Image Purge module was causing a lot of requests to Varnish in order to purge all image styles per a single image, what means that a migration can have a lot of images will have a lot of requests to Varnish.

Steps to reproduce

Update/create a lot of content with images

Proposed resolution

I have seen that the Varnish Image Purge and the Varnish Focal Point were not using the Purge framework, so, it was impossible to implement a queue and get the advantage of the purge module.

* First would be to use the Purge framwork creating a Purger with the URIBAN method
* Limit the number of image styles to the ones that are used for those images and not to all image styles of the site

Remaining tasks

* Dependency Injection of some services
* Add an update support since we are changing how varnish_image_purge is working
* Remove the varnish_focal_point_purge because it can be handle with the varnish_image_purge

User interface changes

API changes

* We will need a new configuration to be able to use varnish_image_purge

Data model changes

✨ Feature request
Status

Needs review

Version

2.0

Component

Code

Created by

πŸ‡ͺπŸ‡ΈSpain jjcarrion Spain

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