aboutsummaryrefslogtreecommitdiffstats
path: root/metrics/metrics.go
diff options
context:
space:
mode:
authorPéter Szilágyi <peterke@gmail.com>2017-03-03 17:41:52 +0800
committerPéter Szilágyi <peterke@gmail.com>2017-03-03 17:41:52 +0800
commite7030c4bf59e8e148822c50ae1a5896c604c38c1 (patch)
tree4403290e84761608e8437d23ecef4d934406dd46 /metrics/metrics.go
parentfaf713632c307e3fd77a492481846b858ad991f9 (diff)
downloaddexon-e7030c4bf59e8e148822c50ae1a5896c604c38c1.tar
dexon-e7030c4bf59e8e148822c50ae1a5896c604c38c1.tar.gz
dexon-e7030c4bf59e8e148822c50ae1a5896c604c38c1.tar.bz2
dexon-e7030c4bf59e8e148822c50ae1a5896c604c38c1.tar.lz
dexon-e7030c4bf59e8e148822c50ae1a5896c604c38c1.tar.xz
dexon-e7030c4bf59e8e148822c50ae1a5896c604c38c1.tar.zst
dexon-e7030c4bf59e8e148822c50ae1a5896c604c38c1.zip
all: update light logs (and a few others) to the new model
Diffstat (limited to 'metrics/metrics.go')
-rw-r--r--metrics/metrics.go5
1 files changed, 2 insertions, 3 deletions
diff --git a/metrics/metrics.go b/metrics/metrics.go
index fe400b2b9..9906bb8ad 100644
--- a/metrics/metrics.go
+++ b/metrics/metrics.go
@@ -18,7 +18,6 @@
package metrics
import (
- "fmt"
"os"
"runtime"
"strings"
@@ -41,7 +40,7 @@ var Enabled = false
func init() {
for _, arg := range os.Args {
if strings.TrimLeft(arg, "-") == MetricsEnabledFlag {
- log.Info(fmt.Sprintf("Enabling metrics collection"))
+ log.Info("Enabling metrics collection")
Enabled = true
}
}
@@ -102,7 +101,7 @@ func CollectProcessMetrics(refresh time.Duration) {
diskWrites = metrics.GetOrRegisterMeter("system/disk/writecount", metrics.DefaultRegistry)
diskWriteBytes = metrics.GetOrRegisterMeter("system/disk/writedata", metrics.DefaultRegistry)
} else {
- log.Debug(fmt.Sprintf("failed to read disk metrics: %v", err))
+ log.Debug("Failed to read disk metrics", "err", err)
}
// Iterate loading the different stats and updating the meters
for i := 1; ; i++ {