Hello,

I have been playing with Memcached between two servers using Perl and 
Memcached::Client which is working great. I would like to take it one step 
further and use AnyEvent to trigger when a new key and value has been written 
to Memcached. I am struggling to understand how to do it though as the code I 
have so far is:

use AnyEvent;
my $cv = AnyEvent->condvar;
$client->get('iplist', $cv);
my $iplist = $cv->recv;

while (($ip,$count) = each(%$iplist)) {
                print $ip . "\n";
}

my $loop = AnyEvent->condvar;
$loop->recv;

If somebody has this working would be very grateful for an example please.
-- 
Thanks, Organic Spider | Weaving Open Source Technology

Reply via email to