Skip to content

[Caching] Add CacheMetaExtensionInterface for custom cache invalidation#7933

Open
ruudk wants to merge 1 commit intorectorphp:mainfrom
ruudk:cache-meta-extension
Open

[Caching] Add CacheMetaExtensionInterface for custom cache invalidation#7933
ruudk wants to merge 1 commit intorectorphp:mainfrom
ruudk:cache-meta-extension

Conversation

@ruudk
Copy link
Contributor

@ruudk ruudk commented Mar 22, 2026

Same mechanism as PHPStan's ResultCacheMetaExtension: extensions implement getKey() and getHash() to provide additional metadata that is folded into the file cache key. When any extension's hash changes, all cached files are reprocessed.

My use case is that I have a rector that operates on cache file that is generated by another process. Whenever the file changes, Rector should pick it up and re-process all files.

Same mechanism as PHPStan's ResultCacheMetaExtension — extensions implement getKey() and getHash() to provide additional metadata that is folded into the file cache key. When any extension's hash changes, all cached files are reprocessed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant