X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=src%2FCore%2FCache%2FProfilerCache.php;h=7c4802077ab07d99b1ae9db724854f34425fa109;hb=ee8689cc899beecaf0943ac175550a7fb49cf199;hp=d59b885609d6947766c8fceb216dd8d8cfd49df6;hpb=6b7dfd0c712bc89de955a735fcbca60dc973d71d;p=friendica.git diff --git a/src/Core/Cache/ProfilerCache.php b/src/Core/Cache/ProfilerCache.php index d59b885609..7c4802077a 100644 --- a/src/Core/Cache/ProfilerCache.php +++ b/src/Core/Cache/ProfilerCache.php @@ -1,4 +1,23 @@ . + * + */ namespace Friendica\Core\Cache; @@ -37,7 +56,7 @@ class ProfilerCache implements ICache, IMemoryCache $return = $this->cache->getAllKeys($prefix); - $this->profiler->saveTimestamp($time, 'cache', System::callstack()); + $this->profiler->saveTimestamp($time, 'cache'); return $return; } @@ -51,7 +70,7 @@ class ProfilerCache implements ICache, IMemoryCache $return = $this->cache->get($key); - $this->profiler->saveTimestamp($time, 'cache', System::callstack()); + $this->profiler->saveTimestamp($time, 'cache'); return $return; } @@ -59,13 +78,13 @@ class ProfilerCache implements ICache, IMemoryCache /** * {@inheritDoc} */ - public function set($key, $value, $ttl = Cache::FIVE_MINUTES) + public function set($key, $value, $ttl = Duration::FIVE_MINUTES) { $time = microtime(true); $return = $this->cache->set($key, $value, $ttl); - $this->profiler->saveTimestamp($time, 'cache', System::callstack()); + $this->profiler->saveTimestamp($time, 'cache'); return $return; } @@ -79,7 +98,7 @@ class ProfilerCache implements ICache, IMemoryCache $return = $this->cache->delete($key); - $this->profiler->saveTimestamp($time, 'cache', System::callstack()); + $this->profiler->saveTimestamp($time, 'cache'); return $return; } @@ -93,7 +112,7 @@ class ProfilerCache implements ICache, IMemoryCache $return = $this->cache->clear($outdated); - $this->profiler->saveTimestamp($time, 'cache', System::callstack()); + $this->profiler->saveTimestamp($time, 'cache'); return $return; } @@ -101,14 +120,14 @@ class ProfilerCache implements ICache, IMemoryCache /** * {@inheritDoc} */ - public function add($key, $value, $ttl = Cache::FIVE_MINUTES) + public function add($key, $value, $ttl = Duration::FIVE_MINUTES) { if ($this->cache instanceof IMemoryCache) { $time = microtime(true); $return = $this->cache->add($key, $value, $ttl); - $this->profiler->saveTimestamp($time, 'cache', System::callstack()); + $this->profiler->saveTimestamp($time, 'cache'); return $return; } else { @@ -119,14 +138,14 @@ class ProfilerCache implements ICache, IMemoryCache /** * {@inheritDoc} */ - public function compareSet($key, $oldValue, $newValue, $ttl = Cache::FIVE_MINUTES) + public function compareSet($key, $oldValue, $newValue, $ttl = Duration::FIVE_MINUTES) { if ($this->cache instanceof IMemoryCache) { $time = microtime(true); $return = $this->cache->compareSet($key, $oldValue, $newValue, $ttl); - $this->profiler->saveTimestamp($time, 'cache', System::callstack()); + $this->profiler->saveTimestamp($time, 'cache'); return $return; } else { @@ -144,7 +163,7 @@ class ProfilerCache implements ICache, IMemoryCache $return = $this->cache->compareDelete($key, $value); - $this->profiler->saveTimestamp($time, 'cache', System::callstack()); + $this->profiler->saveTimestamp($time, 'cache'); return $return; } else {