awallef/cakephp-redis

There is no license information available for the latest version (3.4.0.3) of this package.

CakePHP redis caching & storage

Installs: 430

Dependents: 1

Suggesters: 1

Security: 0

Stars: 0

Watchers: 2

Forks: 0

Open Issues: 0

Type:cakephp-plugin

3.4.0.3 2017-09-12 10:49 UTC

This package is auto-updated.

Last update: 2024-05-16 20:17:43 UTC


README

This plugin allows you cache and store data in redis engine

Installation

You can install this plugin into your CakePHP application using composer.

The recommended way to install composer packages is:

composer require awallef/cakephp-redis

Load it in your config/boostrap.php

Plugin::load('Awallef/Redis');

Redis caching

This plugin provides a very little bit different redis engine based on cakephp's RedisEngine. differences are:

  • Engine config comes with a bool 'serialize' option ( default is true )
  • Read and wirte fct use config 'serialize' option
  • Keys are stored/read/deleted in order to uses : and :* redis skills!

Configure the engine in app.php like follow:

'Cache' => [
    ...
    'redis' => [
      'className' => 'Awallef/Redis.Redis',
      'prefix' => 'www.your-site.com:',
      'duration' => '+24 hours',
      'serialize' => true
    ],
    ...
]