The London Perl and Raku Workshop takes place on 26th Oct 2024. If your company depends on Perl, please consider sponsoring and/or attending.

NAME

Net::Async::Graphite::Draw - Interpret data obtained from graphite.

SYNOPSIS

    with 'Net::Async::Graphite::Draw';

DESCRIPTION

Don't use this module directly, use Net::Async::Graphite and create objects using its new method in the normal way. Those objects will include the functionality documented here.

This role brings the capacity to interpret and encode the data obtained from graphite in various ways. Currently those various ways are gnuplot, and probably using a blocking module at that (although it's pretty fast).

BUGS

Gnuplut may be called synchronously.

plot() is ridiculously naïve. Format and scale in particular need to be dealt with, and the timestamps and step returned by graphite.

ROLE

METHODS

last_value ($target, [%extra])

Calls render() with the same arguments but prepended by the format raw, and returns (a Future which completes to) a list of the final datum on each line in the response.

plot ($target, [%extra])

Return a (Future which completes to) a scalar containing the result of running a plot inside a child gnuplot process.

Mostly this exists for fun so that I can get data displayed on the terminal.

_plot_gather_datasets

I can't remember.

_default_plot_size

I can't remember.

SEE ALSO

Gnuplot http://gnuplot.info/

Net::Async::Graphite

Gnuplot::Builder

Future

Moo

AUTHOR

Matthew King <matthew.king@cloudbeds.com>