remove file cache remainings from server container

This commit is contained in:
Arthur Schiwon 2015-05-13 11:58:19 +02:00
parent d6becb8d82
commit e5a91fc185
1 changed files with 7 additions and 5 deletions

View File

@ -38,13 +38,13 @@ use bantu\IniGetWrapper\IniGetWrapper;
use OC\AppFramework\Http\Request; use OC\AppFramework\Http\Request;
use OC\AppFramework\Db\Db; use OC\AppFramework\Db\Db;
use OC\AppFramework\Utility\SimpleContainer; use OC\AppFramework\Utility\SimpleContainer;
use OC\Cache\UserCache;
use OC\Command\AsyncBus; use OC\Command\AsyncBus;
use OC\Diagnostics\NullQueryLogger; use OC\Diagnostics\NullQueryLogger;
use OC\Diagnostics\EventLogger; use OC\Diagnostics\EventLogger;
use OC\Diagnostics\QueryLogger; use OC\Diagnostics\QueryLogger;
use OC\Mail\Mailer; use OC\Mail\Mailer;
use OC\Memcache\ArrayCache; use OC\Memcache\ArrayCache;
use OC\Memcache\Null as NullCache;
use OC\Http\Client\ClientService; use OC\Http\Client\ClientService;
use OC\Security\CertificateManager; use OC\Security\CertificateManager;
use OC\Files\Node\Root; use OC\Files\Node\Root;
@ -217,8 +217,8 @@ class Server extends SimpleContainer implements IServerContainer {
$this->registerService('AppHelper', function ($c) { $this->registerService('AppHelper', function ($c) {
return new \OC\AppHelper(); return new \OC\AppHelper();
}); });
$this->registerService('UserCache', function ($c) { $this->registerService('NullCache', function ($c) {
return new UserCache(); return new NullCache();
}); });
$this->registerService('MemCacheFactory', function (Server $c) { $this->registerService('MemCacheFactory', function (Server $c) {
$config = $c->getConfig(); $config = $c->getConfig();
@ -646,12 +646,14 @@ class Server extends SimpleContainer implements IServerContainer {
} }
/** /**
* Returns an ICache instance * Returns an ICache instance. Since 8.1.0 it returns a fake cache. Use
* getMemCacheFactory() instead.
* *
* @return \OCP\ICache * @return \OCP\ICache
* @deprecated 8.1.0 use getMemCacheFactory to obtain a proper cache
*/ */
public function getCache() { public function getCache() {
return $this->query('UserCache'); return $this->query('NullCache');
} }
/** /**