Skip to content

Manifest cache one key per file doesn't make any sense #11525

@lekoala

Description

@lekoala

Description

Currently, there is one cache key per file as per

$key = preg_replace('/[^a-zA-Z0-9_]/', '_', $basename ?? '') . '_' . md5_file($pathname ?? '');

i don't know if it's the case for others, but in my case, most of the cache ends up in one file, while 2342 get created

image

this leads to a lot of I/O when using file based cache

there should be a way to have only one key being used. this would allow to load the cache from file only once, not having to make a cache hit for each single file
actually, i believe what is supposed to be lighter (one key per file to only change the files that have been changed) actually leads to a much heavier process when you could simply dump the whole array only once.

Additional context or points of discussion

No response

Validations

  • You intend to implement the feature yourself
  • You have read the contributing guide
  • You strongly believe this feature should be in core, rather than being its own community module
  • You have checked for existing issues or pull requests related to this feature (and didn't find any)

PRs

Metadata

Metadata

Assignees

Labels

No labels
No labels

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions