GSP
Quick Navigator

Search Site

Unix VPS
A - Starter
B - Basic
C - Preferred
D - Commercial
MPS - Dedicated
Previous VPSs
* Sign Up! *

Support
Contact Us
Online Help
Handbooks
Domain Status
Man Pages

FAQ
Virtual Servers
Pricing
Billing
Technical

Network
Facilities
Connectivity
Topology Map

Miscellaneous
Server Agreement
Year 2038
Credits
 

USA Flag

 

 

Man Pages


Manual Reference Pages  -  REDISDB::SENTINEL (3)

.ds Aq ’

NAME

RedisDB::Sentinel - interface to redis servers managed by sentinel

CONTENTS

SYNOPSIS



    use RedisDB::Sentinel;

    my $redis = RedisDB::Sentinel->connect_to_master(
        service => $service_name,
        sentinels => [
            {
                host => host1,
                port => 26379
            },
            {
                host => host2,
                port => 26379
            },
        ],
    );
    $redis->set( $key, $value );
    my $value = $redis->get($key);



DESCRIPTION

This module provides interface to access redis servers managed by sentinels, it handles communication with sentinels and dispatches commands to the master redis.

METHODS

CW$class->connect_to_master(%params)

retrieve information about master from sentinel and return RedisDB object connected to master. Additionally sets on_conect_error handler to retrieve information about new master in case of reconnect. Requires two parameters:
<B>serviceB> service name to which you want to connect
<B>sentinelsB> list of sentinels. Each element is a hash with host and port elements.
Other parameters are passed as is to constructor of RedisDB object. Note, that host, port, and on_connect_error parameters will be overwritten by RedisDB::Sentinel

AUTHOR

Pavel Shaydo, <zwon at cpan.org>

LICENSE AND COPYRIGHT

Copyright 2011-2015 Pavel Shaydo.

This program is free software; you can redistribute it and/or modify it under the terms of either: the GNU General Public License as published by the Free Software Foundation; or the Artistic License.

See http://dev.perl.org/licenses/ for more information.

Search for    or go to Top of page |  Section 3 |  Main Index


perl v5.20.3 REDISDB::SENTINEL (3) 2015-08-03

Powered by GSP Visit the GSP FreeBSD Man Page Interface.
Output converted with manServer 1.07.