Problem/Motivation

We can reduce file I/O and calls to the 'identify' ImageMagick's binary by caching its results.

Proposed resolution

Integrate with the File Metadata Manager module, implement a plugin for the identify command results.
The patch below introduces a dependency to file_mdm

Remaining tasks

Review/feedback.

User interface changes

Several changes to the image toolkit settings' subform - to make it more readable given new addtions of caching options.

API changes

No changes to the methods called by image toolkit operations.
Some changes internal to the module, but I doubt there are out there classes extending imagemagick's classes.

Data model changes

Added some keys to the config schema, to allow capturing caching options.

CommentFileSizeAuthor
#8 2749283-8.patch67.34 KBmondrake
#7 2749283-7.patch68.15 KBmondrake
#2 2749283-2.patch68.42 KBmondrake
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

mondrake created an issue. See original summary.

mondrake’s picture

Status: Active » Needs review
FileSize
68.42 KB

Patch.

Status: Needs review » Needs work

The last submitted patch, 2: 2749283-2.patch, failed testing.

mondrake’s picture

Status: Needs work » Needs review

#2 failed because the 'file_mdm' dependency is part of the patch, and in fact DrupalCI requires the dependency to be already set in the repo before adding dependent code :(

In any case, d.o. test are of very little relevance since most of the test code is bypassed when the ImageMagick's executable cannot be executed, which is the case of the test bots. Tests pass locally, though.

mondrake’s picture

Changes in this issue will be too big for version 1, my plan is to introduce a dependency to the File metadata manager module and Composer based dependency management.

Opened a 8.x-2.x branch where this could be managed better separately.

mondrake’s picture

Version: 8.x-1.x-dev » 8.x-2.x-dev
mondrake’s picture

FileSize
68.15 KB

Reupload of patch in #2 without the additional dependency in .info.yml which have been applied in 8.x-2.x already.

mondrake’s picture

FileSize
67.34 KB

Rerolled

  • mondrake committed f57fa63 on 8.x-2.x
    Issue #2749283 by mondrake: Enable caching of ::parseFile results to...
mondrake’s picture

Status: Needs review » Fixed

Committed to 8.x-2.x

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.