Measure::Everything::Adapter::InfluxDB::TCP - Send stats to Influx via TCP using Telegraf
version 1.001
Measure::Everything::Adapter->set( 'InfluxDB::TCP', host => 'localhost', # default port => 8094, # default ); use Measure::Everything qw($stats); $stats->write('metric', 1);
Send stats via TCP to a Telegraf service, which will forward them to InfluxDB. No buffering whatsoever, so there is one TCP request per call to $stats->write. This might be a bad idea.
$stats->write
If TCP listener is not available when set is called, an error will be written via Log::Any. write will silently discard all metrics, no data will be sent to Telegraf / InfluxDB.
set
Log::Any
write
If a request fails no further error handling is done. The metric will be lost.
Set these options when setting your adapter via Measure::Everything::Adapter->set
Measure::Everything::Adapter->set
host
Name of the host where your Telegraf is running. Default to localhost.
localhost
port
Port your Telegraf is listening. Defaults to 8094.
8094
Thomas Klausner <domm@cpan.org>
This software is copyright (c) 2016 by Thomas Klausner.
This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.
To install Measure::Everything::Adapter::InfluxDB::TCP, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Measure::Everything::Adapter::InfluxDB::TCP
CPAN shell
perl -MCPAN -e shell install Measure::Everything::Adapter::InfluxDB::TCP
For more information on module installation, please visit the detailed CPAN module installation guide.