mirror of
https://github.com/prometheus/node_exporter.git
synced 2024-11-09 23:24:09 -08:00
Update go to 1.17 (#2159)
Signed-off-by: Julien Pivotto <roidelapluie@inuits.eu>
This commit is contained in:
parent
68f1e952c8
commit
68a6c78c0d
|
@ -9,7 +9,7 @@ executors:
|
|||
# should also be updated.
|
||||
golang:
|
||||
docker:
|
||||
- image: circleci/golang:1.16
|
||||
- image: circleci/golang:1.17
|
||||
|
||||
jobs:
|
||||
test:
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
go:
|
||||
# Whenever the Go version is updated here, .circle/config.yml and
|
||||
# .promu.yml should also be updated.
|
||||
version: 1.16
|
||||
version: 1.17
|
||||
cgo: true
|
||||
repository:
|
||||
path: github.com/prometheus/node_exporter
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
go:
|
||||
# Whenever the Go version is updated here, .circle/config.yml and
|
||||
# .promu-cgo.yml should also be updated.
|
||||
version: 1.16
|
||||
version: 1.17
|
||||
repository:
|
||||
path: github.com/prometheus/node_exporter
|
||||
build:
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !noarp
|
||||
// +build !noarp
|
||||
|
||||
package collector
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !nobcache
|
||||
// +build !nobcache
|
||||
|
||||
package collector
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !nobonding
|
||||
// +build !nobonding
|
||||
|
||||
package collector
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build (freebsd || dragonfly || (openbsd && !amd64) || netbsd || darwin) && !noboottime
|
||||
// +build freebsd dragonfly openbsd,!amd64 netbsd darwin
|
||||
// +build !noboottime
|
||||
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !noboottime
|
||||
// +build !noboottime
|
||||
|
||||
package collector
|
||||
|
|
|
@ -11,8 +11,8 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
// +build solaris
|
||||
// +build !noboottime
|
||||
//go:build solaris && !noboottime
|
||||
// +build solaris,!noboottime
|
||||
|
||||
package collector
|
||||
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !nobtrfs
|
||||
// +build !nobtrfs
|
||||
|
||||
package collector
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !nobtrfs
|
||||
// +build !nobtrfs
|
||||
|
||||
package collector
|
||||
|
|
|
@ -11,8 +11,8 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
// +build !nobuddyinfo
|
||||
// +build !netbsd
|
||||
//go:build !nobuddyinfo && !netbsd
|
||||
// +build !nobuddyinfo,!netbsd
|
||||
|
||||
package collector
|
||||
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !noconntrack
|
||||
// +build !noconntrack
|
||||
|
||||
package collector
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !nocpu
|
||||
// +build !nocpu
|
||||
|
||||
package collector
|
||||
|
|
|
@ -14,6 +14,7 @@
|
|||
// Based on gopsutil/cpu/cpu_darwin_cgo.go @ ae251eb which is licensed under
|
||||
// BSD. See https://github.com/shirou/gopsutil/blob/master/LICENSE for details.
|
||||
|
||||
//go:build !nocpu
|
||||
// +build !nocpu
|
||||
|
||||
package collector
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !nocpu
|
||||
// +build !nocpu
|
||||
|
||||
package collector
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !nocpu
|
||||
// +build !nocpu
|
||||
|
||||
package collector
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !nocpu
|
||||
// +build !nocpu
|
||||
|
||||
package collector
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !nocpu
|
||||
// +build !nocpu
|
||||
|
||||
package collector
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !nocpu
|
||||
// +build !nocpu
|
||||
|
||||
package collector
|
||||
|
|
|
@ -11,8 +11,8 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
// +build openbsd,!amd64
|
||||
// +build !nocpu
|
||||
//go:build openbsd && !amd64 && !nocpu
|
||||
// +build openbsd,!amd64,!nocpu
|
||||
|
||||
package collector
|
||||
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !nocpu
|
||||
// +build !nocpu
|
||||
|
||||
package collector
|
||||
|
|
|
@ -11,8 +11,8 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
// +build solaris
|
||||
// +build !nocpu
|
||||
//go:build solaris && !nocpu
|
||||
// +build solaris,!nocpu
|
||||
|
||||
package collector
|
||||
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !nocpu
|
||||
// +build !nocpu
|
||||
|
||||
package collector
|
||||
|
|
|
@ -11,8 +11,8 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
// +build solaris
|
||||
// +build !nocpu
|
||||
//go:build solaris && !nocpu
|
||||
// +build solaris,!nocpu
|
||||
|
||||
package collector
|
||||
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !nodevstat
|
||||
// +build !nodevstat
|
||||
|
||||
package collector
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !nodevstat
|
||||
// +build !nodevstat
|
||||
|
||||
package collector
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !nodiskstats && (openbsd || linux || darwin)
|
||||
// +build !nodiskstats
|
||||
// +build openbsd linux darwin
|
||||
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !nodiskstats
|
||||
// +build !nodiskstats
|
||||
|
||||
package collector
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !nodiskstats
|
||||
// +build !nodiskstats
|
||||
|
||||
package collector
|
||||
|
|
|
@ -11,8 +11,8 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
// +build openbsd,!amd64
|
||||
// +build !nodiskstats
|
||||
//go:build openbsd && !amd64 && !nodiskstats
|
||||
// +build openbsd,!amd64,!nodiskstats
|
||||
|
||||
package collector
|
||||
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !nodiskstats
|
||||
// +build !nodiskstats
|
||||
|
||||
package collector
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !nodrbd
|
||||
// +build !nodrbd
|
||||
|
||||
package collector
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !noedac
|
||||
// +build !noedac
|
||||
|
||||
package collector
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !noentropy
|
||||
// +build !noentropy
|
||||
|
||||
package collector
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !noethtool
|
||||
// +build !noethtool
|
||||
|
||||
// The hard work of collecting data from the kernel via the ethtool interfaces is done by
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build (freebsd || dragonfly) && !noexec
|
||||
// +build freebsd dragonfly
|
||||
// +build !noexec
|
||||
|
||||
|
|
|
@ -11,8 +11,8 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
// +build linux
|
||||
// +build !nofibrechannel
|
||||
//go:build linux && !nofibrechannel
|
||||
// +build linux,!nofibrechannel
|
||||
|
||||
package collector
|
||||
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !nofilefd
|
||||
// +build !nofilefd
|
||||
|
||||
package collector
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build ((openbsd && !amd64) || darwin || dragonfly) && !nofilesystem
|
||||
// +build openbsd,!amd64 darwin dragonfly
|
||||
// +build !nofilesystem
|
||||
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !nofilesystem && (linux || freebsd || openbsd || darwin || dragonfly)
|
||||
// +build !nofilesystem
|
||||
// +build linux freebsd openbsd darwin dragonfly
|
||||
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !nofilesystem
|
||||
// +build !nofilesystem
|
||||
|
||||
package collector
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !nofilesystem
|
||||
// +build !nofilesystem
|
||||
|
||||
package collector
|
||||
|
|
|
@ -11,8 +11,8 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
// +build openbsd
|
||||
// +build !nofilesystem
|
||||
//go:build openbsd && !nofilesystem
|
||||
// +build openbsd,!nofilesystem
|
||||
|
||||
package collector
|
||||
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !nohwmon
|
||||
// +build !nohwmon
|
||||
|
||||
package collector
|
||||
|
|
|
@ -11,8 +11,8 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
// +build linux
|
||||
// +build !noinfiniband
|
||||
//go:build linux && !noinfiniband
|
||||
// +build linux,!noinfiniband
|
||||
|
||||
package collector
|
||||
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build (linux || openbsd) && !nointerrupts
|
||||
// +build linux openbsd
|
||||
// +build !nointerrupts
|
||||
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !nointerrupts
|
||||
// +build !nointerrupts
|
||||
|
||||
package collector
|
||||
|
|
|
@ -11,8 +11,8 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
// +build openbsd,!amd64
|
||||
// +build !nointerrupts
|
||||
//go:build openbsd && !amd64 && !nointerrupts
|
||||
// +build openbsd,!amd64,!nointerrupts
|
||||
|
||||
package collector
|
||||
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !nointerrupts
|
||||
// +build !nointerrupts
|
||||
|
||||
package collector
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !noipvs
|
||||
// +build !noipvs
|
||||
|
||||
package collector
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !noksmd
|
||||
// +build !noksmd
|
||||
|
||||
package collector
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !nokvm && (freebsd || dragonfly)
|
||||
// +build !nokvm
|
||||
// +build freebsd dragonfly
|
||||
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !nolnstat
|
||||
// +build !nolnstat
|
||||
|
||||
package collector
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build (darwin || dragonfly || freebsd || linux || netbsd || openbsd || solaris) && !noloadavg
|
||||
// +build darwin dragonfly freebsd linux netbsd openbsd solaris
|
||||
// +build !noloadavg
|
||||
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build (darwin || dragonfly || freebsd || netbsd || openbsd) && !noloadavg
|
||||
// +build darwin dragonfly freebsd netbsd openbsd
|
||||
// +build !noloadavg
|
||||
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !noloadavg
|
||||
// +build !noloadavg
|
||||
|
||||
package collector
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !noloadavg
|
||||
// +build !noloadavg
|
||||
|
||||
package collector
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !nologind
|
||||
// +build !nologind
|
||||
|
||||
package collector
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !nomdadm
|
||||
// +build !nomdadm
|
||||
|
||||
package collector
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build (darwin || linux || openbsd) && !nomeminfo
|
||||
// +build darwin linux openbsd
|
||||
// +build !nomeminfo
|
||||
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !nomeminfo
|
||||
// +build !nomeminfo
|
||||
|
||||
package collector
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !nomeminfo
|
||||
// +build !nomeminfo
|
||||
|
||||
package collector
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !nomeminfo_numa
|
||||
// +build !nomeminfo_numa
|
||||
|
||||
package collector
|
||||
|
|
|
@ -11,8 +11,8 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
// +build openbsd,!amd64
|
||||
// +build !nomeminfo
|
||||
//go:build openbsd && !amd64 && !nomeminfo
|
||||
// +build openbsd,!amd64,!nomeminfo
|
||||
|
||||
package collector
|
||||
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !nomeminfo
|
||||
// +build !nomeminfo
|
||||
|
||||
package collector
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build (freebsd || dragonfly) && !nomeminfo
|
||||
// +build freebsd dragonfly
|
||||
// +build !nomeminfo
|
||||
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !nomountstats
|
||||
// +build !nomountstats
|
||||
|
||||
package collector
|
||||
|
|
|
@ -11,8 +11,8 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
// +build !nonetclass
|
||||
// +build linux
|
||||
//go:build !nonetclass && linux
|
||||
// +build !nonetclass,linux
|
||||
|
||||
package collector
|
||||
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !nonetdev && (freebsd || dragonfly)
|
||||
// +build !nonetdev
|
||||
// +build freebsd dragonfly
|
||||
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !nonetdev
|
||||
// +build !nonetdev
|
||||
|
||||
package collector
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !nonetdev
|
||||
// +build !nonetdev
|
||||
|
||||
package collector
|
||||
|
|
|
@ -11,8 +11,8 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
// +build openbsd,!amd64
|
||||
// +build !nonetdev
|
||||
//go:build openbsd && !amd64 && !nonetdev
|
||||
// +build openbsd,!amd64,!nonetdev
|
||||
|
||||
package collector
|
||||
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !nonetdev
|
||||
// +build !nonetdev
|
||||
|
||||
package collector
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !nonetstat
|
||||
// +build !nonetstat
|
||||
|
||||
package collector
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !nonetworkroute
|
||||
// +build !nonetworkroute
|
||||
|
||||
package collector
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !nonfs
|
||||
// +build !nonfs
|
||||
|
||||
package collector
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !nonfsd
|
||||
// +build !nonfsd
|
||||
|
||||
package collector
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !nontp
|
||||
// +build !nontp
|
||||
|
||||
package collector
|
||||
|
|
|
@ -11,8 +11,8 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
// +build linux
|
||||
// +build !nonvme
|
||||
//go:build linux && !nonvme
|
||||
// +build linux,!nonvme
|
||||
|
||||
package collector
|
||||
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !noperf
|
||||
// +build !noperf
|
||||
|
||||
package collector
|
||||
|
@ -284,21 +285,30 @@ func NewPerfCollector(logger log.Logger) (Collector, error) {
|
|||
for _, cpu := range cpus {
|
||||
// Use -1 to profile all processes on the CPU, see:
|
||||
// man perf_event_open
|
||||
hwProf := perf.NewHardwareProfiler(-1, cpu)
|
||||
hwProf, err := perf.NewHardwareProfiler(-1, cpu)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if err := hwProf.Start(); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
collector.perfHwProfilers[cpu] = &hwProf
|
||||
collector.hwProfilerCPUMap[&hwProf] = cpu
|
||||
|
||||
swProf := perf.NewSoftwareProfiler(-1, cpu)
|
||||
swProf, err := perf.NewSoftwareProfiler(-1, cpu)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if err := swProf.Start(); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
collector.perfSwProfilers[cpu] = &swProf
|
||||
collector.swProfilerCPUMap[&swProf] = cpu
|
||||
|
||||
cacheProf := perf.NewCacheProfiler(-1, cpu)
|
||||
cacheProf, err := perf.NewCacheProfiler(-1, cpu)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if err := cacheProf.Start(); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !noprocesses
|
||||
// +build !noprocesses
|
||||
|
||||
package collector
|
||||
|
|
|
@ -11,8 +11,8 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
// +build !nopowersupplyclass
|
||||
// +build linux
|
||||
//go:build !nopowersupplyclass && linux
|
||||
// +build !nopowersupplyclass,linux
|
||||
|
||||
package collector
|
||||
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !nopressure
|
||||
// +build !nopressure
|
||||
|
||||
package collector
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !noprocesses
|
||||
// +build !noprocesses
|
||||
|
||||
package collector
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !noprocesses
|
||||
// +build !noprocesses
|
||||
|
||||
package collector
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !noqdisc
|
||||
// +build !noqdisc
|
||||
|
||||
package collector
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !norunit
|
||||
// +build !norunit
|
||||
|
||||
package collector
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !noshedstat
|
||||
// +build !noshedstat
|
||||
|
||||
package collector
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !nosockstat
|
||||
// +build !nosockstat
|
||||
|
||||
package collector
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !nosoftnet
|
||||
// +build !nosoftnet
|
||||
|
||||
package collector
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !nostat
|
||||
// +build !nostat
|
||||
|
||||
package collector
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !nosupervisord
|
||||
// +build !nosupervisord
|
||||
|
||||
package collector
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build (freebsd || dragonfly || openbsd || netbsd || darwin) && cgo
|
||||
// +build freebsd dragonfly openbsd netbsd darwin
|
||||
// +build cgo
|
||||
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !nosystemd
|
||||
// +build !nosystemd
|
||||
|
||||
package collector
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !notapestats
|
||||
// +build !notapestats
|
||||
|
||||
package collector
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !notcpstat
|
||||
// +build !notcpstat
|
||||
|
||||
package collector
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !notextfile
|
||||
// +build !notextfile
|
||||
|
||||
package collector
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !nothermalzone
|
||||
// +build !nothermalzone
|
||||
|
||||
package collector
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
//go:build !notime
|
||||
// +build !notime
|
||||
|
||||
package collector
|
||||
|
|
Some files were not shown because too many files have changed in this diff Show more
Loading…
Reference in a new issue