Merge pull request #72334 from danielqsj/kp

Change proxy metrics to conform metrics guidelines
This commit is contained in:
Kubernetes Prow Robot
2019-01-25 18:32:12 -08:00
committed by GitHub
5 changed files with 39 additions and 5 deletions

View File

@@ -639,7 +639,8 @@ func (proxier *Proxier) syncProxyRules() {
start := time.Now()
defer func() {
metrics.SyncProxyRulesLatency.Observe(metrics.SinceInMicroseconds(start))
metrics.SyncProxyRulesLatency.Observe(metrics.SinceInSeconds(start))
metrics.DeprecatedSyncProxyRulesLatency.Observe(metrics.SinceInMicroseconds(start))
klog.V(4).Infof("syncProxyRules took %v", time.Since(start))
}()
// don't sync rules till we've received services and endpoints