Skip to content
forked from remeh/go-rrd

A golang client for talking to rrdcached

License

Notifications You must be signed in to change notification settings

PengWuLin/go-rrd

 
 

Repository files navigation

go-rrd Go Report Card License GoDoc Build Status

go-rrd is a Go client for talking to rrdtool's rrdcached.

Features

Installation

go get -u github.com/multiplay/go-rrd

Examples

Using go-rrd is simple just create a client and then send commands e.g.

package main

import (
	"log"
	"time"

	"github.com/multiplay/go-rrd"
)

func main() {
	c, err := rrd.NewClient("192.168.1.102:10011")
	if err != nil {
		log.Fatal(err)
	}
	defer c.Close()

	if err := c.Create(
		"test.rrd",
		[]DS{NewGauge("watts", time.Minute*5, 0, 24000)},
		[]RRA{NewAverage(0.5, 1, 864000)},
	); err != nil {
		log.Fatal(err)
	}
}

Documentation

License

go-rrd is available under the BSD 2-Clause License.

About

A golang client for talking to rrdcached

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Go 100.0%