mirror of
https://we.phorge.it/source/phorge.git
synced 2024-11-10 08:52:39 +01:00
Rename PhutilKeyValueCache
subclasses
Summary: Ref T5655. Depends on D10155. Test Plan: Ran `arc unit` Reviewers: epriestley, #blessed_reviewers Reviewed By: epriestley, #blessed_reviewers Subscribers: epriestley, Korvin Maniphest Tasks: T5655 Differential Revision: https://secure.phabricator.com/D10156
This commit is contained in:
parent
8fd098329b
commit
4e9746ed4e
2 changed files with 7 additions and 7 deletions
10
src/applications/cache/PhabricatorCaches.php
vendored
10
src/applications/cache/PhabricatorCaches.php
vendored
|
@ -54,7 +54,7 @@ final class PhabricatorCaches {
|
|||
private static function buildImmutableCaches() {
|
||||
$caches = array();
|
||||
|
||||
$apc = new PhutilKeyValueCacheAPC();
|
||||
$apc = new PhutilAPCKeyValueCache();
|
||||
if ($apc->isAvailable()) {
|
||||
$caches[] = $apc;
|
||||
}
|
||||
|
@ -80,11 +80,11 @@ final class PhabricatorCaches {
|
|||
private static function buildRepositoryGraphL1Caches() {
|
||||
$caches = array();
|
||||
|
||||
$request = new PhutilKeyValueCacheInRequest();
|
||||
$request = new PhutilInRequestKeyValueCache();
|
||||
$request->setLimit(32);
|
||||
$caches[] = $request;
|
||||
|
||||
$apc = new PhutilKeyValueCacheAPC();
|
||||
$apc = new PhutilAPCKeyValueCache();
|
||||
if ($apc->isAvailable()) {
|
||||
$caches[] = $apc;
|
||||
}
|
||||
|
@ -141,7 +141,7 @@ final class PhabricatorCaches {
|
|||
private static function buildSetupCaches() {
|
||||
// In most cases, we should have APC. This is an ideal cache for our
|
||||
// purposes -- it's fast and empties on server restart.
|
||||
$apc = new PhutilKeyValueCacheAPC();
|
||||
$apc = new PhutilAPCKeyValueCache();
|
||||
if ($apc->isAvailable()) {
|
||||
return array($apc);
|
||||
}
|
||||
|
@ -150,7 +150,7 @@ final class PhabricatorCaches {
|
|||
// much better than nothing; some setup steps are quite slow.
|
||||
$disk_path = self::getSetupCacheDiskCachePath();
|
||||
if ($disk_path) {
|
||||
$disk = new PhutilKeyValueCacheOnDisk();
|
||||
$disk = new PhutilOnDiskKeyValueCache();
|
||||
$disk->setCacheFile($disk_path);
|
||||
$disk->setWait(0.1);
|
||||
if ($disk->isAvailable()) {
|
||||
|
|
|
@ -5,7 +5,7 @@ abstract class DivinerDiskCache {
|
|||
private $cache;
|
||||
|
||||
public function __construct($cache_directory, $name) {
|
||||
$dir_cache = id(new PhutilKeyValueCacheDirectory())
|
||||
$dir_cache = id(new PhutilDirectoryKeyValueCache())
|
||||
->setCacheDirectory($cache_directory);
|
||||
$profiled_cache = id(new PhutilKeyValueCacheProfiler($dir_cache))
|
||||
->setProfiler(PhutilServiceProfiler::getInstance())
|
||||
|
@ -25,7 +25,7 @@ abstract class DivinerDiskCache {
|
|||
/**
|
||||
* Convert a long-form hash key like `ccbbaaaaaaaaaaaaaaaaaaaaaaaaaaaaN` into
|
||||
* a shortened directory form, like `cc/bb/aaaaaaaaN`. In conjunction with
|
||||
* @{class:PhutilKeyValueCacheDirectory}, this gives us nice directories
|
||||
* @{class:PhutilDirectoryKeyValueCache}, this gives us nice directories
|
||||
* inside .divinercache instead of a million hash files with huge names at
|
||||
* top level.
|
||||
*/
|
||||
|
|
Loading…
Reference in a new issue