(dev/cloud-native#3) SerializeCache - Remove unused, incomplete cache-driver #14717
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Overview
The class
CRM_Utils_Cache_SerializeCache
provides a cache-driver forstoring cache records in the filesystem (under
CIVICRM_TEMPLATE_COMPILEDIR
,using PHP
serialize()
format). Why remove it?As we work through cleanup in file management (e.g. Lookup path-variable for the private filepath #12843,
dev/cloud-native#3), having an unnecessary reference to
CIVICRM_TEMPLATE_COMPILEDIR makes it harder to reason about the system.
The class is not used. I'm pretty sure it was added speculatively
(i.e. with an aim to try using it some day), but that never came to
pass. Grepping
universe
, I cannot find any usages or references toSerializeCache
.The implementation is incomplete -- parameters like
get(..., $default)
and
set(..., $ttl)
will generate exceptions if used.Before
After