You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
use strict;
use warnings;
use Redis::Fast;
my $redis = Redis::Fast->new(
server => 'localhost:6379',
reconnect=>10,
every => 100_000,
cnx_timeout => 10,
read_timeout => 3,
write_timeout => 3,
#on_connect => sub { while ($_[0]->info("persistence")->{loading}) {sleep 1 } }
);
for (1..100_000) { # adjust me
$redis->set("test_$_", "x" x 10_000);
}
print STDERR "Please restart redis\n";
while () {
$redis->get("test_1");
sleep 1;
}
crashes with
[get] LOADING Redis is loading the dataset in memory, at /usr/local/lib/perl/5.14.2/Redis/Fast.pm line 179.
Redis::Fast::__ANON__(Redis::Fast=SCALAR(0x13a65f8), "test_1") called at ZF.pl line 21
which makes reconnect feature useless. if I uncomment on_connect callback, everything works.
Note that Redis.pm in that case does not work at all.
The text was updated successfully, but these errors were encountered:
crashes with
which makes reconnect feature useless. if I uncomment on_connect callback, everything works.
Note that Redis.pm in that case does not work at all.
The text was updated successfully, but these errors were encountered: