switch to go-kit/log (#1575)

Signed-off-by: yeya24 <yb532204897@gmail.com>
This commit is contained in:
Ben Ye 2019-12-31 11:19:37 -05:00 committed by Ben Kochie
commit 2477c5c67d
158 changed files with 3434 additions and 4636 deletions

View file

@ -19,7 +19,7 @@ import (
"bytes"
"unsafe"
"github.com/prometheus/common/log"
"github.com/go-kit/kit/log/level"
"golang.org/x/sys/unix"
)
@ -54,14 +54,14 @@ func (c *filesystemCollector) GetStats() ([]filesystemStats, error) {
for _, fs := range buf {
mountpoint := gostring(fs.Mntonname[:])
if c.ignoredMountPointsPattern.MatchString(mountpoint) {
log.Debugf("Ignoring mount point: %s", mountpoint)
level.Debug(c.logger).Log("msg", "Ignoring mount point", "mountpoint", mountpoint)
continue
}
device := gostring(fs.Mntfromname[:])
fstype := gostring(fs.Fstypename[:])
if c.ignoredFSTypesPattern.MatchString(fstype) {
log.Debugf("Ignoring fs type: %s", fstype)
level.Debug(c.logger).Log("msg", "Ignoring fs type", "type", fstype)
continue
}