Change the DrupalApcCache methods

Created on 22 July 2024, about 2 months ago
Updated 7 August 2024, about 1 month ago

DrupalApcCache::getPrefixSettingForBin() gets a string containing a bin name, and it returns a prefix for that bin.
Since that method is only called from the constructor and since each instance of DrupalApcCache handles the values contained in a specific bin, DrupalApcCache::getPrefixSettingForBin() should:

  • Be renamed to DrupalApcCache::setBinPrefix()
  • Its code be changed to set $this->prefix
  • Be made a non static method

Furthermore, the following methods should be added:

  • DrupalApcCache::addDatabasePrefix() adds the database prefix if DrupalApcCache::setBinPrefix() sets $this->prefix to an empty string.
  • DrupalApcCache::addModulePrefix() adds a prefix specific for the Alternative PHP Cache module for cache keys.
📌 Task
Status

Fixed

Version

1.0

Component

Code

Created by

🇮🇹Italy apaderno Brescia, 🇮🇹

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Merge Requests

Comments & Activities

Production build 0.71.5 2024