Git Product home page Git Product logo

metronome's Introduction

metronome

Mini-graphite that uses client-side java script to render graphs w/o depending on graphite.

'metronome' implements the carbon protocol, so anything that can feed Graphite can feed metronome. We also accept submissions via POST:

For example, to submit RX bytes for eth0:

while true;
do
    VAL=$(ip -s link ls eth0 | grep RX -A 1 | tail -1 | awk '{print $1}')
    wget -q --post-data="" "http://127.0.0.1:8000/?do=store&name=rxbytes&timestamp=$(date +%s)&value=$VAL" -O /dev/null
    sleep 1
done

To retrieve data:

$ wget http://127.0.0.1:8000/?do=retrieve&name=rxbytes&begin=0&end=$(date +%s)&callback=jsonp

This delivers a JSONP callback with your values in there.

To view, try html/index.html

Installing

Dependencies include a recent g++ (4.7+), Boost and libeigen.

Installing Eigen

Either install libeigen3-dev (Debian, Ubuntu), eigen3-devel (Fedora, EPEL).

To install it manually:

$ wget http://bitbucket.org/eigen/eigen/get/3.2.1.tar.bz2
$ tar xf 3.2.1.tar.bz2

Compiling

$ ./bootstrap
$ ./configure
$ make

If you installed libeigen manually, use ./configure --with-eigen=/path/to/eigen

Running

$ mkdir stats
$ ./metronome --stats-directory=./stats

Next, host the 'html/' directory somewhere on a webserver, and edit 'html/local.js' so it knows the Webserver IP address of metronome (port 8000 on :: by default).

Thanks to

Aki Tuomi for the excellent yahttp, Rickshaw for the graphs. Eigen for the math. And a cast of thousands for C++2011.

status

"Toy" for now - stores all data in flat files, which we read in their entirety to replay data.

But, starting to look nice.

metronome's People

Contributors

ahupowerdns avatar cmouse avatar crami avatar ekohl avatar gintsgints avatar habbie avatar mind04 avatar nlmark avatar paddg avatar pieterlexis avatar rgacogne avatar wojas avatar zeha avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.