Connection impossible to es

Aaaaah, i don't know that... But thank you, it works.

Thank you very much and thanks for the PERL module !

On Apr 17, 12:53 pm, Clinton Gormley cl...@traveljury.com wrote:

Hi Jerome

This isn't the right forum for this question, as your issue is purely
with Perl, nothing to do with Elasticsearch.

Also, much better to gist code (Discover gists · GitHub) rather
than pasting into an email.

sub lireFasta {
my @paramIndex = $_[0]; #contain index name and type name

The above line isn't doing what you think it is doing.

I bet you are calling this sub as: lireFasta(@index_and_type,$es)

but the contents of @index_and_type are flattened, so you end up with:

lireFasta('index','type',$es)

You need to pass the array as a reference instead:

lireFasta(\@index_and_type,$es)
sub lireFasta {
    my $paramIndex = $_[0];
    my $es = $_[1];

    ....
    $es->index(
        index => $paramIndex->[0],
        type  => $paramIndex->[1]

....

clint