diff options
author | michael-grunder <michael.grunder@gmail.com> | 2014-07-09 07:14:18 +0400 |
---|---|---|
committer | michael-grunder <michael.grunder@gmail.com> | 2015-05-06 01:02:04 +0300 |
commit | 488cd3c3163be2178fe3354b2304b16fd874ffda (patch) | |
tree | 10b200de2622994cc03343b04774dee55b77af0c /redis_cluster.h | |
parent | 4462913cb7b9e46034c719df220cf85f6c400a25 (diff) |
SCAN command
Initial commit of the SCAN command for cluster. As a first iteration,
the command takes a host:port string (which can be retreived from the
introspection method RedisCluster::_masters()), to scan either
everything in the cluster (e.g. in a loop), or one in particular.
A simple way to scan everything in the whole cluster Keyspace
$obj_c->setOption(RedisCluster::OPT_SCAN, RedisCluster::SCAN_RETRY);
foreach($obj_c->_masters() as $str_hash) {
$it = NULL;
while($arr = $obj_c->scan($it, $str_hash)) {
foreach($arr as $key) {
echo "$str_hash -> " . $key . "\n";
}
}
}
Diffstat (limited to 'redis_cluster.h')
0 files changed, 0 insertions, 0 deletions