Changeset View
Changeset View
Standalone View
Standalone View
src/applications/cache/PhabricatorCaches.php
| Show First 20 Lines • Show All 264 Lines • ▼ Show 20 Lines | foreach ($caches as $key => $cache) { | ||||
| $pcache = new PhutilKeyValueCacheProfiler($cache); | $pcache = new PhutilKeyValueCacheProfiler($cache); | ||||
| $pcache->setProfiler(PhutilServiceProfiler::getInstance()); | $pcache->setProfiler(PhutilServiceProfiler::getInstance()); | ||||
| $caches[$key] = $pcache; | $caches[$key] = $pcache; | ||||
| } | } | ||||
| return $caches; | return $caches; | ||||
| } | } | ||||
| private static function addNamespaceToCaches(array $caches) { | private static function addNamespaceToCaches(array $caches) { | ||||
| $namespace = PhabricatorCaches::getNamespace(); | $namespace = self::getNamespace(); | ||||
| if (!$namespace) { | if (!$namespace) { | ||||
| return $caches; | return $caches; | ||||
| } | } | ||||
| foreach ($caches as $key => $cache) { | foreach ($caches as $key => $cache) { | ||||
| $ncache = new PhutilKeyValueCacheNamespace($cache); | $ncache = new PhutilKeyValueCacheNamespace($cache); | ||||
| $ncache->setNamespace($namespace); | $ncache->setNamespace($namespace); | ||||
| $caches[$key] = $ncache; | $caches[$key] = $ncache; | ||||
| ▲ Show 20 Lines • Show All 66 Lines • Show Last 20 Lines | |||||