When \Drupal\cloudinary_stream_wrapper\StreamWrapper\CloudinaryStreamWrapper::loadResource is invoked, it loads the resource. If the storage submodule is enabled, this is a previously cached version of the image.

The problem is that the version is then passed to the URL which is generated. If the image was updated in Cloudinary, the Drupal image is now stale. The is also a problem if the format is stored.

The data contains "format" and "version" which gets passed to \Cloudinary::cloudinary_url

        $version = Cloudinary::option_consume($options, "version");
        $format = Cloudinary::option_consume($options, "format");

This is causing stale images, unless you implement a webhook to purge/update these records.

CommentFileSizeAuthor
#2 3030818-2.patch889 bytesmglaman

Comments

mglaman created an issue. See original summary.

mglaman’s picture

Status: Active » Needs review
StatusFileSize
new889 bytes

Here is a patch.

daniel kulbe’s picture

This code is commented out in latest dev.