$cv->begin; $worker3->do( "P:Data" , sub { guard { $cv->end; }; return warn "Request died: $@\n" if $@; warn "Received response: @_\n"; });
$cv->begin; $SIG{INT} = sub { $cv->end };
To install AnyEvent::Worker, copy and paste the appropriate command in to your terminal.
cpanm
cpanm AnyEvent::Worker
CPAN shell
perl -MCPAN -e shell install AnyEvent::Worker
For more information on module installation, please visit the detailed CPAN module installation guide.