|
@@ -39,7 +39,7 @@ type Metric struct {
|
|
|
type Prometheus struct {
|
|
|
MetricsList []*Metric
|
|
|
MetricsPath string
|
|
|
- CallCnt prometheus.CounterVec
|
|
|
+ CallCnt *prometheus.CounterVec
|
|
|
CallDur *prometheus.HistogramVec
|
|
|
}
|
|
|
|
|
@@ -149,7 +149,7 @@ func (p *Prometheus) registerMetrics(sub string) {
|
|
|
}
|
|
|
switch metricDef {
|
|
|
case rpcCallCnt:
|
|
|
- p.CallCnt = metric.(prometheus.CounterVec)
|
|
|
+ p.CallCnt = metric.(*prometheus.CounterVec)
|
|
|
case rpcCallDur:
|
|
|
p.CallDur = metric.(*prometheus.HistogramVec)
|
|
|
}
|