mirror of
https://github.com/nextcloud/server.git
synced 2026-06-06 23:34:22 -04:00
feat: add option to disable scanner transactions
Signed-off-by: Robin Appelman <robin@icewind.nl>
This commit is contained in:
parent
c23002bd76
commit
e93017d308
1 changed files with 5 additions and 1 deletions
|
|
@ -39,6 +39,7 @@ use Doctrine\DBAL\Exception;
|
|||
use OC\Files\Storage\Wrapper\Encryption;
|
||||
use OC\Files\Storage\Wrapper\Jail;
|
||||
use OC\Hooks\BasicEmitter;
|
||||
use OC\SystemConfig;
|
||||
use OCP\Files\Cache\IScanner;
|
||||
use OCP\Files\ForbiddenException;
|
||||
use OCP\Files\NotFoundException;
|
||||
|
|
@ -95,7 +96,10 @@ class Scanner extends BasicEmitter implements IScanner {
|
|||
$this->storage = $storage;
|
||||
$this->storageId = $this->storage->getId();
|
||||
$this->cache = $storage->getCache();
|
||||
$this->cacheActive = !\OC::$server->getConfig()->getSystemValueBool('filesystem_cache_readonly', false);
|
||||
/** @var SystemConfig $config */
|
||||
$config = \OC::$server->get(SystemConfig::class);
|
||||
$this->cacheActive = !$config->getValue('filesystem_cache_readonly', false);
|
||||
$this->useTransactions = !$config->getValue('filescanner_no_transactions', false);
|
||||
$this->lockingProvider = \OC::$server->getLockingProvider();
|
||||
$this->connection = \OC::$server->get(IDBConnection::class);
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue