fix golint issues in core/metric (#499)

This commit is contained in:
Kevin Wan
2021-02-21 21:18:07 +08:00
committed by GitHub
parent 8872d7cbd3
commit e7c9ef16fe
4 changed files with 18 additions and 3 deletions

View File

@@ -6,6 +6,7 @@ import (
)
type (
// A HistogramVecOpts is a histogram vector options.
HistogramVecOpts struct {
Namespace string
Subsystem string
@@ -15,7 +16,9 @@ type (
Buckets []float64
}
// A HistogramVec interface represents a histogram vector.
HistogramVec interface {
// Observe adds observation v to labels.
Observe(v int64, lables ...string)
close() bool
}
@@ -25,6 +28,7 @@ type (
}
)
// NewHistogramVec returns a HistogramVec.
func NewHistogramVec(cfg *HistogramVecOpts) HistogramVec {
if cfg == nil {
return nil