smoke / zf2-cache-storage-redis-array
RedisArray Cache Storage for Zend Framework 2
Installs: 26 462
Dependents: 0
Suggesters: 0
Security: 0
Stars: 6
Watchers: 2
Forks: 2
Open Issues: 0
Requires
- php: ^5.5 || ^7.0
- ext-redis: >=2.2.3
- zendframework/zend-cache: ^2.0
Requires (Dev)
- cache/integration-tests: ^0.16.0
- phpunit/phpunit: ^4.8.36 || ^5.7.27 || ^6.5.8 || ^7.1.2
- squizlabs/php_codesniffer: ^3.3
- zendframework/zend-serializer: ^2.7
This package is not auto-updated.
Last update: 2024-12-21 17:27:42 UTC
README
This is RedisArray Cache Storage Adapter component for ZF2 inspired by \Zend\Cache\Storage\Adapter\Redis
Installation
This module only officially supports installation through Composer. For Composer documentation, please refer to getcomposer.org.
You can install the module from command line:
$ php composer.phar require smoke/zf2-cache-storage-redis-array:1.0.*
Alternatively, you can also add manually the dependency in your composer.json
file:
{ "require": { "smoke/zf2-cache-storage-redis-array": "1.0.*" } }
Configuration settings
In your config/autoload/redis-array.php put the following settings to define the servers_array:
return array( 'caches' => array( 'Cache\General' => array( 'adapter' => array( 'name' => '\Smoke\Cache\Storage\Adapter\RedisArray' ), 'options' => array( 'servers_array' => array( array('host' => 'host1'/*, 'port' => 1234*/), array('host' => 'host2') ), //'lazy_connect' => true, //'connect_timeout' => 15 ), ), ), );
For the rest of the ZF2 Cache Factory needed settings follow http://framework.zend.com/manual/2.3/en/modules/zend.cache.storage.adapter.html
LICENSE
The files in this archive are released under the MIT license. You can find a copy of this license in LICENSE.txt.