hwt/metrics/metrics.go
2018-01-24 21:25:15 -08:00

10 lines
174 B
Go

package metrics
import (
"time"
)
func HTTPLatency(path string, dur time.Duration) {
httpReqLat.WithLabelValues(path).Observe(float64(dur) / float64(time.Millisecond))
}