Skip to content

SIBPHP/Redis

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Redis

Redis manager based on php_redis extension Support master/slave mode through configuration

Installation

composer require "sframe/redis:*"

Configuration

1 Server

array(
    'host' => '',       // optional, default 127.0.0.1
    'port' => '',       // optional, default 6379
    'timeout' => 0,     // optional, default 0
    'persistent' => false, // optional, default false
)

1 Master and 1 Slave

array(
    'master' => array(
        ...
    ),
    'slave' => array(
        ...
    )
)

1 Master and Multi slaves

array(
    'master' => array(
        ...
    ),
    'slaves' => array(
        array(...),
        array(...),
        ...
    )
)

demo.php

$redis = new \SFrame\Redis\Redis();
$redis->set('hello', 1);
$redis->get('hello');
$redis->delete('hello');
...

About

Redis manager, Support master/slave mode

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages