influxdb

package
v0.2.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 27, 2016 License: MIT Imports: 7 Imported by: 0

Documentation

Overview

Package influxdb implements a InfluxDB backend for package metrics.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewCounter

func NewCounter(client stdinflux.Client, bp stdinflux.BatchPoints, key string, tags []metrics.Field, reportInterval time.Duration) metrics.Counter

NewCounter returns a Counter that writes values in the reportInterval to the given InfluxDB client, utilizing batching.

func NewCounterTick

func NewCounterTick(client stdinflux.Client, bp stdinflux.BatchPoints, key string, tags []metrics.Field, reportTicker <-chan time.Time) metrics.Counter

NewCounterTick is the same as NewCounter, but allows the user to pass a own channel to trigger the write process to the client.

func NewGauge

func NewGauge(client stdinflux.Client, bp stdinflux.BatchPoints, key string, tags []metrics.Field, reportInterval time.Duration) metrics.Gauge

NewGauge creates a new gauge instance, reporting points in the defined reportInterval.

func NewGaugeTick

func NewGaugeTick(client stdinflux.Client, bp stdinflux.BatchPoints, key string, tags []metrics.Field, reportTicker <-chan time.Time) metrics.Gauge

NewGaugeTick is the same as NewGauge with a ticker channel instead of a interval.

func NewHistogram

func NewHistogram(client stdinflux.Client, bp stdinflux.BatchPoints, key string, tags []metrics.Field,
	reportInterval time.Duration, minValue, maxValue int64, sigfigs int, quantiles ...int) metrics.Histogram

NewHistogram is taken from http://github.com/codahale/metrics. It returns a windowed HDR histogram which drops data older than five minutes.

The histogram exposes metrics for each passed quantile as gauges. Quantiles should be integers in the range 1..99. The gauge names are assigned by using the passed name as a prefix and appending "_pNN" e.g. "_p50".

func NewHistogramTick

func NewHistogramTick(client stdinflux.Client, bp stdinflux.BatchPoints, key string, tags []metrics.Field,
	reportTicker <-chan time.Time, minValue, maxValue int64, sigfigs int, quantiles ...int) metrics.Histogram

NewHistogramTick is the same as NewHistoGram, but allows to pass a custom reportTicker.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL