drupal / predis
There is no license information available for the latest version (0.1) of this package.
0.1
2014-07-13 02:41 UTC
Requires
- predis/predis: dev-master
This package is auto-updated.
Last update: 2026-02-24 07:54:13 UTC
README
This module provides a service connection to Redis using Predis library, this module only provides a service to be used in other modules.
How to install
This module need predis in the root composer.json
$ composer require predis/predis:~0.8.0
How to use
# my_module.services.yml services: my_module.connection: class: Drupal\my_module\Connection arguments: ['@predis.connection']
use Drupal\predis\RedisConnectionInterface; // ... public function __construct(RedisConnectionInterface $redis) { $this->redis = $redis->getConnection(); } // ...