package
0.2.0
Repository: https://github.com/unit-io/unitdb.git
Documentation: pkg.go.dev

# Functions

GetOrRegisterCounter returns an existing Counter or constructs and registers a new StandardCounter.
GetOrRegisterGauge returns an existing Gauge or constructs and registers a new StandardGauge.
GetOrRegisterHistogram returns an existing Histogram or constructs and registers a new StandardHistogram.
GetOrRegisterTimer returns an existing Timer or constructs and registers a new StandardTimer.
NewCounter constructs a new StandardCounter.
NewGauge constructs a new StandardGauge.
NewHistogram constructs a new StandardHistogram from a Sample.
Create a new registry.
New initializes a new metric sample.
No description provided by the author
NewTimer constructs a new StandardTimer using an exponentially-decaying sample with the same reservoir size and alpha as UNIX load averages.

# Structs

No description provided by the author
HistogramSnapshot is a read-only copy of another Histogram.
SampleSnapshot is a read-only copy of another Sample.
The standard implementation of a Registry is a mutex-protected map of names to metrics.
TimeSeriesSnapshot is a read-only copy of another Timer.

# Interfaces

Counters hold an int64 value that can be incremented and decremented.
Gauges hold an int64 value that can be set arbitrarily.
Histograms calculate distribution statistics from a series of int64 values.
A Metrics holds registry references to a set of metrics by name and can iterate over them, calling callback functions provided by the user.
a stream.
Stoppable defines the metrics which has to be stopped.
Timers capture the duration and rate of events.

# Type aliases

CounterSnapshot is a read-only copy of another Counter.
DuplicateMetric is the error returned by Registry.Register when a metric already exists.
GaugeSnapshot is a read-only copy of another Gauge.