Documentation
¶
Overview ¶
Package metrics provides in-memory metrics collection for cloudemu services.
Index ¶
- type Collector
- func (c *Collector) All() []Metric
- func (c *Collector) Counter(name string, value float64, labels map[string]string)
- func (c *Collector) Gauge(name string, value float64, labels map[string]string)
- func (c *Collector) Histogram(name string, duration time.Duration, labels map[string]string)
- func (c *Collector) Reset()
- type Metric
- type MetricType
- type Query
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Collector ¶
type Collector struct {
// contains filtered or unexported fields
}
Collector collects in-memory metrics.
type Metric ¶
type Metric struct {
Name string
Type MetricType
Value float64
Labels map[string]string
Timestamp time.Time
}
Metric is a recorded metric data point.
type MetricType ¶
type MetricType int
MetricType identifies the type of metric.
const ( CounterType MetricType = iota GaugeType HistogramType )
Click to show internal directories.
Click to hide internal directories.