arch instance
use Mojo::Base 'Mojolicious::Plugin';
use Time::HiRes qw/time/;
use Mojo::JSON qw/encode_json/;
sub register {
my ($self, $app, $conf) = @_;
my $index = $conf->{index} || die "n
}
}
};
my $url = "${es_url}/${index}/${type}/_mapping";
my $tx = $app->ua->post($url, json => $index_meta);
$app->hook(before_dispatch => sub {
my $c = shift;
$c->stash->{'mojol
};
}
my $url = "${es_url}/${index}/${type}/?timestamp=${t}";
$c->app->ua->post($url, json => $data, sub {
my ($ua, $tx) = @_;
if (! $tx) {
$c->app->log->warn("could no