Versions in this module Expand all Collapse all v1 v1.0.0 May 24, 2019 Changes in this version + func GetPushBackend() map[string]PushBackend + func GetSnakeName(name string) string + func Publish(name string, v expvar.Var) + func PublishJSONFunc(name string, f func() string) + func Register(nvh NewVarHook) + func RegisterPushBackend(name string, backend PushBackend, emitPeriod time.Duration) + type CountTracker interface + Counts func() map[string]int64 + func CounterForDimension(mt MultiTracker, dimension string) CountTracker + type Counter struct + func NewCounter(name string, help string) *Counter + func (v *Counter) Add(delta int64) + func (v *Counter) Get() int64 + func (v *Counter) Help() string + func (v *Counter) Reset() + func (v *Counter) String() string + type CounterDuration struct + func NewCounterDuration(name, help string) *CounterDuration + func (cd *CounterDuration) Add(delta time.Duration) + func (cd *CounterDuration) Get() time.Duration + func (cd CounterDuration) Help() string + func (cd CounterDuration) String() string + type CounterDurationFunc struct + F func() time.Duration + func NewCounterDurationFunc(name string, help string, f func() time.Duration) *CounterDurationFunc + func (cf CounterDurationFunc) Help() string + func (cf CounterDurationFunc) String() string + type CounterFunc struct + F func() int64 + func NewCounterFunc(name string, help string, f func() int64) *CounterFunc + func (cf CounterFunc) Help() string + func (cf CounterFunc) String() string + type CountersFuncWithMultiLabels struct + func NewCountersFuncWithMultiLabels(name, help string, labels []string, f func() map[string]int64) *CountersFuncWithMultiLabels + func (c CountersFuncWithMultiLabels) Counts() map[string]int64 + func (c CountersFuncWithMultiLabels) Help() string + func (c CountersFuncWithMultiLabels) Labels() []string + func (c CountersFuncWithMultiLabels) String() string + type CountersWithMultiLabels struct + func NewCountersWithMultiLabels(name, help string, labels []string) *CountersWithMultiLabels + func (c *CountersWithMultiLabels) Help() string + func (c *CountersWithMultiLabels) ResetAll() + func (c *CountersWithMultiLabels) String() string + func (c *CountersWithMultiLabels) ZeroAll() + func (mc *CountersWithMultiLabels) Add(names []string, value int64) + func (mc *CountersWithMultiLabels) Counts() map[string]int64 + func (mc *CountersWithMultiLabels) Labels() []string + func (mc *CountersWithMultiLabels) Reset(names []string) + type CountersWithSingleLabel struct + func NewCountersWithSingleLabel(name, help, label string, tags ...string) *CountersWithSingleLabel + func (c *CountersWithSingleLabel) Add(name string, value int64) + func (c *CountersWithSingleLabel) Counts() map[string]int64 + func (c *CountersWithSingleLabel) Help() string + func (c *CountersWithSingleLabel) Label() string + func (c *CountersWithSingleLabel) Reset(name string) + func (c *CountersWithSingleLabel) ResetAll() + func (c *CountersWithSingleLabel) String() string + func (c *CountersWithSingleLabel) ZeroAll() + type Float struct + func NewFloat(name string) *Float + func (v *Float) Add(delta float64) + func (v *Float) Get() float64 + func (v *Float) Set(value float64) + func (v *Float) String() string + type FloatFunc func() float64 + func (f FloatFunc) String() string + type Gauge struct + func NewGauge(name string, help string) *Gauge + func (v *Gauge) Add(delta int64) + func (v *Gauge) Set(value int64) + type GaugeDuration struct + func NewGaugeDuration(name, help string) *GaugeDuration + func (gd *GaugeDuration) Set(value time.Duration) + type GaugeDurationFunc struct + func NewGaugeDurationFunc(name string, help string, f func() time.Duration) *GaugeDurationFunc + type GaugeFunc struct + func NewGaugeFunc(name string, help string, f func() int64) *GaugeFunc + type GaugesFuncWithMultiLabels struct + func NewGaugesFuncWithMultiLabels(name, help string, labels []string, f func() map[string]int64) *GaugesFuncWithMultiLabels + type GaugesWithMultiLabels struct + func NewGaugesWithMultiLabels(name, help string, labels []string) *GaugesWithMultiLabels + func (c *GaugesWithMultiLabels) Help() string + func (c *GaugesWithMultiLabels) ResetAll() + func (c *GaugesWithMultiLabels) String() string + func (c *GaugesWithMultiLabels) ZeroAll() + func (mg *GaugesWithMultiLabels) Add(names []string, value int64) + func (mg *GaugesWithMultiLabels) Set(names []string, value int64) + type GaugesWithSingleLabel struct + func NewGaugesWithSingleLabel(name, help, label string, tags ...string) *GaugesWithSingleLabel + func (c *GaugesWithSingleLabel) Counts() map[string]int64 + func (c *GaugesWithSingleLabel) Help() string + func (c *GaugesWithSingleLabel) Reset(name string) + func (c *GaugesWithSingleLabel) ResetAll() + func (c *GaugesWithSingleLabel) String() string + func (c *GaugesWithSingleLabel) ZeroAll() + func (g *GaugesWithSingleLabel) Add(name string, value int64) + func (g *GaugesWithSingleLabel) Set(name string, value int64) + type Histogram struct + func NewGenericHistogram(name, help string, cutoffs []int64, labels []string, ...) *Histogram + func NewHistogram(name, help string, cutoffs []int64) *Histogram + func (h *Histogram) Add(value int64) + func (h *Histogram) Buckets() []int64 + func (h *Histogram) Count() (count int64) + func (h *Histogram) CountLabel() string + func (h *Histogram) Counts() map[string]int64 + func (h *Histogram) Cutoffs() []int64 + func (h *Histogram) Help() string + func (h *Histogram) Labels() []string + func (h *Histogram) MarshalJSON() ([]byte, error) + func (h *Histogram) String() string + func (h *Histogram) Total() (total int64) + func (h *Histogram) TotalLabel() string + type JSONFunc func() string + func (f JSONFunc) String() string + type MultiTimings struct + func NewMultiTimings(name string, help string, labels []string) *MultiTimings + func (mt *MultiTimings) Add(names []string, elapsed time.Duration) + func (mt *MultiTimings) Cutoffs() []int64 + func (mt *MultiTimings) Labels() []string + func (mt *MultiTimings) Record(names []string, startTime time.Time) + type MultiTracker interface + Labels func() []string + type NewVarHook func(name string, v expvar.Var) + type PushBackend interface + PushAll func() error + type Rates struct + func NewRates(name string, countTracker CountTracker, samples int, interval time.Duration) *Rates + func (rt *Rates) Get() (rateMap map[string][]float64) + func (rt *Rates) GetCount() (rateMap map[string][]int64) + func (rt *Rates) String() string + func (rt *Rates) TotalRate() float64 + type RingInt64 struct + func NewRingInt64(capacity int) *RingInt64 + func (ri *RingInt64) Add(val int64) + func (ri *RingInt64) Values() (values []int64) + type String struct + func NewString(name string) *String + func (v *String) Get() string + func (v *String) Set(value string) + func (v *String) String() string + type StringFunc func() string + func (f StringFunc) String() string + type StringMap struct + func NewStringMap(name string) *StringMap + func (v *StringMap) Get(name string) string + func (v *StringMap) Set(name, value string) + func (v *StringMap) String() string + type StringMapFunc func() map[string]string + func (f StringMapFunc) String() string + type Timings struct + func NewTimings(name, help, label string, categories ...string) *Timings + func (t *Timings) Add(name string, elapsed time.Duration) + func (t *Timings) Count() int64 + func (t *Timings) Counts() map[string]int64 + func (t *Timings) Cutoffs() []int64 + func (t *Timings) Help() string + func (t *Timings) Histograms() (h map[string]*Histogram) + func (t *Timings) Label() string + func (t *Timings) Record(name string, startTime time.Time) + func (t *Timings) String() string + func (t *Timings) Time() int64 + type Variable interface + Help func() string + String func() string