Skip to content

Commit 73aec06

Browse files
authored
Merge pull request prometheus#1705 from prometheus/bjk/update_mod
Update Go modules
2 parents 3cedd34 + b532c81 commit 73aec06

530 files changed

Lines changed: 113081 additions & 150411 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

collector/filesystem_freebsd.go

Lines changed: 3 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -16,9 +16,6 @@
1616
package collector
1717

1818
import (
19-
"bytes"
20-
"unsafe"
21-
2219
"github.com/go-kit/kit/log/level"
2320
"golang.org/x/sys/unix"
2421
)
@@ -30,15 +27,6 @@ const (
3027
noWait = 0x2 // MNT_NOWAIT
3128
)
3229

33-
func gostring(b []int8) string {
34-
bb := *(*[]byte)(unsafe.Pointer(&b))
35-
idx := bytes.IndexByte(bb, 0)
36-
if idx < 0 {
37-
return ""
38-
}
39-
return string(bb[:idx])
40-
}
41-
4230
// Expose filesystem fullness.
4331
func (c *filesystemCollector) GetStats() ([]filesystemStats, error) {
4432
n, err := unix.Getfsstat(nil, noWait)
@@ -52,14 +40,14 @@ func (c *filesystemCollector) GetStats() ([]filesystemStats, error) {
5240
}
5341
stats := []filesystemStats{}
5442
for _, fs := range buf {
55-
mountpoint := gostring(fs.Mntonname[:])
43+
mountpoint := string(fs.Mntonname[:])
5644
if c.ignoredMountPointsPattern.MatchString(mountpoint) {
5745
level.Debug(c.logger).Log("msg", "Ignoring mount point", "mountpoint", mountpoint)
5846
continue
5947
}
6048

61-
device := gostring(fs.Mntfromname[:])
62-
fstype := gostring(fs.Fstypename[:])
49+
device := string(fs.Mntfromname[:])
50+
fstype := string(fs.Fstypename[:])
6351
if c.ignoredFSTypesPattern.MatchString(fstype) {
6452
level.Debug(c.logger).Log("msg", "Ignoring fs type", "type", fstype)
6553
continue

go.mod

Lines changed: 17 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -2,33 +2,37 @@ module github.com/prometheus/node_exporter
22

33
require (
44
github.com/alecthomas/units v0.0.0-20190924025748-f65c72e2690d // indirect
5-
github.com/beevik/ntp v0.2.0
5+
github.com/beevik/ntp v0.3.0
66
github.com/coreos/go-systemd v0.0.0-20191104093116-d3cd4ed1dbcf
77
github.com/ema/qdisc v0.0.0-20190904071900-b82c76788043
88
github.com/go-kit/kit v0.10.0
99
github.com/godbus/dbus v0.0.0-20190402143921-271e53dc4968
10-
github.com/golang/protobuf v1.3.3 // indirect
10+
github.com/golang/protobuf v1.4.1 // indirect
1111
github.com/hodgesds/perf-utils v0.0.8
12+
github.com/jpillora/backoff v1.0.0 // indirect
1213
github.com/lufia/iostat v1.1.0
1314
github.com/mattn/go-xmlrpc v0.0.3
1415
github.com/mdlayher/genetlink v1.0.0 // indirect
1516
github.com/mdlayher/netlink v1.1.0 // indirect
1617
github.com/mdlayher/wifi v0.0.0-20190303161829-b1436901ddee
18+
github.com/mwitkow/go-conntrack v0.0.0-20190716064945-2f068394615f // indirect
1719
github.com/pkg/errors v0.9.1
18-
github.com/prometheus/client_golang v1.4.1
20+
github.com/prometheus/client_golang v1.6.0
1921
github.com/prometheus/client_model v0.2.0
20-
github.com/prometheus/common v0.9.1
22+
github.com/prometheus/common v0.10.0
2123
github.com/prometheus/procfs v0.0.11
22-
github.com/siebenmann/go-kstat v0.0.0-20160321171754-d34789b79745
24+
github.com/siebenmann/go-kstat v0.0.0-20200303194639-4e8294f9e9d5
2325
github.com/soundcloud/go-runit v0.0.0-20150630195641-06ad41a06c4a
24-
go.uber.org/atomic v1.5.1 // indirect
25-
go.uber.org/multierr v1.4.0 // indirect
26-
golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550
27-
golang.org/x/lint v0.0.0-20200130185559-910be7a94367 // indirect
28-
golang.org/x/sys v0.0.0-20200217220822-9197077df867
29-
golang.org/x/tools v0.0.0-20200216192241-b320d3a0f5a2 // indirect
26+
go.uber.org/multierr v1.5.0 // indirect
27+
golang.org/x/crypto v0.0.0-20200510223506-06a226fb4e37
28+
golang.org/x/lint v0.0.0-20200302205851-738671d3881b // indirect
29+
golang.org/x/net v0.0.0-20200513185701-a91f0712d120 // indirect
30+
golang.org/x/sync v0.0.0-20200317015054-43a5402ce75a // indirect
31+
golang.org/x/sys v0.0.0-20200513112337-417ce2331b5c
32+
golang.org/x/tools v0.0.0-20200513201620-d5fe73897c97 // indirect
3033
gopkg.in/alecthomas/kingpin.v2 v2.2.6
31-
gopkg.in/yaml.v2 v2.2.8
34+
gopkg.in/yaml.v2 v2.3.0
35+
honnef.co/go/tools v0.0.1-2020.1.3 // indirect
3236
)
3337

34-
go 1.13
38+
go 1.14

go.sum

Lines changed: 55 additions & 21 deletions
Large diffs are not rendered by default.

vendor/github.com/BurntSushi/toml/.gitignore

Lines changed: 0 additions & 5 deletions
This file was deleted.

vendor/github.com/BurntSushi/toml/.travis.yml

Lines changed: 0 additions & 15 deletions
This file was deleted.

vendor/github.com/BurntSushi/toml/COMPATIBLE

Lines changed: 0 additions & 3 deletions
This file was deleted.

vendor/github.com/BurntSushi/toml/Makefile

Lines changed: 0 additions & 19 deletions
This file was deleted.

vendor/github.com/BurntSushi/toml/README.md

Lines changed: 0 additions & 218 deletions
This file was deleted.

0 commit comments

Comments
 (0)