@@ -5,7 +5,7 @@ use strict;
5
5
use warnings;
6
6
use base qw( Exporter ) ;
7
7
8
- our $VERSION = ' 0.24 ' ;
8
+ our $VERSION = ' 0.25_01 ' ;
9
9
10
10
use AnyEvent::RipeRedis::Error;
11
11
@@ -114,7 +114,7 @@ sub new {
114
114
115
115
$self -> connection_timeout( $params {connection_timeout } );
116
116
$self -> read_timeout( $params {read_timeout } );
117
- $self -> min_reconnect_interval ( $params {min_reconnect_interval } );
117
+ $self -> reconnect_interval ( $params {reconnect_interval } );
118
118
$self -> on_error( $params {on_error } );
119
119
120
120
$self -> _reset_internals;
@@ -182,7 +182,7 @@ sub on_error {
182
182
}
183
183
184
184
foreach my $name ( qw( connection_timeout read_timeout
185
- min_reconnect_interval ) )
185
+ reconnect_interval ) )
186
186
{
187
187
*{$name } = sub {
188
188
my $self = shift ;
@@ -562,12 +562,12 @@ sub _execute {
562
562
$self -> _connect;
563
563
}
564
564
elsif ( $self -> {reconnect } ) {
565
- if ( defined $self -> {min_reconnect_interval }
566
- && $self -> {min_reconnect_interval } > 0 )
565
+ if ( defined $self -> {reconnect_interval }
566
+ && $self -> {reconnect_interval } > 0 )
567
567
{
568
568
unless ( defined $self -> {_reconnect_timer } ) {
569
569
$self -> {_reconnect_timer } = AE::timer(
570
- $self -> {min_reconnect_interval }, 0,
570
+ $self -> {reconnect_interval }, 0,
571
571
sub {
572
572
undef $self -> {_reconnect_timer };
573
573
$self -> _connect;
@@ -1065,14 +1065,14 @@ Requires Redis 1.2 or higher, and any supported event loop.
1065
1065
=head2 new( %params )
1066
1066
1067
1067
my $redis = AnyEvent::RipeRedis->new(
1068
- host => 'localhost',
1069
- port => 6379,
1070
- password => 'yourpass',
1071
- database => 7,
1072
- connection_timeout => 5,
1073
- read_timeout => 5,
1074
- lazy => 1,
1075
- min_reconnect_interval => 5,
1068
+ host => 'localhost',
1069
+ port => 6379,
1070
+ password => 'yourpass',
1071
+ database => 7,
1072
+ connection_timeout => 5,
1073
+ read_timeout => 5,
1074
+ lazy => 1,
1075
+ reconnect_interval => 5,
1076
1076
1077
1077
on_connect => sub {
1078
1078
# handling...
@@ -1161,12 +1161,12 @@ you need. Such behavior allows to control reconnection procedure.
1161
1161
1162
1162
Enabled by default.
1163
1163
1164
- =item min_reconnect_interval => $fractional_seconds
1164
+ =item reconnect_interval => $fractional_seconds
1165
1165
1166
- If the parameter is specified, the client will try to reconnect not often, than
1167
- after this interval. Commands executed between reconnections will be queued.
1166
+ If the parameter is specified, the client will try to reconnect only after
1167
+ this interval. Commands executed between reconnections will be queued.
1168
1168
1169
- min_reconnect_interval => 5,
1169
+ reconnect_interval => 5,
1170
1170
1171
1171
Not set by default.
1172
1172
@@ -1792,9 +1792,9 @@ Get or set the C<read_timeout> of the client.
1792
1792
1793
1793
Enables or disables reconnection mode of the client.
1794
1794
1795
- =head2 min_reconnect_interval ( [ $fractional_seconds ] )
1795
+ =head2 reconnect_interval ( [ $fractional_seconds ] )
1796
1796
1797
- Get or set C<min_reconnect_interval > of the client.
1797
+ Get or set C<reconnect_interval > of the client.
1798
1798
1799
1799
=head2 on_connect( [ $callback ] )
1800
1800
0 commit comments