mirror of
https://github.com/AzuraCast/AzuraCast.git
synced 2024-06-13 12:46:41 +00:00
Revert service configuration change.
This commit is contained in:
parent
c6aa34f65f
commit
1a1ef5f013
|
@ -136,7 +136,14 @@ return [
|
|||
Doctrine\ORM\EntityManagerInterface::class => DI\Get(App\Doctrine\DecoratedEntityManager::class),
|
||||
|
||||
// Cache
|
||||
Psr\Cache\CacheItemPoolInterface::class => DI\autowire(Cache\Adapter\Redis\RedisCachePool::class),
|
||||
Psr\Cache\CacheItemPoolInterface::class => function (App\Settings $settings, Psr\Container\ContainerInterface $di) {
|
||||
// Never use the Redis cache for CLI commands, as the CLI commands are where
|
||||
// the Redis cache gets flushed, so this will lead to a race condition that can't
|
||||
// be solved within the application.
|
||||
return $settings->enableRedis() && !$settings->isCli()
|
||||
? new Cache\Adapter\Redis\RedisCachePool($di->get(Redis::class))
|
||||
: new Cache\Adapter\PHPArray\ArrayCachePool;
|
||||
},
|
||||
Psr\SimpleCache\CacheInterface::class => DI\get(Psr\Cache\CacheItemPoolInterface::class),
|
||||
|
||||
// Doctrine cache
|
||||
|
|
Loading…
Reference in New Issue
Block a user