NAME
Search::Elasticsearch::Async::Simple - Unofficial asynchronous API for Elasticsearch using callbacks
SYNOPSIS
use AnyEvent ();
use Search::Elasticsearch::Async::Simple ();
my $es = Search::Elasticsearch::Async::Simple->new;
my $cv = AE::cv;
$es->search(
index => 'site',
type => 'post',
body => {
query => {
match => { title => 'elasticsearch' },
},
},
sub {
$cv->send(@_);
}
);
my ($res) = $cv->recv();
DESCRIPTION
Search::Elasticsearch::Async::Simple is the unofficial asynchronous Perl client for Elasticsearch. Unlike the official Search::Elasticsearch::Async module, it does not use any library to provide asynchronous interface, only callbacks.
Search::Elasticsearch::Async::Simple builds on Search::Elasticsearch, which you should see for the main documentation.
All request methods are the same as synchronous methods, but with one exception. They take one more argument in last position, which value must be the callback function. This function will be called after the response will be received.
SEE ALSO
SUPPORT
Repository
Bug tracker
http://github.com/dionys/search-elasticsearch-async-simple/issues
AUTHOR
Denis Ibaev dionys@cpan.org
.
LICENSE
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
See http://dev.perl.org/licenses/ for more information.