rpc: swap out timer metrics to histograms

This commit is contained in:
Péter Szilágyi
2022-06-08 16:24:33 +03:00
parent 138f0d7494
commit 106a162b7c
2 changed files with 19 additions and 8 deletions
+1 -1
View File
@@ -346,7 +346,7 @@ func (h *handler) handleCall(cp *callProc, msg *jsonrpcMessage) *jsonrpcMessage
successfulRequestGauge.Inc(1)
}
rpcServingTimer.UpdateSince(start)
newRPCServingTimer(msg.Method, answer.Error == nil).UpdateSince(start)
updateServeTimeHistogram(msg.Method, answer.Error == nil, time.Since(start))
}
return answer
}