summaryrefslogtreecommitdiff
path: root/vendor/github.com/containerd/cgroups
diff options
context:
space:
mode:
Diffstat (limited to 'vendor/github.com/containerd/cgroups')
-rw-r--r--vendor/github.com/containerd/cgroups/Protobuild.toml46
-rw-r--r--vendor/github.com/containerd/cgroups/Vagrantfile46
-rw-r--r--vendor/github.com/containerd/cgroups/stats/v1/metrics.pb.go6125
-rw-r--r--vendor/github.com/containerd/cgroups/v2/stats/metrics.pb.go3992
-rw-r--r--vendor/github.com/containerd/cgroups/v3/.gitignore (renamed from vendor/github.com/containerd/cgroups/.gitignore)0
-rw-r--r--vendor/github.com/containerd/cgroups/v3/LICENSE (renamed from vendor/github.com/containerd/cgroups/LICENSE)0
-rw-r--r--vendor/github.com/containerd/cgroups/v3/Makefile (renamed from vendor/github.com/containerd/cgroups/Makefile)2
-rw-r--r--vendor/github.com/containerd/cgroups/v3/Protobuild.toml31
-rw-r--r--vendor/github.com/containerd/cgroups/v3/README.md (renamed from vendor/github.com/containerd/cgroups/README.md)90
-rw-r--r--vendor/github.com/containerd/cgroups/v3/cgroup1/blkio.go (renamed from vendor/github.com/containerd/cgroups/blkio.go)7
-rw-r--r--vendor/github.com/containerd/cgroups/v3/cgroup1/cgroup.go (renamed from vendor/github.com/containerd/cgroups/cgroup.go)54
-rw-r--r--vendor/github.com/containerd/cgroups/v3/cgroup1/control.go (renamed from vendor/github.com/containerd/cgroups/control.go)4
-rw-r--r--vendor/github.com/containerd/cgroups/v3/cgroup1/cpu.go (renamed from vendor/github.com/containerd/cgroups/cpu.go)6
-rw-r--r--vendor/github.com/containerd/cgroups/v3/cgroup1/cpuacct.go (renamed from vendor/github.com/containerd/cgroups/cpuacct.go)40
-rw-r--r--vendor/github.com/containerd/cgroups/v3/cgroup1/cpuset.go (renamed from vendor/github.com/containerd/cgroups/cpuset.go)13
-rw-r--r--vendor/github.com/containerd/cgroups/v3/cgroup1/devices.go (renamed from vendor/github.com/containerd/cgroups/devices.go)4
-rw-r--r--vendor/github.com/containerd/cgroups/v3/cgroup1/errors.go (renamed from vendor/github.com/containerd/cgroups/errors.go)2
-rw-r--r--vendor/github.com/containerd/cgroups/v3/cgroup1/freezer.go (renamed from vendor/github.com/containerd/cgroups/freezer.go)8
-rw-r--r--vendor/github.com/containerd/cgroups/v3/cgroup1/hierarchy.go (renamed from vendor/github.com/containerd/cgroups/hierarchy.go)2
-rw-r--r--vendor/github.com/containerd/cgroups/v3/cgroup1/hugetlb.go (renamed from vendor/github.com/containerd/cgroups/hugetlb.go)6
-rw-r--r--vendor/github.com/containerd/cgroups/v3/cgroup1/memory.go (renamed from vendor/github.com/containerd/cgroups/memory.go)74
-rw-r--r--vendor/github.com/containerd/cgroups/v3/cgroup1/named.go (renamed from vendor/github.com/containerd/cgroups/named.go)2
-rw-r--r--vendor/github.com/containerd/cgroups/v3/cgroup1/net_cls.go (renamed from vendor/github.com/containerd/cgroups/net_cls.go)4
-rw-r--r--vendor/github.com/containerd/cgroups/v3/cgroup1/net_prio.go (renamed from vendor/github.com/containerd/cgroups/net_prio.go)4
-rw-r--r--vendor/github.com/containerd/cgroups/v3/cgroup1/opts.go (renamed from vendor/github.com/containerd/cgroups/opts.go)13
-rw-r--r--vendor/github.com/containerd/cgroups/v3/cgroup1/paths.go (renamed from vendor/github.com/containerd/cgroups/paths.go)2
-rw-r--r--vendor/github.com/containerd/cgroups/v3/cgroup1/perf_event.go (renamed from vendor/github.com/containerd/cgroups/perf_event.go)2
-rw-r--r--vendor/github.com/containerd/cgroups/v3/cgroup1/pids.go (renamed from vendor/github.com/containerd/cgroups/pids.go)9
-rw-r--r--vendor/github.com/containerd/cgroups/v3/cgroup1/rdma.go (renamed from vendor/github.com/containerd/cgroups/rdma.go)11
-rw-r--r--vendor/github.com/containerd/cgroups/v3/cgroup1/state.go (renamed from vendor/github.com/containerd/cgroups/state.go)2
-rw-r--r--vendor/github.com/containerd/cgroups/v3/cgroup1/stats/doc.go (renamed from vendor/github.com/containerd/cgroups/v2/stats/doc.go)0
-rw-r--r--vendor/github.com/containerd/cgroups/v3/cgroup1/stats/metrics.pb.go1959
-rw-r--r--vendor/github.com/containerd/cgroups/v3/cgroup1/stats/metrics.pb.txt (renamed from vendor/github.com/containerd/cgroups/stats/v1/metrics.pb.txt)27
-rw-r--r--vendor/github.com/containerd/cgroups/v3/cgroup1/stats/metrics.proto (renamed from vendor/github.com/containerd/cgroups/stats/v1/metrics.proto)16
-rw-r--r--vendor/github.com/containerd/cgroups/v3/cgroup1/subsystem.go (renamed from vendor/github.com/containerd/cgroups/subsystem.go)7
-rw-r--r--vendor/github.com/containerd/cgroups/v3/cgroup1/systemd.go (renamed from vendor/github.com/containerd/cgroups/systemd.go)2
-rw-r--r--vendor/github.com/containerd/cgroups/v3/cgroup1/ticks.go (renamed from vendor/github.com/containerd/cgroups/ticks.go)2
-rw-r--r--vendor/github.com/containerd/cgroups/v3/cgroup1/utils.go (renamed from vendor/github.com/containerd/cgroups/utils.go)153
-rw-r--r--vendor/github.com/containerd/cgroups/v3/cgroup1/v1.go (renamed from vendor/github.com/containerd/cgroups/v1.go)6
-rw-r--r--vendor/github.com/containerd/cgroups/v3/cgroup2/cpu.go (renamed from vendor/github.com/containerd/cgroups/v2/cpu.go)2
-rw-r--r--vendor/github.com/containerd/cgroups/v3/cgroup2/devicefilter.go (renamed from vendor/github.com/containerd/cgroups/v2/devicefilter.go)2
-rw-r--r--vendor/github.com/containerd/cgroups/v3/cgroup2/ebpf.go (renamed from vendor/github.com/containerd/cgroups/v2/ebpf.go)2
-rw-r--r--vendor/github.com/containerd/cgroups/v3/cgroup2/errors.go (renamed from vendor/github.com/containerd/cgroups/v2/errors.go)2
-rw-r--r--vendor/github.com/containerd/cgroups/v3/cgroup2/hugetlb.go (renamed from vendor/github.com/containerd/cgroups/v2/hugetlb.go)2
-rw-r--r--vendor/github.com/containerd/cgroups/v3/cgroup2/io.go (renamed from vendor/github.com/containerd/cgroups/v2/io.go)2
-rw-r--r--vendor/github.com/containerd/cgroups/v3/cgroup2/manager.go (renamed from vendor/github.com/containerd/cgroups/v2/manager.go)175
-rw-r--r--vendor/github.com/containerd/cgroups/v3/cgroup2/memory.go (renamed from vendor/github.com/containerd/cgroups/v2/memory.go)2
-rw-r--r--vendor/github.com/containerd/cgroups/v3/cgroup2/paths.go (renamed from vendor/github.com/containerd/cgroups/v2/paths.go)2
-rw-r--r--vendor/github.com/containerd/cgroups/v3/cgroup2/pids.go (renamed from vendor/github.com/containerd/cgroups/v2/pids.go)2
-rw-r--r--vendor/github.com/containerd/cgroups/v3/cgroup2/rdma.go (renamed from vendor/github.com/containerd/cgroups/v2/rdma.go)2
-rw-r--r--vendor/github.com/containerd/cgroups/v3/cgroup2/state.go (renamed from vendor/github.com/containerd/cgroups/v2/state.go)6
-rw-r--r--vendor/github.com/containerd/cgroups/v3/cgroup2/stats/doc.go (renamed from vendor/github.com/containerd/cgroups/stats/v1/doc.go)2
-rw-r--r--vendor/github.com/containerd/cgroups/v3/cgroup2/stats/metrics.pb.go1333
-rw-r--r--vendor/github.com/containerd/cgroups/v3/cgroup2/stats/metrics.pb.txt (renamed from vendor/github.com/containerd/cgroups/v2/stats/metrics.pb.txt)9
-rw-r--r--vendor/github.com/containerd/cgroups/v3/cgroup2/stats/metrics.proto (renamed from vendor/github.com/containerd/cgroups/v2/stats/metrics.proto)4
-rw-r--r--vendor/github.com/containerd/cgroups/v3/cgroup2/utils.go (renamed from vendor/github.com/containerd/cgroups/v2/utils.go)24
-rw-r--r--vendor/github.com/containerd/cgroups/v3/utils.go150
57 files changed, 3937 insertions, 10559 deletions
diff --git a/vendor/github.com/containerd/cgroups/Protobuild.toml b/vendor/github.com/containerd/cgroups/Protobuild.toml
deleted file mode 100644
index 1c4c802fe..000000000
--- a/vendor/github.com/containerd/cgroups/Protobuild.toml
+++ /dev/null
@@ -1,46 +0,0 @@
-version = "unstable"
-generator = "gogoctrd"
-plugins = ["grpc"]
-
-# Control protoc include paths. Below are usually some good defaults, but feel
-# free to try it without them if it works for your project.
-[includes]
- # Include paths that will be added before all others. Typically, you want to
- # treat the root of the project as an include, but this may not be necessary.
- # before = ["."]
-
- # Paths that should be treated as include roots in relation to the vendor
- # directory. These will be calculated with the vendor directory nearest the
- # target package.
- # vendored = ["github.com/gogo/protobuf"]
- packages = ["github.com/gogo/protobuf"]
-
- # Paths that will be added untouched to the end of the includes. We use
- # `/usr/local/include` to pickup the common install location of protobuf.
- # This is the default.
- after = ["/usr/local/include", "/usr/include"]
-
-# This section maps protobuf imports to Go packages. These will become
-# `-M` directives in the call to the go protobuf generator.
-[packages]
- "gogoproto/gogo.proto" = "github.com/gogo/protobuf/gogoproto"
- "google/protobuf/any.proto" = "github.com/gogo/protobuf/types"
- "google/protobuf/descriptor.proto" = "github.com/gogo/protobuf/protoc-gen-gogo/descriptor"
- "google/protobuf/field_mask.proto" = "github.com/gogo/protobuf/types"
- "google/protobuf/timestamp.proto" = "github.com/gogo/protobuf/types"
-
-# Aggregrate the API descriptors to lock down API changes.
-[[descriptors]]
-prefix = "github.com/containerd/cgroups/stats/v1"
-target = "stats/v1/metrics.pb.txt"
-ignore_files = [
- "google/protobuf/descriptor.proto",
- "gogoproto/gogo.proto"
-]
-[[descriptors]]
-prefix = "github.com/containerd/cgroups/v2/stats"
-target = "v2/stats/metrics.pb.txt"
-ignore_files = [
- "google/protobuf/descriptor.proto",
- "gogoproto/gogo.proto"
-]
diff --git a/vendor/github.com/containerd/cgroups/Vagrantfile b/vendor/github.com/containerd/cgroups/Vagrantfile
deleted file mode 100644
index 9a4aac8cb..000000000
--- a/vendor/github.com/containerd/cgroups/Vagrantfile
+++ /dev/null
@@ -1,46 +0,0 @@
-# -*- mode: ruby -*-
-# vi: set ft=ruby :
-
-Vagrant.configure("2") do |config|
-# Fedora box is used for testing cgroup v2 support
- config.vm.box = "fedora/35-cloud-base"
- config.vm.provider :virtualbox do |v|
- v.memory = 4096
- v.cpus = 2
- end
- config.vm.provider :libvirt do |v|
- v.memory = 4096
- v.cpus = 2
- end
- config.vm.provision "shell", inline: <<-SHELL
- set -eux -o pipefail
- # configuration
- GO_VERSION="1.17.7"
-
- # install gcc and Golang
- dnf -y install gcc
- curl -fsSL "https://dl.google.com/go/go${GO_VERSION}.linux-amd64.tar.gz" | tar Cxz /usr/local
-
- # setup env vars
- cat >> /etc/profile.d/sh.local <<EOF
-PATH=/usr/local/go/bin:$PATH
-GO111MODULE=on
-export PATH GO111MODULE
-EOF
- source /etc/profile.d/sh.local
-
- # enter /root/go/src/github.com/containerd/cgroups
- mkdir -p /root/go/src/github.com/containerd
- ln -s /vagrant /root/go/src/github.com/containerd/cgroups
- cd /root/go/src/github.com/containerd/cgroups
-
- # create /test.sh
- cat > /test.sh <<EOF
-#!/bin/bash
-set -eux -o pipefail
-cd /root/go/src/github.com/containerd/cgroups
-go test -v ./...
-EOF
- chmod +x /test.sh
- SHELL
-end
diff --git a/vendor/github.com/containerd/cgroups/stats/v1/metrics.pb.go b/vendor/github.com/containerd/cgroups/stats/v1/metrics.pb.go
deleted file mode 100644
index 6d2d41770..000000000
--- a/vendor/github.com/containerd/cgroups/stats/v1/metrics.pb.go
+++ /dev/null
@@ -1,6125 +0,0 @@
-// Code generated by protoc-gen-gogo. DO NOT EDIT.
-// source: github.com/containerd/cgroups/stats/v1/metrics.proto
-
-package v1
-
-import (
- fmt "fmt"
- _ "github.com/gogo/protobuf/gogoproto"
- proto "github.com/gogo/protobuf/proto"
- io "io"
- math "math"
- math_bits "math/bits"
- reflect "reflect"
- strings "strings"
-)
-
-// Reference imports to suppress errors if they are not otherwise used.
-var _ = proto.Marshal
-var _ = fmt.Errorf
-var _ = math.Inf
-
-// This is a compile-time assertion to ensure that this generated file
-// is compatible with the proto package it is being compiled against.
-// A compilation error at this line likely means your copy of the
-// proto package needs to be updated.
-const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package
-
-type Metrics struct {
- Hugetlb []*HugetlbStat `protobuf:"bytes,1,rep,name=hugetlb,proto3" json:"hugetlb,omitempty"`
- Pids *PidsStat `protobuf:"bytes,2,opt,name=pids,proto3" json:"pids,omitempty"`
- CPU *CPUStat `protobuf:"bytes,3,opt,name=cpu,proto3" json:"cpu,omitempty"`
- Memory *MemoryStat `protobuf:"bytes,4,opt,name=memory,proto3" json:"memory,omitempty"`
- Blkio *BlkIOStat `protobuf:"bytes,5,opt,name=blkio,proto3" json:"blkio,omitempty"`
- Rdma *RdmaStat `protobuf:"bytes,6,opt,name=rdma,proto3" json:"rdma,omitempty"`
- Network []*NetworkStat `protobuf:"bytes,7,rep,name=network,proto3" json:"network,omitempty"`
- CgroupStats *CgroupStats `protobuf:"bytes,8,opt,name=cgroup_stats,json=cgroupStats,proto3" json:"cgroup_stats,omitempty"`
- MemoryOomControl *MemoryOomControl `protobuf:"bytes,9,opt,name=memory_oom_control,json=memoryOomControl,proto3" json:"memory_oom_control,omitempty"`
- XXX_NoUnkeyedLiteral struct{} `json:"-"`
- XXX_unrecognized []byte `json:"-"`
- XXX_sizecache int32 `json:"-"`
-}
-
-func (m *Metrics) Reset() { *m = Metrics{} }
-func (*Metrics) ProtoMessage() {}
-func (*Metrics) Descriptor() ([]byte, []int) {
- return fileDescriptor_a17b2d87c332bfaa, []int{0}
-}
-func (m *Metrics) XXX_Unmarshal(b []byte) error {
- return m.Unmarshal(b)
-}
-func (m *Metrics) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
- if deterministic {
- return xxx_messageInfo_Metrics.Marshal(b, m, deterministic)
- } else {
- b = b[:cap(b)]
- n, err := m.MarshalToSizedBuffer(b)
- if err != nil {
- return nil, err
- }
- return b[:n], nil
- }
-}
-func (m *Metrics) XXX_Merge(src proto.Message) {
- xxx_messageInfo_Metrics.Merge(m, src)
-}
-func (m *Metrics) XXX_Size() int {
- return m.Size()
-}
-func (m *Metrics) XXX_DiscardUnknown() {
- xxx_messageInfo_Metrics.DiscardUnknown(m)
-}
-
-var xxx_messageInfo_Metrics proto.InternalMessageInfo
-
-type HugetlbStat struct {
- Usage uint64 `protobuf:"varint,1,opt,name=usage,proto3" json:"usage,omitempty"`
- Max uint64 `protobuf:"varint,2,opt,name=max,proto3" json:"max,omitempty"`
- Failcnt uint64 `protobuf:"varint,3,opt,name=failcnt,proto3" json:"failcnt,omitempty"`
- Pagesize string `protobuf:"bytes,4,opt,name=pagesize,proto3" json:"pagesize,omitempty"`
- XXX_NoUnkeyedLiteral struct{} `json:"-"`
- XXX_unrecognized []byte `json:"-"`
- XXX_sizecache int32 `json:"-"`
-}
-
-func (m *HugetlbStat) Reset() { *m = HugetlbStat{} }
-func (*HugetlbStat) ProtoMessage() {}
-func (*HugetlbStat) Descriptor() ([]byte, []int) {
- return fileDescriptor_a17b2d87c332bfaa, []int{1}
-}
-func (m *HugetlbStat) XXX_Unmarshal(b []byte) error {
- return m.Unmarshal(b)
-}
-func (m *HugetlbStat) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
- if deterministic {
- return xxx_messageInfo_HugetlbStat.Marshal(b, m, deterministic)
- } else {
- b = b[:cap(b)]
- n, err := m.MarshalToSizedBuffer(b)
- if err != nil {
- return nil, err
- }
- return b[:n], nil
- }
-}
-func (m *HugetlbStat) XXX_Merge(src proto.Message) {
- xxx_messageInfo_HugetlbStat.Merge(m, src)
-}
-func (m *HugetlbStat) XXX_Size() int {
- return m.Size()
-}
-func (m *HugetlbStat) XXX_DiscardUnknown() {
- xxx_messageInfo_HugetlbStat.DiscardUnknown(m)
-}
-
-var xxx_messageInfo_HugetlbStat proto.InternalMessageInfo
-
-type PidsStat struct {
- Current uint64 `protobuf:"varint,1,opt,name=current,proto3" json:"current,omitempty"`
- Limit uint64 `protobuf:"varint,2,opt,name=limit,proto3" json:"limit,omitempty"`
- XXX_NoUnkeyedLiteral struct{} `json:"-"`
- XXX_unrecognized []byte `json:"-"`
- XXX_sizecache int32 `json:"-"`
-}
-
-func (m *PidsStat) Reset() { *m = PidsStat{} }
-func (*PidsStat) ProtoMessage() {}
-func (*PidsStat) Descriptor() ([]byte, []int) {
- return fileDescriptor_a17b2d87c332bfaa, []int{2}
-}
-func (m *PidsStat) XXX_Unmarshal(b []byte) error {
- return m.Unmarshal(b)
-}
-func (m *PidsStat) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
- if deterministic {
- return xxx_messageInfo_PidsStat.Marshal(b, m, deterministic)
- } else {
- b = b[:cap(b)]
- n, err := m.MarshalToSizedBuffer(b)
- if err != nil {
- return nil, err
- }
- return b[:n], nil
- }
-}
-func (m *PidsStat) XXX_Merge(src proto.Message) {
- xxx_messageInfo_PidsStat.Merge(m, src)
-}
-func (m *PidsStat) XXX_Size() int {
- return m.Size()
-}
-func (m *PidsStat) XXX_DiscardUnknown() {
- xxx_messageInfo_PidsStat.DiscardUnknown(m)
-}
-
-var xxx_messageInfo_PidsStat proto.InternalMessageInfo
-
-type CPUStat struct {
- Usage *CPUUsage `protobuf:"bytes,1,opt,name=usage,proto3" json:"usage,omitempty"`
- Throttling *Throttle `protobuf:"bytes,2,opt,name=throttling,proto3" json:"throttling,omitempty"`
- XXX_NoUnkeyedLiteral struct{} `json:"-"`
- XXX_unrecognized []byte `json:"-"`
- XXX_sizecache int32 `json:"-"`
-}
-
-func (m *CPUStat) Reset() { *m = CPUStat{} }
-func (*CPUStat) ProtoMessage() {}
-func (*CPUStat) Descriptor() ([]byte, []int) {
- return fileDescriptor_a17b2d87c332bfaa, []int{3}
-}
-func (m *CPUStat) XXX_Unmarshal(b []byte) error {
- return m.Unmarshal(b)
-}
-func (m *CPUStat) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
- if deterministic {
- return xxx_messageInfo_CPUStat.Marshal(b, m, deterministic)
- } else {
- b = b[:cap(b)]
- n, err := m.MarshalToSizedBuffer(b)
- if err != nil {
- return nil, err
- }
- return b[:n], nil
- }
-}
-func (m *CPUStat) XXX_Merge(src proto.Message) {
- xxx_messageInfo_CPUStat.Merge(m, src)
-}
-func (m *CPUStat) XXX_Size() int {
- return m.Size()
-}
-func (m *CPUStat) XXX_DiscardUnknown() {
- xxx_messageInfo_CPUStat.DiscardUnknown(m)
-}
-
-var xxx_messageInfo_CPUStat proto.InternalMessageInfo
-
-type CPUUsage struct {
- // values in nanoseconds
- Total uint64 `protobuf:"varint,1,opt,name=total,proto3" json:"total,omitempty"`
- Kernel uint64 `protobuf:"varint,2,opt,name=kernel,proto3" json:"kernel,omitempty"`
- User uint64 `protobuf:"varint,3,opt,name=user,proto3" json:"user,omitempty"`
- PerCPU []uint64 `protobuf:"varint,4,rep,packed,name=per_cpu,json=perCpu,proto3" json:"per_cpu,omitempty"`
- XXX_NoUnkeyedLiteral struct{} `json:"-"`
- XXX_unrecognized []byte `json:"-"`
- XXX_sizecache int32 `json:"-"`
-}
-
-func (m *CPUUsage) Reset() { *m = CPUUsage{} }
-func (*CPUUsage) ProtoMessage() {}
-func (*CPUUsage) Descriptor() ([]byte, []int) {
- return fileDescriptor_a17b2d87c332bfaa, []int{4}
-}
-func (m *CPUUsage) XXX_Unmarshal(b []byte) error {
- return m.Unmarshal(b)
-}
-func (m *CPUUsage) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
- if deterministic {
- return xxx_messageInfo_CPUUsage.Marshal(b, m, deterministic)
- } else {
- b = b[:cap(b)]
- n, err := m.MarshalToSizedBuffer(b)
- if err != nil {
- return nil, err
- }
- return b[:n], nil
- }
-}
-func (m *CPUUsage) XXX_Merge(src proto.Message) {
- xxx_messageInfo_CPUUsage.Merge(m, src)
-}
-func (m *CPUUsage) XXX_Size() int {
- return m.Size()
-}
-func (m *CPUUsage) XXX_DiscardUnknown() {
- xxx_messageInfo_CPUUsage.DiscardUnknown(m)
-}
-
-var xxx_messageInfo_CPUUsage proto.InternalMessageInfo
-
-type Throttle struct {
- Periods uint64 `protobuf:"varint,1,opt,name=periods,proto3" json:"periods,omitempty"`
- ThrottledPeriods uint64 `protobuf:"varint,2,opt,name=throttled_periods,json=throttledPeriods,proto3" json:"throttled_periods,omitempty"`
- ThrottledTime uint64 `protobuf:"varint,3,opt,name=throttled_time,json=throttledTime,proto3" json:"throttled_time,omitempty"`
- XXX_NoUnkeyedLiteral struct{} `json:"-"`
- XXX_unrecognized []byte `json:"-"`
- XXX_sizecache int32 `json:"-"`
-}
-
-func (m *Throttle) Reset() { *m = Throttle{} }
-func (*Throttle) ProtoMessage() {}
-func (*Throttle) Descriptor() ([]byte, []int) {
- return fileDescriptor_a17b2d87c332bfaa, []int{5}
-}
-func (m *Throttle) XXX_Unmarshal(b []byte) error {
- return m.Unmarshal(b)
-}
-func (m *Throttle) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
- if deterministic {
- return xxx_messageInfo_Throttle.Marshal(b, m, deterministic)
- } else {
- b = b[:cap(b)]
- n, err := m.MarshalToSizedBuffer(b)
- if err != nil {
- return nil, err
- }
- return b[:n], nil
- }
-}
-func (m *Throttle) XXX_Merge(src proto.Message) {
- xxx_messageInfo_Throttle.Merge(m, src)
-}
-func (m *Throttle) XXX_Size() int {
- return m.Size()
-}
-func (m *Throttle) XXX_DiscardUnknown() {
- xxx_messageInfo_Throttle.DiscardUnknown(m)
-}
-
-var xxx_messageInfo_Throttle proto.InternalMessageInfo
-
-type MemoryStat struct {
- Cache uint64 `protobuf:"varint,1,opt,name=cache,proto3" json:"cache,omitempty"`
- RSS uint64 `protobuf:"varint,2,opt,name=rss,proto3" json:"rss,omitempty"`
- RSSHuge uint64 `protobuf:"varint,3,opt,name=rss_huge,json=rssHuge,proto3" json:"rss_huge,omitempty"`
- MappedFile uint64 `protobuf:"varint,4,opt,name=mapped_file,json=mappedFile,proto3" json:"mapped_file,omitempty"`
- Dirty uint64 `protobuf:"varint,5,opt,name=dirty,proto3" json:"dirty,omitempty"`
- Writeback uint64 `protobuf:"varint,6,opt,name=writeback,proto3" json:"writeback,omitempty"`
- PgPgIn uint64 `protobuf:"varint,7,opt,name=pg_pg_in,json=pgPgIn,proto3" json:"pg_pg_in,omitempty"`
- PgPgOut uint64 `protobuf:"varint,8,opt,name=pg_pg_out,json=pgPgOut,proto3" json:"pg_pg_out,omitempty"`
- PgFault uint64 `protobuf:"varint,9,opt,name=pg_fault,json=pgFault,proto3" json:"pg_fault,omitempty"`
- PgMajFault uint64 `protobuf:"varint,10,opt,name=pg_maj_fault,json=pgMajFault,proto3" json:"pg_maj_fault,omitempty"`
- InactiveAnon uint64 `protobuf:"varint,11,opt,name=inactive_anon,json=inactiveAnon,proto3" json:"inactive_anon,omitempty"`
- ActiveAnon uint64 `protobuf:"varint,12,opt,name=active_anon,json=activeAnon,proto3" json:"active_anon,omitempty"`
- InactiveFile uint64 `protobuf:"varint,13,opt,name=inactive_file,json=inactiveFile,proto3" json:"inactive_file,omitempty"`
- ActiveFile uint64 `protobuf:"varint,14,opt,name=active_file,json=activeFile,proto3" json:"active_file,omitempty"`
- Unevictable uint64 `protobuf:"varint,15,opt,name=unevictable,proto3" json:"unevictable,omitempty"`
- HierarchicalMemoryLimit uint64 `protobuf:"varint,16,opt,name=hierarchical_memory_limit,json=hierarchicalMemoryLimit,proto3" json:"hierarchical_memory_limit,omitempty"`
- HierarchicalSwapLimit uint64 `protobuf:"varint,17,opt,name=hierarchical_swap_limit,json=hierarchicalSwapLimit,proto3" json:"hierarchical_swap_limit,omitempty"`
- TotalCache uint64 `protobuf:"varint,18,opt,name=total_cache,json=totalCache,proto3" json:"total_cache,omitempty"`
- TotalRSS uint64 `protobuf:"varint,19,opt,name=total_rss,json=totalRss,proto3" json:"total_rss,omitempty"`
- TotalRSSHuge uint64 `protobuf:"varint,20,opt,name=total_rss_huge,json=totalRssHuge,proto3" json:"total_rss_huge,omitempty"`
- TotalMappedFile uint64 `protobuf:"varint,21,opt,name=total_mapped_file,json=totalMappedFile,proto3" json:"total_mapped_file,omitempty"`
- TotalDirty uint64 `protobuf:"varint,22,opt,name=total_dirty,json=totalDirty,proto3" json:"total_dirty,omitempty"`
- TotalWriteback uint64 `protobuf:"varint,23,opt,name=total_writeback,json=totalWriteback,proto3" json:"total_writeback,omitempty"`
- TotalPgPgIn uint64 `protobuf:"varint,24,opt,name=total_pg_pg_in,json=totalPgPgIn,proto3" json:"total_pg_pg_in,omitempty"`
- TotalPgPgOut uint64 `protobuf:"varint,25,opt,name=total_pg_pg_out,json=totalPgPgOut,proto3" json:"total_pg_pg_out,omitempty"`
- TotalPgFault uint64 `protobuf:"varint,26,opt,name=total_pg_fault,json=totalPgFault,proto3" json:"total_pg_fault,omitempty"`
- TotalPgMajFault uint64 `protobuf:"varint,27,opt,name=total_pg_maj_fault,json=totalPgMajFault,proto3" json:"total_pg_maj_fault,omitempty"`
- TotalInactiveAnon uint64 `protobuf:"varint,28,opt,name=total_inactive_anon,json=totalInactiveAnon,proto3" json:"total_inactive_anon,omitempty"`
- TotalActiveAnon uint64 `protobuf:"varint,29,opt,name=total_active_anon,json=totalActiveAnon,proto3" json:"total_active_anon,omitempty"`
- TotalInactiveFile uint64 `protobuf:"varint,30,opt,name=total_inactive_file,json=totalInactiveFile,proto3" json:"total_inactive_file,omitempty"`
- TotalActiveFile uint64 `protobuf:"varint,31,opt,name=total_active_file,json=totalActiveFile,proto3" json:"total_active_file,omitempty"`
- TotalUnevictable uint64 `protobuf:"varint,32,opt,name=total_unevictable,json=totalUnevictable,proto3" json:"total_unevictable,omitempty"`
- Usage *MemoryEntry `protobuf:"bytes,33,opt,name=usage,proto3" json:"usage,omitempty"`
- Swap *MemoryEntry `protobuf:"bytes,34,opt,name=swap,proto3" json:"swap,omitempty"`
- Kernel *MemoryEntry `protobuf:"bytes,35,opt,name=kernel,proto3" json:"kernel,omitempty"`
- KernelTCP *MemoryEntry `protobuf:"bytes,36,opt,name=kernel_tcp,json=kernelTcp,proto3" json:"kernel_tcp,omitempty"`
- XXX_NoUnkeyedLiteral struct{} `json:"-"`
- XXX_unrecognized []byte `json:"-"`
- XXX_sizecache int32 `json:"-"`
-}
-
-func (m *MemoryStat) Reset() { *m = MemoryStat{} }
-func (*MemoryStat) ProtoMessage() {}
-func (*MemoryStat) Descriptor() ([]byte, []int) {
- return fileDescriptor_a17b2d87c332bfaa, []int{6}
-}
-func (m *MemoryStat) XXX_Unmarshal(b []byte) error {
- return m.Unmarshal(b)
-}
-func (m *MemoryStat) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
- if deterministic {
- return xxx_messageInfo_MemoryStat.Marshal(b, m, deterministic)
- } else {
- b = b[:cap(b)]
- n, err := m.MarshalToSizedBuffer(b)
- if err != nil {
- return nil, err
- }
- return b[:n], nil
- }
-}
-func (m *MemoryStat) XXX_Merge(src proto.Message) {
- xxx_messageInfo_MemoryStat.Merge(m, src)
-}
-func (m *MemoryStat) XXX_Size() int {
- return m.Size()
-}
-func (m *MemoryStat) XXX_DiscardUnknown() {
- xxx_messageInfo_MemoryStat.DiscardUnknown(m)
-}
-
-var xxx_messageInfo_MemoryStat proto.InternalMessageInfo
-
-type MemoryEntry struct {
- Limit uint64 `protobuf:"varint,1,opt,name=limit,proto3" json:"limit,omitempty"`
- Usage uint64 `protobuf:"varint,2,opt,name=usage,proto3" json:"usage,omitempty"`
- Max uint64 `protobuf:"varint,3,opt,name=max,proto3" json:"max,omitempty"`
- Failcnt uint64 `protobuf:"varint,4,opt,name=failcnt,proto3" json:"failcnt,omitempty"`
- XXX_NoUnkeyedLiteral struct{} `json:"-"`
- XXX_unrecognized []byte `json:"-"`
- XXX_sizecache int32 `json:"-"`
-}
-
-func (m *MemoryEntry) Reset() { *m = MemoryEntry{} }
-func (*MemoryEntry) ProtoMessage() {}
-func (*MemoryEntry) Descriptor() ([]byte, []int) {
- return fileDescriptor_a17b2d87c332bfaa, []int{7}
-}
-func (m *MemoryEntry) XXX_Unmarshal(b []byte) error {
- return m.Unmarshal(b)
-}
-func (m *MemoryEntry) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
- if deterministic {
- return xxx_messageInfo_MemoryEntry.Marshal(b, m, deterministic)
- } else {
- b = b[:cap(b)]
- n, err := m.MarshalToSizedBuffer(b)
- if err != nil {
- return nil, err
- }
- return b[:n], nil
- }
-}
-func (m *MemoryEntry) XXX_Merge(src proto.Message) {
- xxx_messageInfo_MemoryEntry.Merge(m, src)
-}
-func (m *MemoryEntry) XXX_Size() int {
- return m.Size()
-}
-func (m *MemoryEntry) XXX_DiscardUnknown() {
- xxx_messageInfo_MemoryEntry.DiscardUnknown(m)
-}
-
-var xxx_messageInfo_MemoryEntry proto.InternalMessageInfo
-
-type MemoryOomControl struct {
- OomKillDisable uint64 `protobuf:"varint,1,opt,name=oom_kill_disable,json=oomKillDisable,proto3" json:"oom_kill_disable,omitempty"`
- UnderOom uint64 `protobuf:"varint,2,opt,name=under_oom,json=underOom,proto3" json:"under_oom,omitempty"`
- OomKill uint64 `protobuf:"varint,3,opt,name=oom_kill,json=oomKill,proto3" json:"oom_kill,omitempty"`
- XXX_NoUnkeyedLiteral struct{} `json:"-"`
- XXX_unrecognized []byte `json:"-"`
- XXX_sizecache int32 `json:"-"`
-}
-
-func (m *MemoryOomControl) Reset() { *m = MemoryOomControl{} }
-func (*MemoryOomControl) ProtoMessage() {}
-func (*MemoryOomControl) Descriptor() ([]byte, []int) {
- return fileDescriptor_a17b2d87c332bfaa, []int{8}
-}
-func (m *MemoryOomControl) XXX_Unmarshal(b []byte) error {
- return m.Unmarshal(b)
-}
-func (m *MemoryOomControl) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
- if deterministic {
- return xxx_messageInfo_MemoryOomControl.Marshal(b, m, deterministic)
- } else {
- b = b[:cap(b)]
- n, err := m.MarshalToSizedBuffer(b)
- if err != nil {
- return nil, err
- }
- return b[:n], nil
- }
-}
-func (m *MemoryOomControl) XXX_Merge(src proto.Message) {
- xxx_messageInfo_MemoryOomControl.Merge(m, src)
-}
-func (m *MemoryOomControl) XXX_Size() int {
- return m.Size()
-}
-func (m *MemoryOomControl) XXX_DiscardUnknown() {
- xxx_messageInfo_MemoryOomControl.DiscardUnknown(m)
-}
-
-var xxx_messageInfo_MemoryOomControl proto.InternalMessageInfo
-
-type BlkIOStat struct {
- IoServiceBytesRecursive []*BlkIOEntry `protobuf:"bytes,1,rep,name=io_service_bytes_recursive,json=ioServiceBytesRecursive,proto3" json:"io_service_bytes_recursive,omitempty"`
- IoServicedRecursive []*BlkIOEntry `protobuf:"bytes,2,rep,name=io_serviced_recursive,json=ioServicedRecursive,proto3" json:"io_serviced_recursive,omitempty"`
- IoQueuedRecursive []*BlkIOEntry `protobuf:"bytes,3,rep,name=io_queued_recursive,json=ioQueuedRecursive,proto3" json:"io_queued_recursive,omitempty"`
- IoServiceTimeRecursive []*BlkIOEntry `protobuf:"bytes,4,rep,name=io_service_time_recursive,json=ioServiceTimeRecursive,proto3" json:"io_service_time_recursive,omitempty"`
- IoWaitTimeRecursive []*BlkIOEntry `protobuf:"bytes,5,rep,name=io_wait_time_recursive,json=ioWaitTimeRecursive,proto3" json:"io_wait_time_recursive,omitempty"`
- IoMergedRecursive []*BlkIOEntry `protobuf:"bytes,6,rep,name=io_merged_recursive,json=ioMergedRecursive,proto3" json:"io_merged_recursive,omitempty"`
- IoTimeRecursive []*BlkIOEntry `protobuf:"bytes,7,rep,name=io_time_recursive,json=ioTimeRecursive,proto3" json:"io_time_recursive,omitempty"`
- SectorsRecursive []*BlkIOEntry `protobuf:"bytes,8,rep,name=sectors_recursive,json=sectorsRecursive,proto3" json:"sectors_recursive,omitempty"`
- XXX_NoUnkeyedLiteral struct{} `json:"-"`
- XXX_unrecognized []byte `json:"-"`
- XXX_sizecache int32 `json:"-"`
-}
-
-func (m *BlkIOStat) Reset() { *m = BlkIOStat{} }
-func (*BlkIOStat) ProtoMessage() {}
-func (*BlkIOStat) Descriptor() ([]byte, []int) {
- return fileDescriptor_a17b2d87c332bfaa, []int{9}
-}
-func (m *BlkIOStat) XXX_Unmarshal(b []byte) error {
- return m.Unmarshal(b)
-}
-func (m *BlkIOStat) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
- if deterministic {
- return xxx_messageInfo_BlkIOStat.Marshal(b, m, deterministic)
- } else {
- b = b[:cap(b)]
- n, err := m.MarshalToSizedBuffer(b)
- if err != nil {
- return nil, err
- }
- return b[:n], nil
- }
-}
-func (m *BlkIOStat) XXX_Merge(src proto.Message) {
- xxx_messageInfo_BlkIOStat.Merge(m, src)
-}
-func (m *BlkIOStat) XXX_Size() int {
- return m.Size()
-}
-func (m *BlkIOStat) XXX_DiscardUnknown() {
- xxx_messageInfo_BlkIOStat.DiscardUnknown(m)
-}
-
-var xxx_messageInfo_BlkIOStat proto.InternalMessageInfo
-
-type BlkIOEntry struct {
- Op string `protobuf:"bytes,1,opt,name=op,proto3" json:"op,omitempty"`
- Device string `protobuf:"bytes,2,opt,name=device,proto3" json:"device,omitempty"`
- Major uint64 `protobuf:"varint,3,opt,name=major,proto3" json:"major,omitempty"`
- Minor uint64 `protobuf:"varint,4,opt,name=minor,proto3" json:"minor,omitempty"`
- Value uint64 `protobuf:"varint,5,opt,name=value,proto3" json:"value,omitempty"`
- XXX_NoUnkeyedLiteral struct{} `json:"-"`
- XXX_unrecognized []byte `json:"-"`
- XXX_sizecache int32 `json:"-"`
-}
-
-func (m *BlkIOEntry) Reset() { *m = BlkIOEntry{} }
-func (*BlkIOEntry) ProtoMessage() {}
-func (*BlkIOEntry) Descriptor() ([]byte, []int) {
- return fileDescriptor_a17b2d87c332bfaa, []int{10}
-}
-func (m *BlkIOEntry) XXX_Unmarshal(b []byte) error {
- return m.Unmarshal(b)
-}
-func (m *BlkIOEntry) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
- if deterministic {
- return xxx_messageInfo_BlkIOEntry.Marshal(b, m, deterministic)
- } else {
- b = b[:cap(b)]
- n, err := m.MarshalToSizedBuffer(b)
- if err != nil {
- return nil, err
- }
- return b[:n], nil
- }
-}
-func (m *BlkIOEntry) XXX_Merge(src proto.Message) {
- xxx_messageInfo_BlkIOEntry.Merge(m, src)
-}
-func (m *BlkIOEntry) XXX_Size() int {
- return m.Size()
-}
-func (m *BlkIOEntry) XXX_DiscardUnknown() {
- xxx_messageInfo_BlkIOEntry.DiscardUnknown(m)
-}
-
-var xxx_messageInfo_BlkIOEntry proto.InternalMessageInfo
-
-type RdmaStat struct {
- Current []*RdmaEntry `protobuf:"bytes,1,rep,name=current,proto3" json:"current,omitempty"`
- Limit []*RdmaEntry `protobuf:"bytes,2,rep,name=limit,proto3" json:"limit,omitempty"`
- XXX_NoUnkeyedLiteral struct{} `json:"-"`
- XXX_unrecognized []byte `json:"-"`
- XXX_sizecache int32 `json:"-"`
-}
-
-func (m *RdmaStat) Reset() { *m = RdmaStat{} }
-func (*RdmaStat) ProtoMessage() {}
-func (*RdmaStat) Descriptor() ([]byte, []int) {
- return fileDescriptor_a17b2d87c332bfaa, []int{11}
-}
-func (m *RdmaStat) XXX_Unmarshal(b []byte) error {
- return m.Unmarshal(b)
-}
-func (m *RdmaStat) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
- if deterministic {
- return xxx_messageInfo_RdmaStat.Marshal(b, m, deterministic)
- } else {
- b = b[:cap(b)]
- n, err := m.MarshalToSizedBuffer(b)
- if err != nil {
- return nil, err
- }
- return b[:n], nil
- }
-}
-func (m *RdmaStat) XXX_Merge(src proto.Message) {
- xxx_messageInfo_RdmaStat.Merge(m, src)
-}
-func (m *RdmaStat) XXX_Size() int {
- return m.Size()
-}
-func (m *RdmaStat) XXX_DiscardUnknown() {
- xxx_messageInfo_RdmaStat.DiscardUnknown(m)
-}
-
-var xxx_messageInfo_RdmaStat proto.InternalMessageInfo
-
-type RdmaEntry struct {
- Device string `protobuf:"bytes,1,opt,name=device,proto3" json:"device,omitempty"`
- HcaHandles uint32 `protobuf:"varint,2,opt,name=hca_handles,json=hcaHandles,proto3" json:"hca_handles,omitempty"`
- HcaObjects uint32 `protobuf:"varint,3,opt,name=hca_objects,json=hcaObjects,proto3" json:"hca_objects,omitempty"`
- XXX_NoUnkeyedLiteral struct{} `json:"-"`
- XXX_unrecognized []byte `json:"-"`
- XXX_sizecache int32 `json:"-"`
-}
-
-func (m *RdmaEntry) Reset() { *m = RdmaEntry{} }
-func (*RdmaEntry) ProtoMessage() {}
-func (*RdmaEntry) Descriptor() ([]byte, []int) {
- return fileDescriptor_a17b2d87c332bfaa, []int{12}
-}
-func (m *RdmaEntry) XXX_Unmarshal(b []byte) error {
- return m.Unmarshal(b)
-}
-func (m *RdmaEntry) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
- if deterministic {
- return xxx_messageInfo_RdmaEntry.Marshal(b, m, deterministic)
- } else {
- b = b[:cap(b)]
- n, err := m.MarshalToSizedBuffer(b)
- if err != nil {
- return nil, err
- }
- return b[:n], nil
- }
-}
-func (m *RdmaEntry) XXX_Merge(src proto.Message) {
- xxx_messageInfo_RdmaEntry.Merge(m, src)
-}
-func (m *RdmaEntry) XXX_Size() int {
- return m.Size()
-}
-func (m *RdmaEntry) XXX_DiscardUnknown() {
- xxx_messageInfo_RdmaEntry.DiscardUnknown(m)
-}
-
-var xxx_messageInfo_RdmaEntry proto.InternalMessageInfo
-
-type NetworkStat struct {
- Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
- RxBytes uint64 `protobuf:"varint,2,opt,name=rx_bytes,json=rxBytes,proto3" json:"rx_bytes,omitempty"`
- RxPackets uint64 `protobuf:"varint,3,opt,name=rx_packets,json=rxPackets,proto3" json:"rx_packets,omitempty"`
- RxErrors uint64 `protobuf:"varint,4,opt,name=rx_errors,json=rxErrors,proto3" json:"rx_errors,omitempty"`
- RxDropped uint64 `protobuf:"varint,5,opt,name=rx_dropped,json=rxDropped,proto3" json:"rx_dropped,omitempty"`
- TxBytes uint64 `protobuf:"varint,6,opt,name=tx_bytes,json=txBytes,proto3" json:"tx_bytes,omitempty"`
- TxPackets uint64 `protobuf:"varint,7,opt,name=tx_packets,json=txPackets,proto3" json:"tx_packets,omitempty"`
- TxErrors uint64 `protobuf:"varint,8,opt,name=tx_errors,json=txErrors,proto3" json:"tx_errors,omitempty"`
- TxDropped uint64 `protobuf:"varint,9,opt,name=tx_dropped,json=txDropped,proto3" json:"tx_dropped,omitempty"`
- XXX_NoUnkeyedLiteral struct{} `json:"-"`
- XXX_unrecognized []byte `json:"-"`
- XXX_sizecache int32 `json:"-"`
-}
-
-func (m *NetworkStat) Reset() { *m = NetworkStat{} }
-func (*NetworkStat) ProtoMessage() {}
-func (*NetworkStat) Descriptor() ([]byte, []int) {
- return fileDescriptor_a17b2d87c332bfaa, []int{13}
-}
-func (m *NetworkStat) XXX_Unmarshal(b []byte) error {
- return m.Unmarshal(b)
-}
-func (m *NetworkStat) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
- if deterministic {
- return xxx_messageInfo_NetworkStat.Marshal(b, m, deterministic)
- } else {
- b = b[:cap(b)]
- n, err := m.MarshalToSizedBuffer(b)
- if err != nil {
- return nil, err
- }
- return b[:n], nil
- }
-}
-func (m *NetworkStat) XXX_Merge(src proto.Message) {
- xxx_messageInfo_NetworkStat.Merge(m, src)
-}
-func (m *NetworkStat) XXX_Size() int {
- return m.Size()
-}
-func (m *NetworkStat) XXX_DiscardUnknown() {
- xxx_messageInfo_NetworkStat.DiscardUnknown(m)
-}
-
-var xxx_messageInfo_NetworkStat proto.InternalMessageInfo
-
-// CgroupStats exports per-cgroup statistics.
-type CgroupStats struct {
- // number of tasks sleeping
- NrSleeping uint64 `protobuf:"varint,1,opt,name=nr_sleeping,json=nrSleeping,proto3" json:"nr_sleeping,omitempty"`
- // number of tasks running
- NrRunning uint64 `protobuf:"varint,2,opt,name=nr_running,json=nrRunning,proto3" json:"nr_running,omitempty"`
- // number of tasks in stopped state
- NrStopped uint64 `protobuf:"varint,3,opt,name=nr_stopped,json=nrStopped,proto3" json:"nr_stopped,omitempty"`
- // number of tasks in uninterruptible state
- NrUninterruptible uint64 `protobuf:"varint,4,opt,name=nr_uninterruptible,json=nrUninterruptible,proto3" json:"nr_uninterruptible,omitempty"`
- // number of tasks waiting on IO
- NrIoWait uint64 `protobuf:"varint,5,opt,name=nr_io_wait,json=nrIoWait,proto3" json:"nr_io_wait,omitempty"`
- XXX_NoUnkeyedLiteral struct{} `json:"-"`
- XXX_unrecognized []byte `json:"-"`
- XXX_sizecache int32 `json:"-"`
-}
-
-func (m *CgroupStats) Reset() { *m = CgroupStats{} }
-func (*CgroupStats) ProtoMessage() {}
-func (*CgroupStats) Descriptor() ([]byte, []int) {
- return fileDescriptor_a17b2d87c332bfaa, []int{14}
-}
-func (m *CgroupStats) XXX_Unmarshal(b []byte) error {
- return m.Unmarshal(b)
-}
-func (m *CgroupStats) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
- if deterministic {
- return xxx_messageInfo_CgroupStats.Marshal(b, m, deterministic)
- } else {
- b = b[:cap(b)]
- n, err := m.MarshalToSizedBuffer(b)
- if err != nil {
- return nil, err
- }
- return b[:n], nil
- }
-}
-func (m *CgroupStats) XXX_Merge(src proto.Message) {
- xxx_messageInfo_CgroupStats.Merge(m, src)
-}
-func (m *CgroupStats) XXX_Size() int {
- return m.Size()
-}
-func (m *CgroupStats) XXX_DiscardUnknown() {
- xxx_messageInfo_CgroupStats.DiscardUnknown(m)
-}
-
-var xxx_messageInfo_CgroupStats proto.InternalMessageInfo
-
-func init() {
- proto.RegisterType((*Metrics)(nil), "io.containerd.cgroups.v1.Metrics")
- proto.RegisterType((*HugetlbStat)(nil), "io.containerd.cgroups.v1.HugetlbStat")
- proto.RegisterType((*PidsStat)(nil), "io.containerd.cgroups.v1.PidsStat")
- proto.RegisterType((*CPUStat)(nil), "io.containerd.cgroups.v1.CPUStat")
- proto.RegisterType((*CPUUsage)(nil), "io.containerd.cgroups.v1.CPUUsage")
- proto.RegisterType((*Throttle)(nil), "io.containerd.cgroups.v1.Throttle")
- proto.RegisterType((*MemoryStat)(nil), "io.containerd.cgroups.v1.MemoryStat")
- proto.RegisterType((*MemoryEntry)(nil), "io.containerd.cgroups.v1.MemoryEntry")
- proto.RegisterType((*MemoryOomControl)(nil), "io.containerd.cgroups.v1.MemoryOomControl")
- proto.RegisterType((*BlkIOStat)(nil), "io.containerd.cgroups.v1.BlkIOStat")
- proto.RegisterType((*BlkIOEntry)(nil), "io.containerd.cgroups.v1.BlkIOEntry")
- proto.RegisterType((*RdmaStat)(nil), "io.containerd.cgroups.v1.RdmaStat")
- proto.RegisterType((*RdmaEntry)(nil), "io.containerd.cgroups.v1.RdmaEntry")
- proto.RegisterType((*NetworkStat)(nil), "io.containerd.cgroups.v1.NetworkStat")
- proto.RegisterType((*CgroupStats)(nil), "io.containerd.cgroups.v1.CgroupStats")
-}
-
-func init() {
- proto.RegisterFile("github.com/containerd/cgroups/stats/v1/metrics.proto", fileDescriptor_a17b2d87c332bfaa)
-}
-
-var fileDescriptor_a17b2d87c332bfaa = []byte{
- // 1749 bytes of a gzipped FileDescriptorProto
- 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x94, 0x58, 0xcd, 0x72, 0xe3, 0xc6,
- 0x11, 0x36, 0x45, 0x48, 0x24, 0x9a, 0x92, 0x56, 0x9a, 0xfd, 0x83, 0xe4, 0xb5, 0x28, 0x53, 0xbb,
- 0x89, 0xe2, 0xad, 0x48, 0x65, 0x27, 0xb5, 0x95, 0x75, 0xec, 0x4a, 0x59, 0x5a, 0xbb, 0x76, 0xcb,
- 0x51, 0x44, 0x83, 0x52, 0xd9, 0x39, 0xa1, 0x40, 0x70, 0x16, 0x9c, 0x15, 0x80, 0x81, 0x07, 0x03,
- 0x89, 0xca, 0x29, 0x87, 0x54, 0xe5, 0x94, 0x07, 0xca, 0x1b, 0xf8, 0x98, 0x4b, 0x52, 0xc9, 0x45,
- 0x15, 0xf3, 0x49, 0x52, 0x33, 0x3d, 0xf8, 0xa1, 0xbc, 0x5a, 0x85, 0x37, 0x76, 0xcf, 0xd7, 0x5f,
- 0xf7, 0x34, 0xbe, 0x19, 0x34, 0x08, 0xbf, 0x0e, 0x99, 0x1c, 0xe7, 0xc3, 0xbd, 0x80, 0xc7, 0xfb,
- 0x01, 0x4f, 0xa4, 0xcf, 0x12, 0x2a, 0x46, 0xfb, 0x41, 0x28, 0x78, 0x9e, 0x66, 0xfb, 0x99, 0xf4,
- 0x65, 0xb6, 0x7f, 0xfe, 0xf1, 0x7e, 0x4c, 0xa5, 0x60, 0x41, 0xb6, 0x97, 0x0a, 0x2e, 0x39, 0x71,
- 0x18, 0xdf, 0xab, 0xd0, 0x7b, 0x06, 0xbd, 0x77, 0xfe, 0xf1, 0xe6, 0xbd, 0x90, 0x87, 0x5c, 0x83,
- 0xf6, 0xd5, 0x2f, 0xc4, 0xf7, 0xfe, 0x65, 0x41, 0xeb, 0x08, 0x19, 0xc8, 0xef, 0xa0, 0x35, 0xce,
- 0x43, 0x2a, 0xa3, 0xa1, 0xd3, 0xd8, 0x6e, 0xee, 0x76, 0x3e, 0x79, 0xb2, 0x77, 0x13, 0xdb, 0xde,
- 0x4b, 0x04, 0x0e, 0xa4, 0x2f, 0xdd, 0x22, 0x8a, 0x3c, 0x03, 0x2b, 0x65, 0xa3, 0xcc, 0x59, 0xd8,
- 0x6e, 0xec, 0x76, 0x3e, 0xe9, 0xdd, 0x1c, 0xdd, 0x67, 0xa3, 0x4c, 0x87, 0x6a, 0x3c, 0xf9, 0x0c,
- 0x9a, 0x41, 0x9a, 0x3b, 0x4d, 0x1d, 0xf6, 0xe1, 0xcd, 0x61, 0x87, 0xfd, 0x53, 0x15, 0x75, 0xd0,
- 0x9a, 0x5e, 0x75, 0x9b, 0x87, 0xfd, 0x53, 0x57, 0x85, 0x91, 0xcf, 0x60, 0x29, 0xa6, 0x31, 0x17,
- 0x97, 0x8e, 0xa5, 0x09, 0x1e, 0xdf, 0x4c, 0x70, 0xa4, 0x71, 0x3a, 0xb3, 0x89, 0x21, 0xcf, 0x61,
- 0x71, 0x18, 0x9d, 0x31, 0xee, 0x2c, 0xea, 0xe0, 0x9d, 0x9b, 0x83, 0x0f, 0xa2, 0xb3, 0x57, 0xc7,
- 0x3a, 0x16, 0x23, 0xd4, 0x76, 0xc5, 0x28, 0xf6, 0x9d, 0xa5, 0xdb, 0xb6, 0xeb, 0x8e, 0x62, 0x1f,
- 0xb7, 0xab, 0xf0, 0xaa, 0xcf, 0x09, 0x95, 0x17, 0x5c, 0x9c, 0x39, 0xad, 0xdb, 0xfa, 0xfc, 0x07,
- 0x04, 0x62, 0x9f, 0x4d, 0x14, 0x79, 0x09, 0xcb, 0x08, 0xf1, 0xb4, 0x0a, 0x9c, 0xb6, 0x2e, 0xe0,
- 0x1d, 0x2c, 0x87, 0xfa, 0xa7, 0x22, 0xc9, 0xdc, 0x4e, 0x50, 0x19, 0xe4, 0x3b, 0x20, 0xd8, 0x07,
- 0x8f, 0xf3, 0xd8, 0x53, 0xc1, 0x82, 0x47, 0x8e, 0xad, 0xf9, 0x3e, 0xba, 0xad, 0x8f, 0xc7, 0x3c,
- 0x3e, 0xc4, 0x08, 0x77, 0x2d, 0xbe, 0xe6, 0xe9, 0x9d, 0x41, 0xa7, 0xa6, 0x11, 0x72, 0x0f, 0x16,
- 0xf3, 0xcc, 0x0f, 0xa9, 0xd3, 0xd8, 0x6e, 0xec, 0x5a, 0x2e, 0x1a, 0x64, 0x0d, 0x9a, 0xb1, 0x3f,
- 0xd1, 0x7a, 0xb1, 0x5c, 0xf5, 0x93, 0x38, 0xd0, 0x7a, 0xed, 0xb3, 0x28, 0x48, 0xa4, 0x96, 0x83,
- 0xe5, 0x16, 0x26, 0xd9, 0x84, 0x76, 0xea, 0x87, 0x34, 0x63, 0x7f, 0xa2, 0xfa, 0x41, 0xdb, 0x6e,
- 0x69, 0xf7, 0x3e, 0x85, 0x76, 0x21, 0x29, 0xc5, 0x10, 0xe4, 0x42, 0xd0, 0x44, 0x9a, 0x5c, 0x85,
- 0xa9, 0x6a, 0x88, 0x58, 0xcc, 0xa4, 0xc9, 0x87, 0x46, 0xef, 0xaf, 0x0d, 0x68, 0x19, 0x61, 0x91,
- 0xdf, 0xd4, 0xab, 0x7c, 0xe7, 0x23, 0x3d, 0xec, 0x9f, 0x9e, 0x2a, 0x64, 0xb1, 0x93, 0x03, 0x00,
- 0x39, 0x16, 0x5c, 0xca, 0x88, 0x25, 0xe1, 0xed, 0x07, 0xe0, 0x04, 0xb1, 0xd4, 0xad, 0x45, 0xf5,
- 0xbe, 0x87, 0x76, 0x41, 0xab, 0x6a, 0x95, 0x5c, 0xfa, 0x51, 0xd1, 0x2f, 0x6d, 0x90, 0x07, 0xb0,
- 0x74, 0x46, 0x45, 0x42, 0x23, 0xb3, 0x05, 0x63, 0x11, 0x02, 0x56, 0x9e, 0x51, 0x61, 0x5a, 0xa6,
- 0x7f, 0x93, 0x1d, 0x68, 0xa5, 0x54, 0x78, 0xea, 0x60, 0x59, 0xdb, 0xcd, 0x5d, 0xeb, 0x00, 0xa6,
- 0x57, 0xdd, 0xa5, 0x3e, 0x15, 0xea, 0xe0, 0x2c, 0xa5, 0x54, 0x1c, 0xa6, 0x79, 0x6f, 0x02, 0xed,
- 0xa2, 0x14, 0xd5, 0xb8, 0x94, 0x0a, 0xc6, 0x47, 0x59, 0xd1, 0x38, 0x63, 0x92, 0xa7, 0xb0, 0x6e,
- 0xca, 0xa4, 0x23, 0xaf, 0xc0, 0x60, 0x05, 0x6b, 0xe5, 0x42, 0xdf, 0x80, 0x9f, 0xc0, 0x6a, 0x05,
- 0x96, 0x2c, 0xa6, 0xa6, 0xaa, 0x95, 0xd2, 0x7b, 0xc2, 0x62, 0xda, 0xfb, 0x4f, 0x07, 0xa0, 0x3a,
- 0x8e, 0x6a, 0xbf, 0x81, 0x1f, 0x8c, 0x4b, 0x7d, 0x68, 0x83, 0x6c, 0x40, 0x53, 0x64, 0x26, 0x15,
- 0x9e, 0x7a, 0x77, 0x30, 0x70, 0x95, 0x8f, 0xfc, 0x0c, 0xda, 0x22, 0xcb, 0x3c, 0x75, 0xf5, 0x60,
- 0x82, 0x83, 0xce, 0xf4, 0xaa, 0xdb, 0x72, 0x07, 0x03, 0x25, 0x3b, 0xb7, 0x25, 0xb2, 0x4c, 0xfd,
- 0x20, 0x5d, 0xe8, 0xc4, 0x7e, 0x9a, 0xd2, 0x91, 0xf7, 0x9a, 0x45, 0xa8, 0x1c, 0xcb, 0x05, 0x74,
- 0x7d, 0xc5, 0x22, 0xdd, 0xe9, 0x11, 0x13, 0xf2, 0x52, 0x5f, 0x00, 0x96, 0x8b, 0x06, 0x79, 0x04,
- 0xf6, 0x85, 0x60, 0x92, 0x0e, 0xfd, 0xe0, 0x4c, 0x1f, 0x70, 0xcb, 0xad, 0x1c, 0xc4, 0x81, 0x76,
- 0x1a, 0x7a, 0x69, 0xe8, 0xb1, 0xc4, 0x69, 0xe1, 0x93, 0x48, 0xc3, 0x7e, 0xf8, 0x2a, 0x21, 0x9b,
- 0x60, 0xe3, 0x0a, 0xcf, 0xa5, 0x3e, 0x97, 0xaa, 0x8d, 0x61, 0x3f, 0x3c, 0xce, 0x25, 0xd9, 0xd0,
- 0x51, 0xaf, 0xfd, 0x3c, 0x92, 0xfa, 0x88, 0xe9, 0xa5, 0xaf, 0x94, 0x49, 0xb6, 0x61, 0x39, 0x0d,
- 0xbd, 0xd8, 0x7f, 0x63, 0x96, 0x01, 0xcb, 0x4c, 0xc3, 0x23, 0xff, 0x0d, 0x22, 0x76, 0x60, 0x85,
- 0x25, 0x7e, 0x20, 0xd9, 0x39, 0xf5, 0xfc, 0x84, 0x27, 0x4e, 0x47, 0x43, 0x96, 0x0b, 0xe7, 0x17,
- 0x09, 0x4f, 0xd4, 0x66, 0xeb, 0x90, 0x65, 0x64, 0xa9, 0x01, 0xea, 0x2c, 0xba, 0x1f, 0x2b, 0xb3,
- 0x2c, 0xba, 0x23, 0x15, 0x8b, 0x86, 0xac, 0xd6, 0x59, 0x34, 0x60, 0x1b, 0x3a, 0x79, 0x42, 0xcf,
- 0x59, 0x20, 0xfd, 0x61, 0x44, 0x9d, 0x3b, 0x1a, 0x50, 0x77, 0x91, 0x4f, 0x61, 0x63, 0xcc, 0xa8,
- 0xf0, 0x45, 0x30, 0x66, 0x81, 0x1f, 0x79, 0xe6, 0x92, 0xc1, 0xe3, 0xb7, 0xa6, 0xf1, 0x0f, 0xeb,
- 0x00, 0x54, 0xc2, 0xef, 0xd5, 0x32, 0x79, 0x06, 0x33, 0x4b, 0x5e, 0x76, 0xe1, 0xa7, 0x26, 0x72,
- 0x5d, 0x47, 0xde, 0xaf, 0x2f, 0x0f, 0x2e, 0xfc, 0x14, 0xe3, 0xba, 0xd0, 0xd1, 0xa7, 0xc4, 0x43,
- 0x21, 0x11, 0x2c, 0x5b, 0xbb, 0x0e, 0xb5, 0x9a, 0x7e, 0x01, 0x36, 0x02, 0x94, 0xa6, 0xee, 0x6a,
- 0xcd, 0x2c, 0x4f, 0xaf, 0xba, 0xed, 0x13, 0xe5, 0x54, 0xc2, 0x6a, 0xeb, 0x65, 0x37, 0xcb, 0xc8,
- 0x33, 0x58, 0x2d, 0xa1, 0xa8, 0xb1, 0x7b, 0x1a, 0xbf, 0x36, 0xbd, 0xea, 0x2e, 0x17, 0x78, 0x2d,
- 0xb4, 0xe5, 0x22, 0x46, 0xab, 0xed, 0x23, 0x58, 0xc7, 0xb8, 0xba, 0xe6, 0xee, 0xeb, 0x4a, 0xee,
- 0xe8, 0x85, 0xa3, 0x4a, 0x78, 0x65, 0xbd, 0x28, 0xbf, 0x07, 0xb5, 0x7a, 0x5f, 0x68, 0x0d, 0xfe,
- 0x1c, 0x30, 0xc6, 0xab, 0x94, 0xf8, 0x50, 0x83, 0xb0, 0xb6, 0x6f, 0x4b, 0x39, 0xee, 0x14, 0xd5,
- 0x96, 0xa2, 0x74, 0xf0, 0x91, 0x68, 0x6f, 0x1f, 0x95, 0xf9, 0xa4, 0x60, 0xab, 0xf4, 0xb9, 0x81,
- 0x0f, 0xbf, 0x44, 0x29, 0x91, 0x3e, 0xae, 0x71, 0xa1, 0x16, 0x37, 0x67, 0x50, 0xa8, 0xc6, 0xa7,
- 0x40, 0x4a, 0x54, 0xa5, 0xda, 0xf7, 0x6b, 0x1b, 0xed, 0x57, 0xd2, 0xdd, 0x83, 0xbb, 0x08, 0x9e,
- 0x15, 0xf0, 0x23, 0x8d, 0xc6, 0x7e, 0xbd, 0xaa, 0xab, 0xb8, 0x6c, 0x62, 0x1d, 0xfd, 0x41, 0x8d,
- 0xfb, 0x8b, 0x0a, 0xfb, 0x53, 0x6e, 0xdd, 0xf2, 0xad, 0xb7, 0x70, 0xeb, 0xa6, 0x5f, 0xe7, 0xd6,
- 0xe8, 0xee, 0x4f, 0xb8, 0x35, 0xf6, 0x69, 0x81, 0xad, 0x8b, 0x7d, 0xdb, 0x5c, 0x7b, 0x6a, 0xe1,
- 0xb4, 0xa6, 0xf8, 0xdf, 0x16, 0xaf, 0x8e, 0x0f, 0x6f, 0x7b, 0x19, 0xa3, 0xd6, 0xbf, 0x4c, 0xa4,
- 0xb8, 0x2c, 0xde, 0x1e, 0xcf, 0xc1, 0x52, 0x2a, 0x77, 0x7a, 0xf3, 0xc4, 0xea, 0x10, 0xf2, 0x79,
- 0xf9, 0x4a, 0xd8, 0x99, 0x27, 0xb8, 0x78, 0x73, 0x0c, 0x00, 0xf0, 0x97, 0x27, 0x83, 0xd4, 0x79,
- 0x3c, 0x07, 0xc5, 0xc1, 0xca, 0xf4, 0xaa, 0x6b, 0x7f, 0xad, 0x83, 0x4f, 0x0e, 0xfb, 0xae, 0x8d,
- 0x3c, 0x27, 0x41, 0xda, 0xa3, 0xd0, 0xa9, 0x01, 0xab, 0xf7, 0x6e, 0xa3, 0xf6, 0xde, 0xad, 0x26,
- 0x82, 0x85, 0xb7, 0x4c, 0x04, 0xcd, 0xb7, 0x4e, 0x04, 0xd6, 0xcc, 0x44, 0xd0, 0x93, 0xb0, 0x76,
- 0x7d, 0x10, 0x21, 0xbb, 0xb0, 0xa6, 0x26, 0x99, 0x33, 0x16, 0xa9, 0x73, 0x95, 0xe9, 0x47, 0x86,
- 0x69, 0x57, 0x39, 0x8f, 0xbf, 0x66, 0x51, 0xf4, 0x02, 0xbd, 0xe4, 0x7d, 0xb0, 0xf3, 0x64, 0x44,
- 0x85, 0x9a, 0x7c, 0x4c, 0x0d, 0x6d, 0xed, 0x38, 0xe6, 0xb1, 0xba, 0xaa, 0x0b, 0x9a, 0x62, 0x0e,
- 0x31, 0xe1, 0xbd, 0x7f, 0x2e, 0x82, 0x5d, 0x8e, 0x82, 0xc4, 0x87, 0x4d, 0xc6, 0xbd, 0x8c, 0x8a,
- 0x73, 0x16, 0x50, 0x6f, 0x78, 0x29, 0x69, 0xe6, 0x09, 0x1a, 0xe4, 0x22, 0x63, 0xe7, 0xd4, 0x8c,
- 0xd1, 0x8f, 0x6f, 0x99, 0x29, 0xf1, 0x89, 0x3c, 0x64, 0x7c, 0x80, 0x34, 0x07, 0x8a, 0xc5, 0x2d,
- 0x48, 0xc8, 0x77, 0x70, 0xbf, 0x4a, 0x31, 0xaa, 0xb1, 0x2f, 0xcc, 0xc1, 0x7e, 0xb7, 0x64, 0x1f,
- 0x55, 0xcc, 0x27, 0x70, 0x97, 0x71, 0xef, 0xfb, 0x9c, 0xe6, 0x33, 0xbc, 0xcd, 0x39, 0x78, 0xd7,
- 0x19, 0xff, 0x46, 0xc7, 0x57, 0xac, 0x1e, 0x6c, 0xd4, 0x5a, 0xa2, 0x26, 0x80, 0x1a, 0xb7, 0x35,
- 0x07, 0xf7, 0x83, 0xb2, 0x66, 0x35, 0x31, 0x54, 0x09, 0xfe, 0x08, 0x0f, 0x18, 0xf7, 0x2e, 0x7c,
- 0x26, 0xaf, 0xb3, 0x2f, 0xce, 0xd7, 0x91, 0x6f, 0x7d, 0x26, 0x67, 0xa9, 0xb1, 0x23, 0x31, 0x15,
- 0xe1, 0x4c, 0x47, 0x96, 0xe6, 0xeb, 0xc8, 0x91, 0x8e, 0xaf, 0x58, 0xfb, 0xb0, 0xce, 0xf8, 0xf5,
- 0x5a, 0x5b, 0x73, 0x70, 0xde, 0x61, 0x7c, 0xb6, 0xce, 0x6f, 0x60, 0x3d, 0xa3, 0x81, 0xe4, 0xa2,
- 0xae, 0xb6, 0xf6, 0x1c, 0x8c, 0x6b, 0x26, 0xbc, 0xa4, 0xec, 0x9d, 0x03, 0x54, 0xeb, 0x64, 0x15,
- 0x16, 0x78, 0xaa, 0x4f, 0x8e, 0xed, 0x2e, 0xf0, 0x54, 0x4d, 0x9e, 0x23, 0x75, 0xd9, 0xe1, 0x71,
- 0xb5, 0x5d, 0x63, 0xa9, 0x53, 0x1c, 0xfb, 0x6f, 0x78, 0x31, 0x7a, 0xa2, 0xa1, 0xbd, 0x2c, 0xe1,
- 0xc2, 0x9c, 0x58, 0x34, 0x94, 0xf7, 0xdc, 0x8f, 0x72, 0x5a, 0x4c, 0x5a, 0xda, 0xe8, 0xfd, 0xa5,
- 0x01, 0xed, 0xe2, 0x03, 0x89, 0x7c, 0x5e, 0x1f, 0xde, 0x9b, 0xef, 0xfe, 0x1e, 0x53, 0x41, 0xb8,
- 0x99, 0x72, 0xc2, 0x7f, 0x5e, 0x4d, 0xf8, 0xff, 0x77, 0xb0, 0xf9, 0x0c, 0xa0, 0x60, 0x97, 0xbe,
- 0xda, 0x6e, 0x1b, 0x33, 0xbb, 0xed, 0x42, 0x67, 0x1c, 0xf8, 0xde, 0xd8, 0x4f, 0x46, 0x11, 0xc5,
- 0xb9, 0x74, 0xc5, 0x85, 0x71, 0xe0, 0xbf, 0x44, 0x4f, 0x01, 0xe0, 0xc3, 0x37, 0x34, 0x90, 0x99,
- 0x6e, 0x0a, 0x02, 0x8e, 0xd1, 0xd3, 0xfb, 0xdb, 0x02, 0x74, 0x6a, 0xdf, 0x74, 0x6a, 0x72, 0x4f,
- 0xfc, 0xb8, 0xc8, 0xa3, 0x7f, 0xab, 0xcb, 0x47, 0x4c, 0xf0, 0x2e, 0x31, 0x17, 0x53, 0x4b, 0x4c,
- 0xf4, 0xa5, 0x40, 0x3e, 0x00, 0x10, 0x13, 0x2f, 0xf5, 0x83, 0x33, 0x6a, 0xe8, 0x2d, 0xd7, 0x16,
- 0x93, 0x3e, 0x3a, 0xd4, 0x9d, 0x26, 0x26, 0x1e, 0x15, 0x82, 0x8b, 0xcc, 0xf4, 0xbe, 0x2d, 0x26,
- 0x5f, 0x6a, 0xdb, 0xc4, 0x8e, 0x04, 0x57, 0x13, 0x88, 0x79, 0x06, 0xb6, 0x98, 0xbc, 0x40, 0x87,
- 0xca, 0x2a, 0x8b, 0xac, 0x38, 0xf0, 0xb6, 0x64, 0x95, 0x55, 0x56, 0x59, 0x71, 0xe0, 0xb5, 0x65,
- 0x3d, 0xab, 0x2c, 0xb3, 0xe2, 0xcc, 0xdb, 0x96, 0xb5, 0xac, 0xb2, 0xca, 0x6a, 0x17, 0xb1, 0x26,
- 0x6b, 0xef, 0xef, 0x0d, 0xe8, 0xd4, 0xbe, 0x4e, 0x55, 0x03, 0x13, 0xe1, 0x65, 0x11, 0xa5, 0xa9,
- 0xfa, 0x90, 0xc2, 0xab, 0x1b, 0x12, 0x31, 0x30, 0x1e, 0xc5, 0x97, 0x08, 0x4f, 0xe4, 0x49, 0x52,
- 0x7c, 0x68, 0x59, 0xae, 0x9d, 0x08, 0x17, 0x1d, 0x66, 0x39, 0x93, 0x98, 0xae, 0x59, 0x2c, 0x0f,
- 0xd0, 0x41, 0x7e, 0x09, 0x24, 0x11, 0x5e, 0x9e, 0xb0, 0x44, 0x52, 0x21, 0xf2, 0x54, 0xb2, 0x61,
- 0xf9, 0x51, 0xb0, 0x9e, 0x88, 0xd3, 0xd9, 0x05, 0xf2, 0x48, 0xb3, 0x99, 0xcb, 0xc6, 0xb4, 0xac,
- 0x9d, 0x88, 0x57, 0xfa, 0xe6, 0x38, 0x70, 0x7e, 0xf8, 0x71, 0xeb, 0xbd, 0x7f, 0xff, 0xb8, 0xf5,
- 0xde, 0x9f, 0xa7, 0x5b, 0x8d, 0x1f, 0xa6, 0x5b, 0x8d, 0x7f, 0x4c, 0xb7, 0x1a, 0xff, 0x9d, 0x6e,
- 0x35, 0x86, 0x4b, 0xfa, 0xcf, 0x95, 0x5f, 0xfd, 0x2f, 0x00, 0x00, 0xff, 0xff, 0xc4, 0x4e, 0x24,
- 0x22, 0xc4, 0x11, 0x00, 0x00,
-}
-
-func (m *Metrics) Marshal() (dAtA []byte, err error) {
- size := m.Size()
- dAtA = make([]byte, size)
- n, err := m.MarshalToSizedBuffer(dAtA[:size])
- if err != nil {
- return nil, err
- }
- return dAtA[:n], nil
-}
-
-func (m *Metrics) MarshalTo(dAtA []byte) (int, error) {
- size := m.Size()
- return m.MarshalToSizedBuffer(dAtA[:size])
-}
-
-func (m *Metrics) MarshalToSizedBuffer(dAtA []byte) (int, error) {
- i := len(dAtA)
- _ = i
- var l int
- _ = l
- if m.XXX_unrecognized != nil {
- i -= len(m.XXX_unrecognized)
- copy(dAtA[i:], m.XXX_unrecognized)
- }
- if m.MemoryOomControl != nil {
- {
- size, err := m.MemoryOomControl.MarshalToSizedBuffer(dAtA[:i])
- if err != nil {
- return 0, err
- }
- i -= size
- i = encodeVarintMetrics(dAtA, i, uint64(size))
- }
- i--
- dAtA[i] = 0x4a
- }
- if m.CgroupStats != nil {
- {
- size, err := m.CgroupStats.MarshalToSizedBuffer(dAtA[:i])
- if err != nil {
- return 0, err
- }
- i -= size
- i = encodeVarintMetrics(dAtA, i, uint64(size))
- }
- i--
- dAtA[i] = 0x42
- }
- if len(m.Network) > 0 {
- for iNdEx := len(m.Network) - 1; iNdEx >= 0; iNdEx-- {
- {
- size, err := m.Network[iNdEx].MarshalToSizedBuffer(dAtA[:i])
- if err != nil {
- return 0, err
- }
- i -= size
- i = encodeVarintMetrics(dAtA, i, uint64(size))
- }
- i--
- dAtA[i] = 0x3a
- }
- }
- if m.Rdma != nil {
- {
- size, err := m.Rdma.MarshalToSizedBuffer(dAtA[:i])
- if err != nil {
- return 0, err
- }
- i -= size
- i = encodeVarintMetrics(dAtA, i, uint64(size))
- }
- i--
- dAtA[i] = 0x32
- }
- if m.Blkio != nil {
- {
- size, err := m.Blkio.MarshalToSizedBuffer(dAtA[:i])
- if err != nil {
- return 0, err
- }
- i -= size
- i = encodeVarintMetrics(dAtA, i, uint64(size))
- }
- i--
- dAtA[i] = 0x2a
- }
- if m.Memory != nil {
- {
- size, err := m.Memory.MarshalToSizedBuffer(dAtA[:i])
- if err != nil {
- return 0, err
- }
- i -= size
- i = encodeVarintMetrics(dAtA, i, uint64(size))
- }
- i--
- dAtA[i] = 0x22
- }
- if m.CPU != nil {
- {
- size, err := m.CPU.MarshalToSizedBuffer(dAtA[:i])
- if err != nil {
- return 0, err
- }
- i -= size
- i = encodeVarintMetrics(dAtA, i, uint64(size))
- }
- i--
- dAtA[i] = 0x1a
- }
- if m.Pids != nil {
- {
- size, err := m.Pids.MarshalToSizedBuffer(dAtA[:i])
- if err != nil {
- return 0, err
- }
- i -= size
- i = encodeVarintMetrics(dAtA, i, uint64(size))
- }
- i--
- dAtA[i] = 0x12
- }
- if len(m.Hugetlb) > 0 {
- for iNdEx := len(m.Hugetlb) - 1; iNdEx >= 0; iNdEx-- {
- {
- size, err := m.Hugetlb[iNdEx].MarshalToSizedBuffer(dAtA[:i])
- if err != nil {
- return 0, err
- }
- i -= size
- i = encodeVarintMetrics(dAtA, i, uint64(size))
- }
- i--
- dAtA[i] = 0xa
- }
- }
- return len(dAtA) - i, nil
-}
-
-func (m *HugetlbStat) Marshal() (dAtA []byte, err error) {
- size := m.Size()
- dAtA = make([]byte, size)
- n, err := m.MarshalToSizedBuffer(dAtA[:size])
- if err != nil {
- return nil, err
- }
- return dAtA[:n], nil
-}
-
-func (m *HugetlbStat) MarshalTo(dAtA []byte) (int, error) {
- size := m.Size()
- return m.MarshalToSizedBuffer(dAtA[:size])
-}
-
-func (m *HugetlbStat) MarshalToSizedBuffer(dAtA []byte) (int, error) {
- i := len(dAtA)
- _ = i
- var l int
- _ = l
- if m.XXX_unrecognized != nil {
- i -= len(m.XXX_unrecognized)
- copy(dAtA[i:], m.XXX_unrecognized)
- }
- if len(m.Pagesize) > 0 {
- i -= len(m.Pagesize)
- copy(dAtA[i:], m.Pagesize)
- i = encodeVarintMetrics(dAtA, i, uint64(len(m.Pagesize)))
- i--
- dAtA[i] = 0x22
- }
- if m.Failcnt != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.Failcnt))
- i--
- dAtA[i] = 0x18
- }
- if m.Max != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.Max))
- i--
- dAtA[i] = 0x10
- }
- if m.Usage != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.Usage))
- i--
- dAtA[i] = 0x8
- }
- return len(dAtA) - i, nil
-}
-
-func (m *PidsStat) Marshal() (dAtA []byte, err error) {
- size := m.Size()
- dAtA = make([]byte, size)
- n, err := m.MarshalToSizedBuffer(dAtA[:size])
- if err != nil {
- return nil, err
- }
- return dAtA[:n], nil
-}
-
-func (m *PidsStat) MarshalTo(dAtA []byte) (int, error) {
- size := m.Size()
- return m.MarshalToSizedBuffer(dAtA[:size])
-}
-
-func (m *PidsStat) MarshalToSizedBuffer(dAtA []byte) (int, error) {
- i := len(dAtA)
- _ = i
- var l int
- _ = l
- if m.XXX_unrecognized != nil {
- i -= len(m.XXX_unrecognized)
- copy(dAtA[i:], m.XXX_unrecognized)
- }
- if m.Limit != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.Limit))
- i--
- dAtA[i] = 0x10
- }
- if m.Current != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.Current))
- i--
- dAtA[i] = 0x8
- }
- return len(dAtA) - i, nil
-}
-
-func (m *CPUStat) Marshal() (dAtA []byte, err error) {
- size := m.Size()
- dAtA = make([]byte, size)
- n, err := m.MarshalToSizedBuffer(dAtA[:size])
- if err != nil {
- return nil, err
- }
- return dAtA[:n], nil
-}
-
-func (m *CPUStat) MarshalTo(dAtA []byte) (int, error) {
- size := m.Size()
- return m.MarshalToSizedBuffer(dAtA[:size])
-}
-
-func (m *CPUStat) MarshalToSizedBuffer(dAtA []byte) (int, error) {
- i := len(dAtA)
- _ = i
- var l int
- _ = l
- if m.XXX_unrecognized != nil {
- i -= len(m.XXX_unrecognized)
- copy(dAtA[i:], m.XXX_unrecognized)
- }
- if m.Throttling != nil {
- {
- size, err := m.Throttling.MarshalToSizedBuffer(dAtA[:i])
- if err != nil {
- return 0, err
- }
- i -= size
- i = encodeVarintMetrics(dAtA, i, uint64(size))
- }
- i--
- dAtA[i] = 0x12
- }
- if m.Usage != nil {
- {
- size, err := m.Usage.MarshalToSizedBuffer(dAtA[:i])
- if err != nil {
- return 0, err
- }
- i -= size
- i = encodeVarintMetrics(dAtA, i, uint64(size))
- }
- i--
- dAtA[i] = 0xa
- }
- return len(dAtA) - i, nil
-}
-
-func (m *CPUUsage) Marshal() (dAtA []byte, err error) {
- size := m.Size()
- dAtA = make([]byte, size)
- n, err := m.MarshalToSizedBuffer(dAtA[:size])
- if err != nil {
- return nil, err
- }
- return dAtA[:n], nil
-}
-
-func (m *CPUUsage) MarshalTo(dAtA []byte) (int, error) {
- size := m.Size()
- return m.MarshalToSizedBuffer(dAtA[:size])
-}
-
-func (m *CPUUsage) MarshalToSizedBuffer(dAtA []byte) (int, error) {
- i := len(dAtA)
- _ = i
- var l int
- _ = l
- if m.XXX_unrecognized != nil {
- i -= len(m.XXX_unrecognized)
- copy(dAtA[i:], m.XXX_unrecognized)
- }
- if len(m.PerCPU) > 0 {
- dAtA11 := make([]byte, len(m.PerCPU)*10)
- var j10 int
- for _, num := range m.PerCPU {
- for num >= 1<<7 {
- dAtA11[j10] = uint8(uint64(num)&0x7f | 0x80)
- num >>= 7
- j10++
- }
- dAtA11[j10] = uint8(num)
- j10++
- }
- i -= j10
- copy(dAtA[i:], dAtA11[:j10])
- i = encodeVarintMetrics(dAtA, i, uint64(j10))
- i--
- dAtA[i] = 0x22
- }
- if m.User != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.User))
- i--
- dAtA[i] = 0x18
- }
- if m.Kernel != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.Kernel))
- i--
- dAtA[i] = 0x10
- }
- if m.Total != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.Total))
- i--
- dAtA[i] = 0x8
- }
- return len(dAtA) - i, nil
-}
-
-func (m *Throttle) Marshal() (dAtA []byte, err error) {
- size := m.Size()
- dAtA = make([]byte, size)
- n, err := m.MarshalToSizedBuffer(dAtA[:size])
- if err != nil {
- return nil, err
- }
- return dAtA[:n], nil
-}
-
-func (m *Throttle) MarshalTo(dAtA []byte) (int, error) {
- size := m.Size()
- return m.MarshalToSizedBuffer(dAtA[:size])
-}
-
-func (m *Throttle) MarshalToSizedBuffer(dAtA []byte) (int, error) {
- i := len(dAtA)
- _ = i
- var l int
- _ = l
- if m.XXX_unrecognized != nil {
- i -= len(m.XXX_unrecognized)
- copy(dAtA[i:], m.XXX_unrecognized)
- }
- if m.ThrottledTime != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.ThrottledTime))
- i--
- dAtA[i] = 0x18
- }
- if m.ThrottledPeriods != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.ThrottledPeriods))
- i--
- dAtA[i] = 0x10
- }
- if m.Periods != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.Periods))
- i--
- dAtA[i] = 0x8
- }
- return len(dAtA) - i, nil
-}
-
-func (m *MemoryStat) Marshal() (dAtA []byte, err error) {
- size := m.Size()
- dAtA = make([]byte, size)
- n, err := m.MarshalToSizedBuffer(dAtA[:size])
- if err != nil {
- return nil, err
- }
- return dAtA[:n], nil
-}
-
-func (m *MemoryStat) MarshalTo(dAtA []byte) (int, error) {
- size := m.Size()
- return m.MarshalToSizedBuffer(dAtA[:size])
-}
-
-func (m *MemoryStat) MarshalToSizedBuffer(dAtA []byte) (int, error) {
- i := len(dAtA)
- _ = i
- var l int
- _ = l
- if m.XXX_unrecognized != nil {
- i -= len(m.XXX_unrecognized)
- copy(dAtA[i:], m.XXX_unrecognized)
- }
- if m.KernelTCP != nil {
- {
- size, err := m.KernelTCP.MarshalToSizedBuffer(dAtA[:i])
- if err != nil {
- return 0, err
- }
- i -= size
- i = encodeVarintMetrics(dAtA, i, uint64(size))
- }
- i--
- dAtA[i] = 0x2
- i--
- dAtA[i] = 0xa2
- }
- if m.Kernel != nil {
- {
- size, err := m.Kernel.MarshalToSizedBuffer(dAtA[:i])
- if err != nil {
- return 0, err
- }
- i -= size
- i = encodeVarintMetrics(dAtA, i, uint64(size))
- }
- i--
- dAtA[i] = 0x2
- i--
- dAtA[i] = 0x9a
- }
- if m.Swap != nil {
- {
- size, err := m.Swap.MarshalToSizedBuffer(dAtA[:i])
- if err != nil {
- return 0, err
- }
- i -= size
- i = encodeVarintMetrics(dAtA, i, uint64(size))
- }
- i--
- dAtA[i] = 0x2
- i--
- dAtA[i] = 0x92
- }
- if m.Usage != nil {
- {
- size, err := m.Usage.MarshalToSizedBuffer(dAtA[:i])
- if err != nil {
- return 0, err
- }
- i -= size
- i = encodeVarintMetrics(dAtA, i, uint64(size))
- }
- i--
- dAtA[i] = 0x2
- i--
- dAtA[i] = 0x8a
- }
- if m.TotalUnevictable != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.TotalUnevictable))
- i--
- dAtA[i] = 0x2
- i--
- dAtA[i] = 0x80
- }
- if m.TotalActiveFile != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.TotalActiveFile))
- i--
- dAtA[i] = 0x1
- i--
- dAtA[i] = 0xf8
- }
- if m.TotalInactiveFile != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.TotalInactiveFile))
- i--
- dAtA[i] = 0x1
- i--
- dAtA[i] = 0xf0
- }
- if m.TotalActiveAnon != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.TotalActiveAnon))
- i--
- dAtA[i] = 0x1
- i--
- dAtA[i] = 0xe8
- }
- if m.TotalInactiveAnon != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.TotalInactiveAnon))
- i--
- dAtA[i] = 0x1
- i--
- dAtA[i] = 0xe0
- }
- if m.TotalPgMajFault != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.TotalPgMajFault))
- i--
- dAtA[i] = 0x1
- i--
- dAtA[i] = 0xd8
- }
- if m.TotalPgFault != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.TotalPgFault))
- i--
- dAtA[i] = 0x1
- i--
- dAtA[i] = 0xd0
- }
- if m.TotalPgPgOut != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.TotalPgPgOut))
- i--
- dAtA[i] = 0x1
- i--
- dAtA[i] = 0xc8
- }
- if m.TotalPgPgIn != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.TotalPgPgIn))
- i--
- dAtA[i] = 0x1
- i--
- dAtA[i] = 0xc0
- }
- if m.TotalWriteback != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.TotalWriteback))
- i--
- dAtA[i] = 0x1
- i--
- dAtA[i] = 0xb8
- }
- if m.TotalDirty != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.TotalDirty))
- i--
- dAtA[i] = 0x1
- i--
- dAtA[i] = 0xb0
- }
- if m.TotalMappedFile != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.TotalMappedFile))
- i--
- dAtA[i] = 0x1
- i--
- dAtA[i] = 0xa8
- }
- if m.TotalRSSHuge != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.TotalRSSHuge))
- i--
- dAtA[i] = 0x1
- i--
- dAtA[i] = 0xa0
- }
- if m.TotalRSS != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.TotalRSS))
- i--
- dAtA[i] = 0x1
- i--
- dAtA[i] = 0x98
- }
- if m.TotalCache != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.TotalCache))
- i--
- dAtA[i] = 0x1
- i--
- dAtA[i] = 0x90
- }
- if m.HierarchicalSwapLimit != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.HierarchicalSwapLimit))
- i--
- dAtA[i] = 0x1
- i--
- dAtA[i] = 0x88
- }
- if m.HierarchicalMemoryLimit != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.HierarchicalMemoryLimit))
- i--
- dAtA[i] = 0x1
- i--
- dAtA[i] = 0x80
- }
- if m.Unevictable != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.Unevictable))
- i--
- dAtA[i] = 0x78
- }
- if m.ActiveFile != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.ActiveFile))
- i--
- dAtA[i] = 0x70
- }
- if m.InactiveFile != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.InactiveFile))
- i--
- dAtA[i] = 0x68
- }
- if m.ActiveAnon != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.ActiveAnon))
- i--
- dAtA[i] = 0x60
- }
- if m.InactiveAnon != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.InactiveAnon))
- i--
- dAtA[i] = 0x58
- }
- if m.PgMajFault != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.PgMajFault))
- i--
- dAtA[i] = 0x50
- }
- if m.PgFault != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.PgFault))
- i--
- dAtA[i] = 0x48
- }
- if m.PgPgOut != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.PgPgOut))
- i--
- dAtA[i] = 0x40
- }
- if m.PgPgIn != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.PgPgIn))
- i--
- dAtA[i] = 0x38
- }
- if m.Writeback != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.Writeback))
- i--
- dAtA[i] = 0x30
- }
- if m.Dirty != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.Dirty))
- i--
- dAtA[i] = 0x28
- }
- if m.MappedFile != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.MappedFile))
- i--
- dAtA[i] = 0x20
- }
- if m.RSSHuge != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.RSSHuge))
- i--
- dAtA[i] = 0x18
- }
- if m.RSS != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.RSS))
- i--
- dAtA[i] = 0x10
- }
- if m.Cache != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.Cache))
- i--
- dAtA[i] = 0x8
- }
- return len(dAtA) - i, nil
-}
-
-func (m *MemoryEntry) Marshal() (dAtA []byte, err error) {
- size := m.Size()
- dAtA = make([]byte, size)
- n, err := m.MarshalToSizedBuffer(dAtA[:size])
- if err != nil {
- return nil, err
- }
- return dAtA[:n], nil
-}
-
-func (m *MemoryEntry) MarshalTo(dAtA []byte) (int, error) {
- size := m.Size()
- return m.MarshalToSizedBuffer(dAtA[:size])
-}
-
-func (m *MemoryEntry) MarshalToSizedBuffer(dAtA []byte) (int, error) {
- i := len(dAtA)
- _ = i
- var l int
- _ = l
- if m.XXX_unrecognized != nil {
- i -= len(m.XXX_unrecognized)
- copy(dAtA[i:], m.XXX_unrecognized)
- }
- if m.Failcnt != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.Failcnt))
- i--
- dAtA[i] = 0x20
- }
- if m.Max != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.Max))
- i--
- dAtA[i] = 0x18
- }
- if m.Usage != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.Usage))
- i--
- dAtA[i] = 0x10
- }
- if m.Limit != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.Limit))
- i--
- dAtA[i] = 0x8
- }
- return len(dAtA) - i, nil
-}
-
-func (m *MemoryOomControl) Marshal() (dAtA []byte, err error) {
- size := m.Size()
- dAtA = make([]byte, size)
- n, err := m.MarshalToSizedBuffer(dAtA[:size])
- if err != nil {
- return nil, err
- }
- return dAtA[:n], nil
-}
-
-func (m *MemoryOomControl) MarshalTo(dAtA []byte) (int, error) {
- size := m.Size()
- return m.MarshalToSizedBuffer(dAtA[:size])
-}
-
-func (m *MemoryOomControl) MarshalToSizedBuffer(dAtA []byte) (int, error) {
- i := len(dAtA)
- _ = i
- var l int
- _ = l
- if m.XXX_unrecognized != nil {
- i -= len(m.XXX_unrecognized)
- copy(dAtA[i:], m.XXX_unrecognized)
- }
- if m.OomKill != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.OomKill))
- i--
- dAtA[i] = 0x18
- }
- if m.UnderOom != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.UnderOom))
- i--
- dAtA[i] = 0x10
- }
- if m.OomKillDisable != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.OomKillDisable))
- i--
- dAtA[i] = 0x8
- }
- return len(dAtA) - i, nil
-}
-
-func (m *BlkIOStat) Marshal() (dAtA []byte, err error) {
- size := m.Size()
- dAtA = make([]byte, size)
- n, err := m.MarshalToSizedBuffer(dAtA[:size])
- if err != nil {
- return nil, err
- }
- return dAtA[:n], nil
-}
-
-func (m *BlkIOStat) MarshalTo(dAtA []byte) (int, error) {
- size := m.Size()
- return m.MarshalToSizedBuffer(dAtA[:size])
-}
-
-func (m *BlkIOStat) MarshalToSizedBuffer(dAtA []byte) (int, error) {
- i := len(dAtA)
- _ = i
- var l int
- _ = l
- if m.XXX_unrecognized != nil {
- i -= len(m.XXX_unrecognized)
- copy(dAtA[i:], m.XXX_unrecognized)
- }
- if len(m.SectorsRecursive) > 0 {
- for iNdEx := len(m.SectorsRecursive) - 1; iNdEx >= 0; iNdEx-- {
- {
- size, err := m.SectorsRecursive[iNdEx].MarshalToSizedBuffer(dAtA[:i])
- if err != nil {
- return 0, err
- }
- i -= size
- i = encodeVarintMetrics(dAtA, i, uint64(size))
- }
- i--
- dAtA[i] = 0x42
- }
- }
- if len(m.IoTimeRecursive) > 0 {
- for iNdEx := len(m.IoTimeRecursive) - 1; iNdEx >= 0; iNdEx-- {
- {
- size, err := m.IoTimeRecursive[iNdEx].MarshalToSizedBuffer(dAtA[:i])
- if err != nil {
- return 0, err
- }
- i -= size
- i = encodeVarintMetrics(dAtA, i, uint64(size))
- }
- i--
- dAtA[i] = 0x3a
- }
- }
- if len(m.IoMergedRecursive) > 0 {
- for iNdEx := len(m.IoMergedRecursive) - 1; iNdEx >= 0; iNdEx-- {
- {
- size, err := m.IoMergedRecursive[iNdEx].MarshalToSizedBuffer(dAtA[:i])
- if err != nil {
- return 0, err
- }
- i -= size
- i = encodeVarintMetrics(dAtA, i, uint64(size))
- }
- i--
- dAtA[i] = 0x32
- }
- }
- if len(m.IoWaitTimeRecursive) > 0 {
- for iNdEx := len(m.IoWaitTimeRecursive) - 1; iNdEx >= 0; iNdEx-- {
- {
- size, err := m.IoWaitTimeRecursive[iNdEx].MarshalToSizedBuffer(dAtA[:i])
- if err != nil {
- return 0, err
- }
- i -= size
- i = encodeVarintMetrics(dAtA, i, uint64(size))
- }
- i--
- dAtA[i] = 0x2a
- }
- }
- if len(m.IoServiceTimeRecursive) > 0 {
- for iNdEx := len(m.IoServiceTimeRecursive) - 1; iNdEx >= 0; iNdEx-- {
- {
- size, err := m.IoServiceTimeRecursive[iNdEx].MarshalToSizedBuffer(dAtA[:i])
- if err != nil {
- return 0, err
- }
- i -= size
- i = encodeVarintMetrics(dAtA, i, uint64(size))
- }
- i--
- dAtA[i] = 0x22
- }
- }
- if len(m.IoQueuedRecursive) > 0 {
- for iNdEx := len(m.IoQueuedRecursive) - 1; iNdEx >= 0; iNdEx-- {
- {
- size, err := m.IoQueuedRecursive[iNdEx].MarshalToSizedBuffer(dAtA[:i])
- if err != nil {
- return 0, err
- }
- i -= size
- i = encodeVarintMetrics(dAtA, i, uint64(size))
- }
- i--
- dAtA[i] = 0x1a
- }
- }
- if len(m.IoServicedRecursive) > 0 {
- for iNdEx := len(m.IoServicedRecursive) - 1; iNdEx >= 0; iNdEx-- {
- {
- size, err := m.IoServicedRecursive[iNdEx].MarshalToSizedBuffer(dAtA[:i])
- if err != nil {
- return 0, err
- }
- i -= size
- i = encodeVarintMetrics(dAtA, i, uint64(size))
- }
- i--
- dAtA[i] = 0x12
- }
- }
- if len(m.IoServiceBytesRecursive) > 0 {
- for iNdEx := len(m.IoServiceBytesRecursive) - 1; iNdEx >= 0; iNdEx-- {
- {
- size, err := m.IoServiceBytesRecursive[iNdEx].MarshalToSizedBuffer(dAtA[:i])
- if err != nil {
- return 0, err
- }
- i -= size
- i = encodeVarintMetrics(dAtA, i, uint64(size))
- }
- i--
- dAtA[i] = 0xa
- }
- }
- return len(dAtA) - i, nil
-}
-
-func (m *BlkIOEntry) Marshal() (dAtA []byte, err error) {
- size := m.Size()
- dAtA = make([]byte, size)
- n, err := m.MarshalToSizedBuffer(dAtA[:size])
- if err != nil {
- return nil, err
- }
- return dAtA[:n], nil
-}
-
-func (m *BlkIOEntry) MarshalTo(dAtA []byte) (int, error) {
- size := m.Size()
- return m.MarshalToSizedBuffer(dAtA[:size])
-}
-
-func (m *BlkIOEntry) MarshalToSizedBuffer(dAtA []byte) (int, error) {
- i := len(dAtA)
- _ = i
- var l int
- _ = l
- if m.XXX_unrecognized != nil {
- i -= len(m.XXX_unrecognized)
- copy(dAtA[i:], m.XXX_unrecognized)
- }
- if m.Value != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.Value))
- i--
- dAtA[i] = 0x28
- }
- if m.Minor != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.Minor))
- i--
- dAtA[i] = 0x20
- }
- if m.Major != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.Major))
- i--
- dAtA[i] = 0x18
- }
- if len(m.Device) > 0 {
- i -= len(m.Device)
- copy(dAtA[i:], m.Device)
- i = encodeVarintMetrics(dAtA, i, uint64(len(m.Device)))
- i--
- dAtA[i] = 0x12
- }
- if len(m.Op) > 0 {
- i -= len(m.Op)
- copy(dAtA[i:], m.Op)
- i = encodeVarintMetrics(dAtA, i, uint64(len(m.Op)))
- i--
- dAtA[i] = 0xa
- }
- return len(dAtA) - i, nil
-}
-
-func (m *RdmaStat) Marshal() (dAtA []byte, err error) {
- size := m.Size()
- dAtA = make([]byte, size)
- n, err := m.MarshalToSizedBuffer(dAtA[:size])
- if err != nil {
- return nil, err
- }
- return dAtA[:n], nil
-}
-
-func (m *RdmaStat) MarshalTo(dAtA []byte) (int, error) {
- size := m.Size()
- return m.MarshalToSizedBuffer(dAtA[:size])
-}
-
-func (m *RdmaStat) MarshalToSizedBuffer(dAtA []byte) (int, error) {
- i := len(dAtA)
- _ = i
- var l int
- _ = l
- if m.XXX_unrecognized != nil {
- i -= len(m.XXX_unrecognized)
- copy(dAtA[i:], m.XXX_unrecognized)
- }
- if len(m.Limit) > 0 {
- for iNdEx := len(m.Limit) - 1; iNdEx >= 0; iNdEx-- {
- {
- size, err := m.Limit[iNdEx].MarshalToSizedBuffer(dAtA[:i])
- if err != nil {
- return 0, err
- }
- i -= size
- i = encodeVarintMetrics(dAtA, i, uint64(size))
- }
- i--
- dAtA[i] = 0x12
- }
- }
- if len(m.Current) > 0 {
- for iNdEx := len(m.Current) - 1; iNdEx >= 0; iNdEx-- {
- {
- size, err := m.Current[iNdEx].MarshalToSizedBuffer(dAtA[:i])
- if err != nil {
- return 0, err
- }
- i -= size
- i = encodeVarintMetrics(dAtA, i, uint64(size))
- }
- i--
- dAtA[i] = 0xa
- }
- }
- return len(dAtA) - i, nil
-}
-
-func (m *RdmaEntry) Marshal() (dAtA []byte, err error) {
- size := m.Size()
- dAtA = make([]byte, size)
- n, err := m.MarshalToSizedBuffer(dAtA[:size])
- if err != nil {
- return nil, err
- }
- return dAtA[:n], nil
-}
-
-func (m *RdmaEntry) MarshalTo(dAtA []byte) (int, error) {
- size := m.Size()
- return m.MarshalToSizedBuffer(dAtA[:size])
-}
-
-func (m *RdmaEntry) MarshalToSizedBuffer(dAtA []byte) (int, error) {
- i := len(dAtA)
- _ = i
- var l int
- _ = l
- if m.XXX_unrecognized != nil {
- i -= len(m.XXX_unrecognized)
- copy(dAtA[i:], m.XXX_unrecognized)
- }
- if m.HcaObjects != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.HcaObjects))
- i--
- dAtA[i] = 0x18
- }
- if m.HcaHandles != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.HcaHandles))
- i--
- dAtA[i] = 0x10
- }
- if len(m.Device) > 0 {
- i -= len(m.Device)
- copy(dAtA[i:], m.Device)
- i = encodeVarintMetrics(dAtA, i, uint64(len(m.Device)))
- i--
- dAtA[i] = 0xa
- }
- return len(dAtA) - i, nil
-}
-
-func (m *NetworkStat) Marshal() (dAtA []byte, err error) {
- size := m.Size()
- dAtA = make([]byte, size)
- n, err := m.MarshalToSizedBuffer(dAtA[:size])
- if err != nil {
- return nil, err
- }
- return dAtA[:n], nil
-}
-
-func (m *NetworkStat) MarshalTo(dAtA []byte) (int, error) {
- size := m.Size()
- return m.MarshalToSizedBuffer(dAtA[:size])
-}
-
-func (m *NetworkStat) MarshalToSizedBuffer(dAtA []byte) (int, error) {
- i := len(dAtA)
- _ = i
- var l int
- _ = l
- if m.XXX_unrecognized != nil {
- i -= len(m.XXX_unrecognized)
- copy(dAtA[i:], m.XXX_unrecognized)
- }
- if m.TxDropped != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.TxDropped))
- i--
- dAtA[i] = 0x48
- }
- if m.TxErrors != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.TxErrors))
- i--
- dAtA[i] = 0x40
- }
- if m.TxPackets != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.TxPackets))
- i--
- dAtA[i] = 0x38
- }
- if m.TxBytes != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.TxBytes))
- i--
- dAtA[i] = 0x30
- }
- if m.RxDropped != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.RxDropped))
- i--
- dAtA[i] = 0x28
- }
- if m.RxErrors != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.RxErrors))
- i--
- dAtA[i] = 0x20
- }
- if m.RxPackets != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.RxPackets))
- i--
- dAtA[i] = 0x18
- }
- if m.RxBytes != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.RxBytes))
- i--
- dAtA[i] = 0x10
- }
- if len(m.Name) > 0 {
- i -= len(m.Name)
- copy(dAtA[i:], m.Name)
- i = encodeVarintMetrics(dAtA, i, uint64(len(m.Name)))
- i--
- dAtA[i] = 0xa
- }
- return len(dAtA) - i, nil
-}
-
-func (m *CgroupStats) Marshal() (dAtA []byte, err error) {
- size := m.Size()
- dAtA = make([]byte, size)
- n, err := m.MarshalToSizedBuffer(dAtA[:size])
- if err != nil {
- return nil, err
- }
- return dAtA[:n], nil
-}
-
-func (m *CgroupStats) MarshalTo(dAtA []byte) (int, error) {
- size := m.Size()
- return m.MarshalToSizedBuffer(dAtA[:size])
-}
-
-func (m *CgroupStats) MarshalToSizedBuffer(dAtA []byte) (int, error) {
- i := len(dAtA)
- _ = i
- var l int
- _ = l
- if m.XXX_unrecognized != nil {
- i -= len(m.XXX_unrecognized)
- copy(dAtA[i:], m.XXX_unrecognized)
- }
- if m.NrIoWait != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.NrIoWait))
- i--
- dAtA[i] = 0x28
- }
- if m.NrUninterruptible != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.NrUninterruptible))
- i--
- dAtA[i] = 0x20
- }
- if m.NrStopped != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.NrStopped))
- i--
- dAtA[i] = 0x18
- }
- if m.NrRunning != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.NrRunning))
- i--
- dAtA[i] = 0x10
- }
- if m.NrSleeping != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.NrSleeping))
- i--
- dAtA[i] = 0x8
- }
- return len(dAtA) - i, nil
-}
-
-func encodeVarintMetrics(dAtA []byte, offset int, v uint64) int {
- offset -= sovMetrics(v)
- base := offset
- for v >= 1<<7 {
- dAtA[offset] = uint8(v&0x7f | 0x80)
- v >>= 7
- offset++
- }
- dAtA[offset] = uint8(v)
- return base
-}
-func (m *Metrics) Size() (n int) {
- if m == nil {
- return 0
- }
- var l int
- _ = l
- if len(m.Hugetlb) > 0 {
- for _, e := range m.Hugetlb {
- l = e.Size()
- n += 1 + l + sovMetrics(uint64(l))
- }
- }
- if m.Pids != nil {
- l = m.Pids.Size()
- n += 1 + l + sovMetrics(uint64(l))
- }
- if m.CPU != nil {
- l = m.CPU.Size()
- n += 1 + l + sovMetrics(uint64(l))
- }
- if m.Memory != nil {
- l = m.Memory.Size()
- n += 1 + l + sovMetrics(uint64(l))
- }
- if m.Blkio != nil {
- l = m.Blkio.Size()
- n += 1 + l + sovMetrics(uint64(l))
- }
- if m.Rdma != nil {
- l = m.Rdma.Size()
- n += 1 + l + sovMetrics(uint64(l))
- }
- if len(m.Network) > 0 {
- for _, e := range m.Network {
- l = e.Size()
- n += 1 + l + sovMetrics(uint64(l))
- }
- }
- if m.CgroupStats != nil {
- l = m.CgroupStats.Size()
- n += 1 + l + sovMetrics(uint64(l))
- }
- if m.MemoryOomControl != nil {
- l = m.MemoryOomControl.Size()
- n += 1 + l + sovMetrics(uint64(l))
- }
- if m.XXX_unrecognized != nil {
- n += len(m.XXX_unrecognized)
- }
- return n
-}
-
-func (m *HugetlbStat) Size() (n int) {
- if m == nil {
- return 0
- }
- var l int
- _ = l
- if m.Usage != 0 {
- n += 1 + sovMetrics(uint64(m.Usage))
- }
- if m.Max != 0 {
- n += 1 + sovMetrics(uint64(m.Max))
- }
- if m.Failcnt != 0 {
- n += 1 + sovMetrics(uint64(m.Failcnt))
- }
- l = len(m.Pagesize)
- if l > 0 {
- n += 1 + l + sovMetrics(uint64(l))
- }
- if m.XXX_unrecognized != nil {
- n += len(m.XXX_unrecognized)
- }
- return n
-}
-
-func (m *PidsStat) Size() (n int) {
- if m == nil {
- return 0
- }
- var l int
- _ = l
- if m.Current != 0 {
- n += 1 + sovMetrics(uint64(m.Current))
- }
- if m.Limit != 0 {
- n += 1 + sovMetrics(uint64(m.Limit))
- }
- if m.XXX_unrecognized != nil {
- n += len(m.XXX_unrecognized)
- }
- return n
-}
-
-func (m *CPUStat) Size() (n int) {
- if m == nil {
- return 0
- }
- var l int
- _ = l
- if m.Usage != nil {
- l = m.Usage.Size()
- n += 1 + l + sovMetrics(uint64(l))
- }
- if m.Throttling != nil {
- l = m.Throttling.Size()
- n += 1 + l + sovMetrics(uint64(l))
- }
- if m.XXX_unrecognized != nil {
- n += len(m.XXX_unrecognized)
- }
- return n
-}
-
-func (m *CPUUsage) Size() (n int) {
- if m == nil {
- return 0
- }
- var l int
- _ = l
- if m.Total != 0 {
- n += 1 + sovMetrics(uint64(m.Total))
- }
- if m.Kernel != 0 {
- n += 1 + sovMetrics(uint64(m.Kernel))
- }
- if m.User != 0 {
- n += 1 + sovMetrics(uint64(m.User))
- }
- if len(m.PerCPU) > 0 {
- l = 0
- for _, e := range m.PerCPU {
- l += sovMetrics(uint64(e))
- }
- n += 1 + sovMetrics(uint64(l)) + l
- }
- if m.XXX_unrecognized != nil {
- n += len(m.XXX_unrecognized)
- }
- return n
-}
-
-func (m *Throttle) Size() (n int) {
- if m == nil {
- return 0
- }
- var l int
- _ = l
- if m.Periods != 0 {
- n += 1 + sovMetrics(uint64(m.Periods))
- }
- if m.ThrottledPeriods != 0 {
- n += 1 + sovMetrics(uint64(m.ThrottledPeriods))
- }
- if m.ThrottledTime != 0 {
- n += 1 + sovMetrics(uint64(m.ThrottledTime))
- }
- if m.XXX_unrecognized != nil {
- n += len(m.XXX_unrecognized)
- }
- return n
-}
-
-func (m *MemoryStat) Size() (n int) {
- if m == nil {
- return 0
- }
- var l int
- _ = l
- if m.Cache != 0 {
- n += 1 + sovMetrics(uint64(m.Cache))
- }
- if m.RSS != 0 {
- n += 1 + sovMetrics(uint64(m.RSS))
- }
- if m.RSSHuge != 0 {
- n += 1 + sovMetrics(uint64(m.RSSHuge))
- }
- if m.MappedFile != 0 {
- n += 1 + sovMetrics(uint64(m.MappedFile))
- }
- if m.Dirty != 0 {
- n += 1 + sovMetrics(uint64(m.Dirty))
- }
- if m.Writeback != 0 {
- n += 1 + sovMetrics(uint64(m.Writeback))
- }
- if m.PgPgIn != 0 {
- n += 1 + sovMetrics(uint64(m.PgPgIn))
- }
- if m.PgPgOut != 0 {
- n += 1 + sovMetrics(uint64(m.PgPgOut))
- }
- if m.PgFault != 0 {
- n += 1 + sovMetrics(uint64(m.PgFault))
- }
- if m.PgMajFault != 0 {
- n += 1 + sovMetrics(uint64(m.PgMajFault))
- }
- if m.InactiveAnon != 0 {
- n += 1 + sovMetrics(uint64(m.InactiveAnon))
- }
- if m.ActiveAnon != 0 {
- n += 1 + sovMetrics(uint64(m.ActiveAnon))
- }
- if m.InactiveFile != 0 {
- n += 1 + sovMetrics(uint64(m.InactiveFile))
- }
- if m.ActiveFile != 0 {
- n += 1 + sovMetrics(uint64(m.ActiveFile))
- }
- if m.Unevictable != 0 {
- n += 1 + sovMetrics(uint64(m.Unevictable))
- }
- if m.HierarchicalMemoryLimit != 0 {
- n += 2 + sovMetrics(uint64(m.HierarchicalMemoryLimit))
- }
- if m.HierarchicalSwapLimit != 0 {
- n += 2 + sovMetrics(uint64(m.HierarchicalSwapLimit))
- }
- if m.TotalCache != 0 {
- n += 2 + sovMetrics(uint64(m.TotalCache))
- }
- if m.TotalRSS != 0 {
- n += 2 + sovMetrics(uint64(m.TotalRSS))
- }
- if m.TotalRSSHuge != 0 {
- n += 2 + sovMetrics(uint64(m.TotalRSSHuge))
- }
- if m.TotalMappedFile != 0 {
- n += 2 + sovMetrics(uint64(m.TotalMappedFile))
- }
- if m.TotalDirty != 0 {
- n += 2 + sovMetrics(uint64(m.TotalDirty))
- }
- if m.TotalWriteback != 0 {
- n += 2 + sovMetrics(uint64(m.TotalWriteback))
- }
- if m.TotalPgPgIn != 0 {
- n += 2 + sovMetrics(uint64(m.TotalPgPgIn))
- }
- if m.TotalPgPgOut != 0 {
- n += 2 + sovMetrics(uint64(m.TotalPgPgOut))
- }
- if m.TotalPgFault != 0 {
- n += 2 + sovMetrics(uint64(m.TotalPgFault))
- }
- if m.TotalPgMajFault != 0 {
- n += 2 + sovMetrics(uint64(m.TotalPgMajFault))
- }
- if m.TotalInactiveAnon != 0 {
- n += 2 + sovMetrics(uint64(m.TotalInactiveAnon))
- }
- if m.TotalActiveAnon != 0 {
- n += 2 + sovMetrics(uint64(m.TotalActiveAnon))
- }
- if m.TotalInactiveFile != 0 {
- n += 2 + sovMetrics(uint64(m.TotalInactiveFile))
- }
- if m.TotalActiveFile != 0 {
- n += 2 + sovMetrics(uint64(m.TotalActiveFile))
- }
- if m.TotalUnevictable != 0 {
- n += 2 + sovMetrics(uint64(m.TotalUnevictable))
- }
- if m.Usage != nil {
- l = m.Usage.Size()
- n += 2 + l + sovMetrics(uint64(l))
- }
- if m.Swap != nil {
- l = m.Swap.Size()
- n += 2 + l + sovMetrics(uint64(l))
- }
- if m.Kernel != nil {
- l = m.Kernel.Size()
- n += 2 + l + sovMetrics(uint64(l))
- }
- if m.KernelTCP != nil {
- l = m.KernelTCP.Size()
- n += 2 + l + sovMetrics(uint64(l))
- }
- if m.XXX_unrecognized != nil {
- n += len(m.XXX_unrecognized)
- }
- return n
-}
-
-func (m *MemoryEntry) Size() (n int) {
- if m == nil {
- return 0
- }
- var l int
- _ = l
- if m.Limit != 0 {
- n += 1 + sovMetrics(uint64(m.Limit))
- }
- if m.Usage != 0 {
- n += 1 + sovMetrics(uint64(m.Usage))
- }
- if m.Max != 0 {
- n += 1 + sovMetrics(uint64(m.Max))
- }
- if m.Failcnt != 0 {
- n += 1 + sovMetrics(uint64(m.Failcnt))
- }
- if m.XXX_unrecognized != nil {
- n += len(m.XXX_unrecognized)
- }
- return n
-}
-
-func (m *MemoryOomControl) Size() (n int) {
- if m == nil {
- return 0
- }
- var l int
- _ = l
- if m.OomKillDisable != 0 {
- n += 1 + sovMetrics(uint64(m.OomKillDisable))
- }
- if m.UnderOom != 0 {
- n += 1 + sovMetrics(uint64(m.UnderOom))
- }
- if m.OomKill != 0 {
- n += 1 + sovMetrics(uint64(m.OomKill))
- }
- if m.XXX_unrecognized != nil {
- n += len(m.XXX_unrecognized)
- }
- return n
-}
-
-func (m *BlkIOStat) Size() (n int) {
- if m == nil {
- return 0
- }
- var l int
- _ = l
- if len(m.IoServiceBytesRecursive) > 0 {
- for _, e := range m.IoServiceBytesRecursive {
- l = e.Size()
- n += 1 + l + sovMetrics(uint64(l))
- }
- }
- if len(m.IoServicedRecursive) > 0 {
- for _, e := range m.IoServicedRecursive {
- l = e.Size()
- n += 1 + l + sovMetrics(uint64(l))
- }
- }
- if len(m.IoQueuedRecursive) > 0 {
- for _, e := range m.IoQueuedRecursive {
- l = e.Size()
- n += 1 + l + sovMetrics(uint64(l))
- }
- }
- if len(m.IoServiceTimeRecursive) > 0 {
- for _, e := range m.IoServiceTimeRecursive {
- l = e.Size()
- n += 1 + l + sovMetrics(uint64(l))
- }
- }
- if len(m.IoWaitTimeRecursive) > 0 {
- for _, e := range m.IoWaitTimeRecursive {
- l = e.Size()
- n += 1 + l + sovMetrics(uint64(l))
- }
- }
- if len(m.IoMergedRecursive) > 0 {
- for _, e := range m.IoMergedRecursive {
- l = e.Size()
- n += 1 + l + sovMetrics(uint64(l))
- }
- }
- if len(m.IoTimeRecursive) > 0 {
- for _, e := range m.IoTimeRecursive {
- l = e.Size()
- n += 1 + l + sovMetrics(uint64(l))
- }
- }
- if len(m.SectorsRecursive) > 0 {
- for _, e := range m.SectorsRecursive {
- l = e.Size()
- n += 1 + l + sovMetrics(uint64(l))
- }
- }
- if m.XXX_unrecognized != nil {
- n += len(m.XXX_unrecognized)
- }
- return n
-}
-
-func (m *BlkIOEntry) Size() (n int) {
- if m == nil {
- return 0
- }
- var l int
- _ = l
- l = len(m.Op)
- if l > 0 {
- n += 1 + l + sovMetrics(uint64(l))
- }
- l = len(m.Device)
- if l > 0 {
- n += 1 + l + sovMetrics(uint64(l))
- }
- if m.Major != 0 {
- n += 1 + sovMetrics(uint64(m.Major))
- }
- if m.Minor != 0 {
- n += 1 + sovMetrics(uint64(m.Minor))
- }
- if m.Value != 0 {
- n += 1 + sovMetrics(uint64(m.Value))
- }
- if m.XXX_unrecognized != nil {
- n += len(m.XXX_unrecognized)
- }
- return n
-}
-
-func (m *RdmaStat) Size() (n int) {
- if m == nil {
- return 0
- }
- var l int
- _ = l
- if len(m.Current) > 0 {
- for _, e := range m.Current {
- l = e.Size()
- n += 1 + l + sovMetrics(uint64(l))
- }
- }
- if len(m.Limit) > 0 {
- for _, e := range m.Limit {
- l = e.Size()
- n += 1 + l + sovMetrics(uint64(l))
- }
- }
- if m.XXX_unrecognized != nil {
- n += len(m.XXX_unrecognized)
- }
- return n
-}
-
-func (m *RdmaEntry) Size() (n int) {
- if m == nil {
- return 0
- }
- var l int
- _ = l
- l = len(m.Device)
- if l > 0 {
- n += 1 + l + sovMetrics(uint64(l))
- }
- if m.HcaHandles != 0 {
- n += 1 + sovMetrics(uint64(m.HcaHandles))
- }
- if m.HcaObjects != 0 {
- n += 1 + sovMetrics(uint64(m.HcaObjects))
- }
- if m.XXX_unrecognized != nil {
- n += len(m.XXX_unrecognized)
- }
- return n
-}
-
-func (m *NetworkStat) Size() (n int) {
- if m == nil {
- return 0
- }
- var l int
- _ = l
- l = len(m.Name)
- if l > 0 {
- n += 1 + l + sovMetrics(uint64(l))
- }
- if m.RxBytes != 0 {
- n += 1 + sovMetrics(uint64(m.RxBytes))
- }
- if m.RxPackets != 0 {
- n += 1 + sovMetrics(uint64(m.RxPackets))
- }
- if m.RxErrors != 0 {
- n += 1 + sovMetrics(uint64(m.RxErrors))
- }
- if m.RxDropped != 0 {
- n += 1 + sovMetrics(uint64(m.RxDropped))
- }
- if m.TxBytes != 0 {
- n += 1 + sovMetrics(uint64(m.TxBytes))
- }
- if m.TxPackets != 0 {
- n += 1 + sovMetrics(uint64(m.TxPackets))
- }
- if m.TxErrors != 0 {
- n += 1 + sovMetrics(uint64(m.TxErrors))
- }
- if m.TxDropped != 0 {
- n += 1 + sovMetrics(uint64(m.TxDropped))
- }
- if m.XXX_unrecognized != nil {
- n += len(m.XXX_unrecognized)
- }
- return n
-}
-
-func (m *CgroupStats) Size() (n int) {
- if m == nil {
- return 0
- }
- var l int
- _ = l
- if m.NrSleeping != 0 {
- n += 1 + sovMetrics(uint64(m.NrSleeping))
- }
- if m.NrRunning != 0 {
- n += 1 + sovMetrics(uint64(m.NrRunning))
- }
- if m.NrStopped != 0 {
- n += 1 + sovMetrics(uint64(m.NrStopped))
- }
- if m.NrUninterruptible != 0 {
- n += 1 + sovMetrics(uint64(m.NrUninterruptible))
- }
- if m.NrIoWait != 0 {
- n += 1 + sovMetrics(uint64(m.NrIoWait))
- }
- if m.XXX_unrecognized != nil {
- n += len(m.XXX_unrecognized)
- }
- return n
-}
-
-func sovMetrics(x uint64) (n int) {
- return (math_bits.Len64(x|1) + 6) / 7
-}
-func sozMetrics(x uint64) (n int) {
- return sovMetrics(uint64((x << 1) ^ uint64((int64(x) >> 63))))
-}
-func (this *Metrics) String() string {
- if this == nil {
- return "nil"
- }
- repeatedStringForHugetlb := "[]*HugetlbStat{"
- for _, f := range this.Hugetlb {
- repeatedStringForHugetlb += strings.Replace(f.String(), "HugetlbStat", "HugetlbStat", 1) + ","
- }
- repeatedStringForHugetlb += "}"
- repeatedStringForNetwork := "[]*NetworkStat{"
- for _, f := range this.Network {
- repeatedStringForNetwork += strings.Replace(f.String(), "NetworkStat", "NetworkStat", 1) + ","
- }
- repeatedStringForNetwork += "}"
- s := strings.Join([]string{`&Metrics{`,
- `Hugetlb:` + repeatedStringForHugetlb + `,`,
- `Pids:` + strings.Replace(this.Pids.String(), "PidsStat", "PidsStat", 1) + `,`,
- `CPU:` + strings.Replace(this.CPU.String(), "CPUStat", "CPUStat", 1) + `,`,
- `Memory:` + strings.Replace(this.Memory.String(), "MemoryStat", "MemoryStat", 1) + `,`,
- `Blkio:` + strings.Replace(this.Blkio.String(), "BlkIOStat", "BlkIOStat", 1) + `,`,
- `Rdma:` + strings.Replace(this.Rdma.String(), "RdmaStat", "RdmaStat", 1) + `,`,
- `Network:` + repeatedStringForNetwork + `,`,
- `CgroupStats:` + strings.Replace(this.CgroupStats.String(), "CgroupStats", "CgroupStats", 1) + `,`,
- `MemoryOomControl:` + strings.Replace(this.MemoryOomControl.String(), "MemoryOomControl", "MemoryOomControl", 1) + `,`,
- `XXX_unrecognized:` + fmt.Sprintf("%v", this.XXX_unrecognized) + `,`,
- `}`,
- }, "")
- return s
-}
-func (this *HugetlbStat) String() string {
- if this == nil {
- return "nil"
- }
- s := strings.Join([]string{`&HugetlbStat{`,
- `Usage:` + fmt.Sprintf("%v", this.Usage) + `,`,
- `Max:` + fmt.Sprintf("%v", this.Max) + `,`,
- `Failcnt:` + fmt.Sprintf("%v", this.Failcnt) + `,`,
- `Pagesize:` + fmt.Sprintf("%v", this.Pagesize) + `,`,
- `XXX_unrecognized:` + fmt.Sprintf("%v", this.XXX_unrecognized) + `,`,
- `}`,
- }, "")
- return s
-}
-func (this *PidsStat) String() string {
- if this == nil {
- return "nil"
- }
- s := strings.Join([]string{`&PidsStat{`,
- `Current:` + fmt.Sprintf("%v", this.Current) + `,`,
- `Limit:` + fmt.Sprintf("%v", this.Limit) + `,`,
- `XXX_unrecognized:` + fmt.Sprintf("%v", this.XXX_unrecognized) + `,`,
- `}`,
- }, "")
- return s
-}
-func (this *CPUStat) String() string {
- if this == nil {
- return "nil"
- }
- s := strings.Join([]string{`&CPUStat{`,
- `Usage:` + strings.Replace(this.Usage.String(), "CPUUsage", "CPUUsage", 1) + `,`,
- `Throttling:` + strings.Replace(this.Throttling.String(), "Throttle", "Throttle", 1) + `,`,
- `XXX_unrecognized:` + fmt.Sprintf("%v", this.XXX_unrecognized) + `,`,
- `}`,
- }, "")
- return s
-}
-func (this *CPUUsage) String() string {
- if this == nil {
- return "nil"
- }
- s := strings.Join([]string{`&CPUUsage{`,
- `Total:` + fmt.Sprintf("%v", this.Total) + `,`,
- `Kernel:` + fmt.Sprintf("%v", this.Kernel) + `,`,
- `User:` + fmt.Sprintf("%v", this.User) + `,`,
- `PerCPU:` + fmt.Sprintf("%v", this.PerCPU) + `,`,
- `XXX_unrecognized:` + fmt.Sprintf("%v", this.XXX_unrecognized) + `,`,
- `}`,
- }, "")
- return s
-}
-func (this *Throttle) String() string {
- if this == nil {
- return "nil"
- }
- s := strings.Join([]string{`&Throttle{`,
- `Periods:` + fmt.Sprintf("%v", this.Periods) + `,`,
- `ThrottledPeriods:` + fmt.Sprintf("%v", this.ThrottledPeriods) + `,`,
- `ThrottledTime:` + fmt.Sprintf("%v", this.ThrottledTime) + `,`,
- `XXX_unrecognized:` + fmt.Sprintf("%v", this.XXX_unrecognized) + `,`,
- `}`,
- }, "")
- return s
-}
-func (this *MemoryStat) String() string {
- if this == nil {
- return "nil"
- }
- s := strings.Join([]string{`&MemoryStat{`,
- `Cache:` + fmt.Sprintf("%v", this.Cache) + `,`,
- `RSS:` + fmt.Sprintf("%v", this.RSS) + `,`,
- `RSSHuge:` + fmt.Sprintf("%v", this.RSSHuge) + `,`,
- `MappedFile:` + fmt.Sprintf("%v", this.MappedFile) + `,`,
- `Dirty:` + fmt.Sprintf("%v", this.Dirty) + `,`,
- `Writeback:` + fmt.Sprintf("%v", this.Writeback) + `,`,
- `PgPgIn:` + fmt.Sprintf("%v", this.PgPgIn) + `,`,
- `PgPgOut:` + fmt.Sprintf("%v", this.PgPgOut) + `,`,
- `PgFault:` + fmt.Sprintf("%v", this.PgFault) + `,`,
- `PgMajFault:` + fmt.Sprintf("%v", this.PgMajFault) + `,`,
- `InactiveAnon:` + fmt.Sprintf("%v", this.InactiveAnon) + `,`,
- `ActiveAnon:` + fmt.Sprintf("%v", this.ActiveAnon) + `,`,
- `InactiveFile:` + fmt.Sprintf("%v", this.InactiveFile) + `,`,
- `ActiveFile:` + fmt.Sprintf("%v", this.ActiveFile) + `,`,
- `Unevictable:` + fmt.Sprintf("%v", this.Unevictable) + `,`,
- `HierarchicalMemoryLimit:` + fmt.Sprintf("%v", this.HierarchicalMemoryLimit) + `,`,
- `HierarchicalSwapLimit:` + fmt.Sprintf("%v", this.HierarchicalSwapLimit) + `,`,
- `TotalCache:` + fmt.Sprintf("%v", this.TotalCache) + `,`,
- `TotalRSS:` + fmt.Sprintf("%v", this.TotalRSS) + `,`,
- `TotalRSSHuge:` + fmt.Sprintf("%v", this.TotalRSSHuge) + `,`,
- `TotalMappedFile:` + fmt.Sprintf("%v", this.TotalMappedFile) + `,`,
- `TotalDirty:` + fmt.Sprintf("%v", this.TotalDirty) + `,`,
- `TotalWriteback:` + fmt.Sprintf("%v", this.TotalWriteback) + `,`,
- `TotalPgPgIn:` + fmt.Sprintf("%v", this.TotalPgPgIn) + `,`,
- `TotalPgPgOut:` + fmt.Sprintf("%v", this.TotalPgPgOut) + `,`,
- `TotalPgFault:` + fmt.Sprintf("%v", this.TotalPgFault) + `,`,
- `TotalPgMajFault:` + fmt.Sprintf("%v", this.TotalPgMajFault) + `,`,
- `TotalInactiveAnon:` + fmt.Sprintf("%v", this.TotalInactiveAnon) + `,`,
- `TotalActiveAnon:` + fmt.Sprintf("%v", this.TotalActiveAnon) + `,`,
- `TotalInactiveFile:` + fmt.Sprintf("%v", this.TotalInactiveFile) + `,`,
- `TotalActiveFile:` + fmt.Sprintf("%v", this.TotalActiveFile) + `,`,
- `TotalUnevictable:` + fmt.Sprintf("%v", this.TotalUnevictable) + `,`,
- `Usage:` + strings.Replace(this.Usage.String(), "MemoryEntry", "MemoryEntry", 1) + `,`,
- `Swap:` + strings.Replace(this.Swap.String(), "MemoryEntry", "MemoryEntry", 1) + `,`,
- `Kernel:` + strings.Replace(this.Kernel.String(), "MemoryEntry", "MemoryEntry", 1) + `,`,
- `KernelTCP:` + strings.Replace(this.KernelTCP.String(), "MemoryEntry", "MemoryEntry", 1) + `,`,
- `XXX_unrecognized:` + fmt.Sprintf("%v", this.XXX_unrecognized) + `,`,
- `}`,
- }, "")
- return s
-}
-func (this *MemoryEntry) String() string {
- if this == nil {
- return "nil"
- }
- s := strings.Join([]string{`&MemoryEntry{`,
- `Limit:` + fmt.Sprintf("%v", this.Limit) + `,`,
- `Usage:` + fmt.Sprintf("%v", this.Usage) + `,`,
- `Max:` + fmt.Sprintf("%v", this.Max) + `,`,
- `Failcnt:` + fmt.Sprintf("%v", this.Failcnt) + `,`,
- `XXX_unrecognized:` + fmt.Sprintf("%v", this.XXX_unrecognized) + `,`,
- `}`,
- }, "")
- return s
-}
-func (this *MemoryOomControl) String() string {
- if this == nil {
- return "nil"
- }
- s := strings.Join([]string{`&MemoryOomControl{`,
- `OomKillDisable:` + fmt.Sprintf("%v", this.OomKillDisable) + `,`,
- `UnderOom:` + fmt.Sprintf("%v", this.UnderOom) + `,`,
- `OomKill:` + fmt.Sprintf("%v", this.OomKill) + `,`,
- `XXX_unrecognized:` + fmt.Sprintf("%v", this.XXX_unrecognized) + `,`,
- `}`,
- }, "")
- return s
-}
-func (this *BlkIOStat) String() string {
- if this == nil {
- return "nil"
- }
- repeatedStringForIoServiceBytesRecursive := "[]*BlkIOEntry{"
- for _, f := range this.IoServiceBytesRecursive {
- repeatedStringForIoServiceBytesRecursive += strings.Replace(f.String(), "BlkIOEntry", "BlkIOEntry", 1) + ","
- }
- repeatedStringForIoServiceBytesRecursive += "}"
- repeatedStringForIoServicedRecursive := "[]*BlkIOEntry{"
- for _, f := range this.IoServicedRecursive {
- repeatedStringForIoServicedRecursive += strings.Replace(f.String(), "BlkIOEntry", "BlkIOEntry", 1) + ","
- }
- repeatedStringForIoServicedRecursive += "}"
- repeatedStringForIoQueuedRecursive := "[]*BlkIOEntry{"
- for _, f := range this.IoQueuedRecursive {
- repeatedStringForIoQueuedRecursive += strings.Replace(f.String(), "BlkIOEntry", "BlkIOEntry", 1) + ","
- }
- repeatedStringForIoQueuedRecursive += "}"
- repeatedStringForIoServiceTimeRecursive := "[]*BlkIOEntry{"
- for _, f := range this.IoServiceTimeRecursive {
- repeatedStringForIoServiceTimeRecursive += strings.Replace(f.String(), "BlkIOEntry", "BlkIOEntry", 1) + ","
- }
- repeatedStringForIoServiceTimeRecursive += "}"
- repeatedStringForIoWaitTimeRecursive := "[]*BlkIOEntry{"
- for _, f := range this.IoWaitTimeRecursive {
- repeatedStringForIoWaitTimeRecursive += strings.Replace(f.String(), "BlkIOEntry", "BlkIOEntry", 1) + ","
- }
- repeatedStringForIoWaitTimeRecursive += "}"
- repeatedStringForIoMergedRecursive := "[]*BlkIOEntry{"
- for _, f := range this.IoMergedRecursive {
- repeatedStringForIoMergedRecursive += strings.Replace(f.String(), "BlkIOEntry", "BlkIOEntry", 1) + ","
- }
- repeatedStringForIoMergedRecursive += "}"
- repeatedStringForIoTimeRecursive := "[]*BlkIOEntry{"
- for _, f := range this.IoTimeRecursive {
- repeatedStringForIoTimeRecursive += strings.Replace(f.String(), "BlkIOEntry", "BlkIOEntry", 1) + ","
- }
- repeatedStringForIoTimeRecursive += "}"
- repeatedStringForSectorsRecursive := "[]*BlkIOEntry{"
- for _, f := range this.SectorsRecursive {
- repeatedStringForSectorsRecursive += strings.Replace(f.String(), "BlkIOEntry", "BlkIOEntry", 1) + ","
- }
- repeatedStringForSectorsRecursive += "}"
- s := strings.Join([]string{`&BlkIOStat{`,
- `IoServiceBytesRecursive:` + repeatedStringForIoServiceBytesRecursive + `,`,
- `IoServicedRecursive:` + repeatedStringForIoServicedRecursive + `,`,
- `IoQueuedRecursive:` + repeatedStringForIoQueuedRecursive + `,`,
- `IoServiceTimeRecursive:` + repeatedStringForIoServiceTimeRecursive + `,`,
- `IoWaitTimeRecursive:` + repeatedStringForIoWaitTimeRecursive + `,`,
- `IoMergedRecursive:` + repeatedStringForIoMergedRecursive + `,`,
- `IoTimeRecursive:` + repeatedStringForIoTimeRecursive + `,`,
- `SectorsRecursive:` + repeatedStringForSectorsRecursive + `,`,
- `XXX_unrecognized:` + fmt.Sprintf("%v", this.XXX_unrecognized) + `,`,
- `}`,
- }, "")
- return s
-}
-func (this *BlkIOEntry) String() string {
- if this == nil {
- return "nil"
- }
- s := strings.Join([]string{`&BlkIOEntry{`,
- `Op:` + fmt.Sprintf("%v", this.Op) + `,`,
- `Device:` + fmt.Sprintf("%v", this.Device) + `,`,
- `Major:` + fmt.Sprintf("%v", this.Major) + `,`,
- `Minor:` + fmt.Sprintf("%v", this.Minor) + `,`,
- `Value:` + fmt.Sprintf("%v", this.Value) + `,`,
- `XXX_unrecognized:` + fmt.Sprintf("%v", this.XXX_unrecognized) + `,`,
- `}`,
- }, "")
- return s
-}
-func (this *RdmaStat) String() string {
- if this == nil {
- return "nil"
- }
- repeatedStringForCurrent := "[]*RdmaEntry{"
- for _, f := range this.Current {
- repeatedStringForCurrent += strings.Replace(f.String(), "RdmaEntry", "RdmaEntry", 1) + ","
- }
- repeatedStringForCurrent += "}"
- repeatedStringForLimit := "[]*RdmaEntry{"
- for _, f := range this.Limit {
- repeatedStringForLimit += strings.Replace(f.String(), "RdmaEntry", "RdmaEntry", 1) + ","
- }
- repeatedStringForLimit += "}"
- s := strings.Join([]string{`&RdmaStat{`,
- `Current:` + repeatedStringForCurrent + `,`,
- `Limit:` + repeatedStringForLimit + `,`,
- `XXX_unrecognized:` + fmt.Sprintf("%v", this.XXX_unrecognized) + `,`,
- `}`,
- }, "")
- return s
-}
-func (this *RdmaEntry) String() string {
- if this == nil {
- return "nil"
- }
- s := strings.Join([]string{`&RdmaEntry{`,
- `Device:` + fmt.Sprintf("%v", this.Device) + `,`,
- `HcaHandles:` + fmt.Sprintf("%v", this.HcaHandles) + `,`,
- `HcaObjects:` + fmt.Sprintf("%v", this.HcaObjects) + `,`,
- `XXX_unrecognized:` + fmt.Sprintf("%v", this.XXX_unrecognized) + `,`,
- `}`,
- }, "")
- return s
-}
-func (this *NetworkStat) String() string {
- if this == nil {
- return "nil"
- }
- s := strings.Join([]string{`&NetworkStat{`,
- `Name:` + fmt.Sprintf("%v", this.Name) + `,`,
- `RxBytes:` + fmt.Sprintf("%v", this.RxBytes) + `,`,
- `RxPackets:` + fmt.Sprintf("%v", this.RxPackets) + `,`,
- `RxErrors:` + fmt.Sprintf("%v", this.RxErrors) + `,`,
- `RxDropped:` + fmt.Sprintf("%v", this.RxDropped) + `,`,
- `TxBytes:` + fmt.Sprintf("%v", this.TxBytes) + `,`,
- `TxPackets:` + fmt.Sprintf("%v", this.TxPackets) + `,`,
- `TxErrors:` + fmt.Sprintf("%v", this.TxErrors) + `,`,
- `TxDropped:` + fmt.Sprintf("%v", this.TxDropped) + `,`,
- `XXX_unrecognized:` + fmt.Sprintf("%v", this.XXX_unrecognized) + `,`,
- `}`,
- }, "")
- return s
-}
-func (this *CgroupStats) String() string {
- if this == nil {
- return "nil"
- }
- s := strings.Join([]string{`&CgroupStats{`,
- `NrSleeping:` + fmt.Sprintf("%v", this.NrSleeping) + `,`,
- `NrRunning:` + fmt.Sprintf("%v", this.NrRunning) + `,`,
- `NrStopped:` + fmt.Sprintf("%v", this.NrStopped) + `,`,
- `NrUninterruptible:` + fmt.Sprintf("%v", this.NrUninterruptible) + `,`,
- `NrIoWait:` + fmt.Sprintf("%v", this.NrIoWait) + `,`,
- `XXX_unrecognized:` + fmt.Sprintf("%v", this.XXX_unrecognized) + `,`,
- `}`,
- }, "")
- return s
-}
-func valueToStringMetrics(v interface{}) string {
- rv := reflect.ValueOf(v)
- if rv.IsNil() {
- return "nil"
- }
- pv := reflect.Indirect(rv).Interface()
- return fmt.Sprintf("*%v", pv)
-}
-func (m *Metrics) Unmarshal(dAtA []byte) error {
- l := len(dAtA)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- wire |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: Metrics: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: Metrics: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Hugetlb", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- msglen |= int(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthMetrics
- }
- postIndex := iNdEx + msglen
- if postIndex < 0 {
- return ErrInvalidLengthMetrics
- }
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Hugetlb = append(m.Hugetlb, &HugetlbStat{})
- if err := m.Hugetlb[len(m.Hugetlb)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Pids", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- msglen |= int(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthMetrics
- }
- postIndex := iNdEx + msglen
- if postIndex < 0 {
- return ErrInvalidLengthMetrics
- }
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.Pids == nil {
- m.Pids = &PidsStat{}
- }
- if err := m.Pids.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 3:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field CPU", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- msglen |= int(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthMetrics
- }
- postIndex := iNdEx + msglen
- if postIndex < 0 {
- return ErrInvalidLengthMetrics
- }
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.CPU == nil {
- m.CPU = &CPUStat{}
- }
- if err := m.CPU.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 4:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Memory", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- msglen |= int(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthMetrics
- }
- postIndex := iNdEx + msglen
- if postIndex < 0 {
- return ErrInvalidLengthMetrics
- }
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.Memory == nil {
- m.Memory = &MemoryStat{}
- }
- if err := m.Memory.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 5:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Blkio", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- msglen |= int(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthMetrics
- }
- postIndex := iNdEx + msglen
- if postIndex < 0 {
- return ErrInvalidLengthMetrics
- }
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.Blkio == nil {
- m.Blkio = &BlkIOStat{}
- }
- if err := m.Blkio.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 6:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Rdma", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- msglen |= int(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthMetrics
- }
- postIndex := iNdEx + msglen
- if postIndex < 0 {
- return ErrInvalidLengthMetrics
- }
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.Rdma == nil {
- m.Rdma = &RdmaStat{}
- }
- if err := m.Rdma.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 7:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Network", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- msglen |= int(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthMetrics
- }
- postIndex := iNdEx + msglen
- if postIndex < 0 {
- return ErrInvalidLengthMetrics
- }
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Network = append(m.Network, &NetworkStat{})
- if err := m.Network[len(m.Network)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 8:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field CgroupStats", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- msglen |= int(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthMetrics
- }
- postIndex := iNdEx + msglen
- if postIndex < 0 {
- return ErrInvalidLengthMetrics
- }
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.CgroupStats == nil {
- m.CgroupStats = &CgroupStats{}
- }
- if err := m.CgroupStats.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 9:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field MemoryOomControl", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- msglen |= int(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthMetrics
- }
- postIndex := iNdEx + msglen
- if postIndex < 0 {
- return ErrInvalidLengthMetrics
- }
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.MemoryOomControl == nil {
- m.MemoryOomControl = &MemoryOomControl{}
- }
- if err := m.MemoryOomControl.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipMetrics(dAtA[iNdEx:])
- if err != nil {
- return err
- }
- if (skippy < 0) || (iNdEx+skippy) < 0 {
- return ErrInvalidLengthMetrics
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...)
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *HugetlbStat) Unmarshal(dAtA []byte) error {
- l := len(dAtA)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- wire |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: HugetlbStat: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: HugetlbStat: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Usage", wireType)
- }
- m.Usage = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.Usage |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 2:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Max", wireType)
- }
- m.Max = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.Max |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 3:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Failcnt", wireType)
- }
- m.Failcnt = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.Failcnt |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 4:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Pagesize", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- stringLen |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthMetrics
- }
- postIndex := iNdEx + intStringLen
- if postIndex < 0 {
- return ErrInvalidLengthMetrics
- }
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Pagesize = string(dAtA[iNdEx:postIndex])
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipMetrics(dAtA[iNdEx:])
- if err != nil {
- return err
- }
- if (skippy < 0) || (iNdEx+skippy) < 0 {
- return ErrInvalidLengthMetrics
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...)
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *PidsStat) Unmarshal(dAtA []byte) error {
- l := len(dAtA)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- wire |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: PidsStat: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: PidsStat: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Current", wireType)
- }
- m.Current = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.Current |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 2:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Limit", wireType)
- }
- m.Limit = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.Limit |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- default:
- iNdEx = preIndex
- skippy, err := skipMetrics(dAtA[iNdEx:])
- if err != nil {
- return err
- }
- if (skippy < 0) || (iNdEx+skippy) < 0 {
- return ErrInvalidLengthMetrics
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...)
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *CPUStat) Unmarshal(dAtA []byte) error {
- l := len(dAtA)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- wire |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: CPUStat: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: CPUStat: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Usage", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- msglen |= int(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthMetrics
- }
- postIndex := iNdEx + msglen
- if postIndex < 0 {
- return ErrInvalidLengthMetrics
- }
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.Usage == nil {
- m.Usage = &CPUUsage{}
- }
- if err := m.Usage.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Throttling", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- msglen |= int(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthMetrics
- }
- postIndex := iNdEx + msglen
- if postIndex < 0 {
- return ErrInvalidLengthMetrics
- }
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.Throttling == nil {
- m.Throttling = &Throttle{}
- }
- if err := m.Throttling.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipMetrics(dAtA[iNdEx:])
- if err != nil {
- return err
- }
- if (skippy < 0) || (iNdEx+skippy) < 0 {
- return ErrInvalidLengthMetrics
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...)
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *CPUUsage) Unmarshal(dAtA []byte) error {
- l := len(dAtA)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- wire |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: CPUUsage: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: CPUUsage: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Total", wireType)
- }
- m.Total = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.Total |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 2:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Kernel", wireType)
- }
- m.Kernel = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.Kernel |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 3:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field User", wireType)
- }
- m.User = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.User |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 4:
- if wireType == 0 {
- var v uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- v |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- m.PerCPU = append(m.PerCPU, v)
- } else if wireType == 2 {
- var packedLen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- packedLen |= int(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if packedLen < 0 {
- return ErrInvalidLengthMetrics
- }
- postIndex := iNdEx + packedLen
- if postIndex < 0 {
- return ErrInvalidLengthMetrics
- }
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- var elementCount int
- var count int
- for _, integer := range dAtA[iNdEx:postIndex] {
- if integer < 128 {
- count++
- }
- }
- elementCount = count
- if elementCount != 0 && len(m.PerCPU) == 0 {
- m.PerCPU = make([]uint64, 0, elementCount)
- }
- for iNdEx < postIndex {
- var v uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- v |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- m.PerCPU = append(m.PerCPU, v)
- }
- } else {
- return fmt.Errorf("proto: wrong wireType = %d for field PerCPU", wireType)
- }
- default:
- iNdEx = preIndex
- skippy, err := skipMetrics(dAtA[iNdEx:])
- if err != nil {
- return err
- }
- if (skippy < 0) || (iNdEx+skippy) < 0 {
- return ErrInvalidLengthMetrics
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...)
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *Throttle) Unmarshal(dAtA []byte) error {
- l := len(dAtA)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- wire |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: Throttle: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: Throttle: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Periods", wireType)
- }
- m.Periods = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.Periods |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 2:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field ThrottledPeriods", wireType)
- }
- m.ThrottledPeriods = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.ThrottledPeriods |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 3:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field ThrottledTime", wireType)
- }
- m.ThrottledTime = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.ThrottledTime |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- default:
- iNdEx = preIndex
- skippy, err := skipMetrics(dAtA[iNdEx:])
- if err != nil {
- return err
- }
- if (skippy < 0) || (iNdEx+skippy) < 0 {
- return ErrInvalidLengthMetrics
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...)
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *MemoryStat) Unmarshal(dAtA []byte) error {
- l := len(dAtA)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- wire |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: MemoryStat: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: MemoryStat: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Cache", wireType)
- }
- m.Cache = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.Cache |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 2:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field RSS", wireType)
- }
- m.RSS = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.RSS |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 3:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field RSSHuge", wireType)
- }
- m.RSSHuge = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.RSSHuge |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 4:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field MappedFile", wireType)
- }
- m.MappedFile = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.MappedFile |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 5:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Dirty", wireType)
- }
- m.Dirty = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.Dirty |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 6:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Writeback", wireType)
- }
- m.Writeback = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.Writeback |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 7:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field PgPgIn", wireType)
- }
- m.PgPgIn = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.PgPgIn |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 8:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field PgPgOut", wireType)
- }
- m.PgPgOut = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.PgPgOut |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 9:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field PgFault", wireType)
- }
- m.PgFault = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.PgFault |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 10:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field PgMajFault", wireType)
- }
- m.PgMajFault = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.PgMajFault |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 11:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field InactiveAnon", wireType)
- }
- m.InactiveAnon = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.InactiveAnon |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 12:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field ActiveAnon", wireType)
- }
- m.ActiveAnon = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.ActiveAnon |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 13:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field InactiveFile", wireType)
- }
- m.InactiveFile = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.InactiveFile |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 14:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field ActiveFile", wireType)
- }
- m.ActiveFile = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.ActiveFile |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 15:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Unevictable", wireType)
- }
- m.Unevictable = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.Unevictable |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 16:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field HierarchicalMemoryLimit", wireType)
- }
- m.HierarchicalMemoryLimit = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.HierarchicalMemoryLimit |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 17:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field HierarchicalSwapLimit", wireType)
- }
- m.HierarchicalSwapLimit = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.HierarchicalSwapLimit |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 18:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field TotalCache", wireType)
- }
- m.TotalCache = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.TotalCache |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 19:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field TotalRSS", wireType)
- }
- m.TotalRSS = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.TotalRSS |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 20:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field TotalRSSHuge", wireType)
- }
- m.TotalRSSHuge = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.TotalRSSHuge |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 21:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field TotalMappedFile", wireType)
- }
- m.TotalMappedFile = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.TotalMappedFile |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 22:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field TotalDirty", wireType)
- }
- m.TotalDirty = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.TotalDirty |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 23:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field TotalWriteback", wireType)
- }
- m.TotalWriteback = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.TotalWriteback |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 24:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field TotalPgPgIn", wireType)
- }
- m.TotalPgPgIn = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.TotalPgPgIn |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 25:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field TotalPgPgOut", wireType)
- }
- m.TotalPgPgOut = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.TotalPgPgOut |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 26:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field TotalPgFault", wireType)
- }
- m.TotalPgFault = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.TotalPgFault |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 27:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field TotalPgMajFault", wireType)
- }
- m.TotalPgMajFault = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.TotalPgMajFault |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 28:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field TotalInactiveAnon", wireType)
- }
- m.TotalInactiveAnon = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.TotalInactiveAnon |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 29:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field TotalActiveAnon", wireType)
- }
- m.TotalActiveAnon = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.TotalActiveAnon |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 30:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field TotalInactiveFile", wireType)
- }
- m.TotalInactiveFile = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.TotalInactiveFile |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 31:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field TotalActiveFile", wireType)
- }
- m.TotalActiveFile = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.TotalActiveFile |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 32:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field TotalUnevictable", wireType)
- }
- m.TotalUnevictable = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.TotalUnevictable |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 33:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Usage", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- msglen |= int(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthMetrics
- }
- postIndex := iNdEx + msglen
- if postIndex < 0 {
- return ErrInvalidLengthMetrics
- }
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.Usage == nil {
- m.Usage = &MemoryEntry{}
- }
- if err := m.Usage.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 34:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Swap", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- msglen |= int(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthMetrics
- }
- postIndex := iNdEx + msglen
- if postIndex < 0 {
- return ErrInvalidLengthMetrics
- }
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.Swap == nil {
- m.Swap = &MemoryEntry{}
- }
- if err := m.Swap.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 35:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Kernel", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- msglen |= int(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthMetrics
- }
- postIndex := iNdEx + msglen
- if postIndex < 0 {
- return ErrInvalidLengthMetrics
- }
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.Kernel == nil {
- m.Kernel = &MemoryEntry{}
- }
- if err := m.Kernel.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 36:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field KernelTCP", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- msglen |= int(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthMetrics
- }
- postIndex := iNdEx + msglen
- if postIndex < 0 {
- return ErrInvalidLengthMetrics
- }
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.KernelTCP == nil {
- m.KernelTCP = &MemoryEntry{}
- }
- if err := m.KernelTCP.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipMetrics(dAtA[iNdEx:])
- if err != nil {
- return err
- }
- if (skippy < 0) || (iNdEx+skippy) < 0 {
- return ErrInvalidLengthMetrics
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...)
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *MemoryEntry) Unmarshal(dAtA []byte) error {
- l := len(dAtA)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- wire |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: MemoryEntry: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: MemoryEntry: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Limit", wireType)
- }
- m.Limit = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.Limit |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 2:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Usage", wireType)
- }
- m.Usage = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.Usage |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 3:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Max", wireType)
- }
- m.Max = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.Max |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 4:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Failcnt", wireType)
- }
- m.Failcnt = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.Failcnt |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- default:
- iNdEx = preIndex
- skippy, err := skipMetrics(dAtA[iNdEx:])
- if err != nil {
- return err
- }
- if (skippy < 0) || (iNdEx+skippy) < 0 {
- return ErrInvalidLengthMetrics
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...)
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *MemoryOomControl) Unmarshal(dAtA []byte) error {
- l := len(dAtA)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- wire |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: MemoryOomControl: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: MemoryOomControl: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field OomKillDisable", wireType)
- }
- m.OomKillDisable = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.OomKillDisable |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 2:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field UnderOom", wireType)
- }
- m.UnderOom = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.UnderOom |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 3:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field OomKill", wireType)
- }
- m.OomKill = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.OomKill |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- default:
- iNdEx = preIndex
- skippy, err := skipMetrics(dAtA[iNdEx:])
- if err != nil {
- return err
- }
- if (skippy < 0) || (iNdEx+skippy) < 0 {
- return ErrInvalidLengthMetrics
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...)
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *BlkIOStat) Unmarshal(dAtA []byte) error {
- l := len(dAtA)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- wire |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: BlkIOStat: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: BlkIOStat: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field IoServiceBytesRecursive", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- msglen |= int(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthMetrics
- }
- postIndex := iNdEx + msglen
- if postIndex < 0 {
- return ErrInvalidLengthMetrics
- }
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.IoServiceBytesRecursive = append(m.IoServiceBytesRecursive, &BlkIOEntry{})
- if err := m.IoServiceBytesRecursive[len(m.IoServiceBytesRecursive)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field IoServicedRecursive", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- msglen |= int(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthMetrics
- }
- postIndex := iNdEx + msglen
- if postIndex < 0 {
- return ErrInvalidLengthMetrics
- }
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.IoServicedRecursive = append(m.IoServicedRecursive, &BlkIOEntry{})
- if err := m.IoServicedRecursive[len(m.IoServicedRecursive)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 3:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field IoQueuedRecursive", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- msglen |= int(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthMetrics
- }
- postIndex := iNdEx + msglen
- if postIndex < 0 {
- return ErrInvalidLengthMetrics
- }
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.IoQueuedRecursive = append(m.IoQueuedRecursive, &BlkIOEntry{})
- if err := m.IoQueuedRecursive[len(m.IoQueuedRecursive)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 4:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field IoServiceTimeRecursive", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- msglen |= int(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthMetrics
- }
- postIndex := iNdEx + msglen
- if postIndex < 0 {
- return ErrInvalidLengthMetrics
- }
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.IoServiceTimeRecursive = append(m.IoServiceTimeRecursive, &BlkIOEntry{})
- if err := m.IoServiceTimeRecursive[len(m.IoServiceTimeRecursive)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 5:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field IoWaitTimeRecursive", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- msglen |= int(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthMetrics
- }
- postIndex := iNdEx + msglen
- if postIndex < 0 {
- return ErrInvalidLengthMetrics
- }
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.IoWaitTimeRecursive = append(m.IoWaitTimeRecursive, &BlkIOEntry{})
- if err := m.IoWaitTimeRecursive[len(m.IoWaitTimeRecursive)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 6:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field IoMergedRecursive", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- msglen |= int(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthMetrics
- }
- postIndex := iNdEx + msglen
- if postIndex < 0 {
- return ErrInvalidLengthMetrics
- }
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.IoMergedRecursive = append(m.IoMergedRecursive, &BlkIOEntry{})
- if err := m.IoMergedRecursive[len(m.IoMergedRecursive)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 7:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field IoTimeRecursive", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- msglen |= int(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthMetrics
- }
- postIndex := iNdEx + msglen
- if postIndex < 0 {
- return ErrInvalidLengthMetrics
- }
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.IoTimeRecursive = append(m.IoTimeRecursive, &BlkIOEntry{})
- if err := m.IoTimeRecursive[len(m.IoTimeRecursive)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 8:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field SectorsRecursive", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- msglen |= int(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthMetrics
- }
- postIndex := iNdEx + msglen
- if postIndex < 0 {
- return ErrInvalidLengthMetrics
- }
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.SectorsRecursive = append(m.SectorsRecursive, &BlkIOEntry{})
- if err := m.SectorsRecursive[len(m.SectorsRecursive)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipMetrics(dAtA[iNdEx:])
- if err != nil {
- return err
- }
- if (skippy < 0) || (iNdEx+skippy) < 0 {
- return ErrInvalidLengthMetrics
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...)
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *BlkIOEntry) Unmarshal(dAtA []byte) error {
- l := len(dAtA)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- wire |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: BlkIOEntry: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: BlkIOEntry: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Op", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- stringLen |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthMetrics
- }
- postIndex := iNdEx + intStringLen
- if postIndex < 0 {
- return ErrInvalidLengthMetrics
- }
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Op = string(dAtA[iNdEx:postIndex])
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Device", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- stringLen |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthMetrics
- }
- postIndex := iNdEx + intStringLen
- if postIndex < 0 {
- return ErrInvalidLengthMetrics
- }
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Device = string(dAtA[iNdEx:postIndex])
- iNdEx = postIndex
- case 3:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Major", wireType)
- }
- m.Major = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.Major |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 4:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Minor", wireType)
- }
- m.Minor = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.Minor |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 5:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Value", wireType)
- }
- m.Value = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.Value |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- default:
- iNdEx = preIndex
- skippy, err := skipMetrics(dAtA[iNdEx:])
- if err != nil {
- return err
- }
- if (skippy < 0) || (iNdEx+skippy) < 0 {
- return ErrInvalidLengthMetrics
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...)
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *RdmaStat) Unmarshal(dAtA []byte) error {
- l := len(dAtA)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- wire |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: RdmaStat: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: RdmaStat: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Current", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- msglen |= int(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthMetrics
- }
- postIndex := iNdEx + msglen
- if postIndex < 0 {
- return ErrInvalidLengthMetrics
- }
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Current = append(m.Current, &RdmaEntry{})
- if err := m.Current[len(m.Current)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Limit", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- msglen |= int(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthMetrics
- }
- postIndex := iNdEx + msglen
- if postIndex < 0 {
- return ErrInvalidLengthMetrics
- }
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Limit = append(m.Limit, &RdmaEntry{})
- if err := m.Limit[len(m.Limit)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipMetrics(dAtA[iNdEx:])
- if err != nil {
- return err
- }
- if (skippy < 0) || (iNdEx+skippy) < 0 {
- return ErrInvalidLengthMetrics
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...)
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *RdmaEntry) Unmarshal(dAtA []byte) error {
- l := len(dAtA)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- wire |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: RdmaEntry: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: RdmaEntry: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Device", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- stringLen |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthMetrics
- }
- postIndex := iNdEx + intStringLen
- if postIndex < 0 {
- return ErrInvalidLengthMetrics
- }
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Device = string(dAtA[iNdEx:postIndex])
- iNdEx = postIndex
- case 2:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field HcaHandles", wireType)
- }
- m.HcaHandles = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.HcaHandles |= uint32(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 3:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field HcaObjects", wireType)
- }
- m.HcaObjects = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.HcaObjects |= uint32(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- default:
- iNdEx = preIndex
- skippy, err := skipMetrics(dAtA[iNdEx:])
- if err != nil {
- return err
- }
- if (skippy < 0) || (iNdEx+skippy) < 0 {
- return ErrInvalidLengthMetrics
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...)
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *NetworkStat) Unmarshal(dAtA []byte) error {
- l := len(dAtA)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- wire |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: NetworkStat: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: NetworkStat: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- stringLen |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthMetrics
- }
- postIndex := iNdEx + intStringLen
- if postIndex < 0 {
- return ErrInvalidLengthMetrics
- }
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Name = string(dAtA[iNdEx:postIndex])
- iNdEx = postIndex
- case 2:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field RxBytes", wireType)
- }
- m.RxBytes = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.RxBytes |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 3:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field RxPackets", wireType)
- }
- m.RxPackets = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.RxPackets |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 4:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field RxErrors", wireType)
- }
- m.RxErrors = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.RxErrors |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 5:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field RxDropped", wireType)
- }
- m.RxDropped = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.RxDropped |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 6:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field TxBytes", wireType)
- }
- m.TxBytes = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.TxBytes |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 7:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field TxPackets", wireType)
- }
- m.TxPackets = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.TxPackets |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 8:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field TxErrors", wireType)
- }
- m.TxErrors = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.TxErrors |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 9:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field TxDropped", wireType)
- }
- m.TxDropped = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.TxDropped |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- default:
- iNdEx = preIndex
- skippy, err := skipMetrics(dAtA[iNdEx:])
- if err != nil {
- return err
- }
- if (skippy < 0) || (iNdEx+skippy) < 0 {
- return ErrInvalidLengthMetrics
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...)
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *CgroupStats) Unmarshal(dAtA []byte) error {
- l := len(dAtA)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- wire |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: CgroupStats: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: CgroupStats: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field NrSleeping", wireType)
- }
- m.NrSleeping = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.NrSleeping |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 2:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field NrRunning", wireType)
- }
- m.NrRunning = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.NrRunning |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 3:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field NrStopped", wireType)
- }
- m.NrStopped = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.NrStopped |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 4:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field NrUninterruptible", wireType)
- }
- m.NrUninterruptible = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.NrUninterruptible |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 5:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field NrIoWait", wireType)
- }
- m.NrIoWait = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.NrIoWait |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- default:
- iNdEx = preIndex
- skippy, err := skipMetrics(dAtA[iNdEx:])
- if err != nil {
- return err
- }
- if (skippy < 0) || (iNdEx+skippy) < 0 {
- return ErrInvalidLengthMetrics
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...)
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func skipMetrics(dAtA []byte) (n int, err error) {
- l := len(dAtA)
- iNdEx := 0
- depth := 0
- for iNdEx < l {
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return 0, ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return 0, io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- wireType := int(wire & 0x7)
- switch wireType {
- case 0:
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return 0, ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return 0, io.ErrUnexpectedEOF
- }
- iNdEx++
- if dAtA[iNdEx-1] < 0x80 {
- break
- }
- }
- case 1:
- iNdEx += 8
- case 2:
- var length int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return 0, ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return 0, io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- length |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if length < 0 {
- return 0, ErrInvalidLengthMetrics
- }
- iNdEx += length
- case 3:
- depth++
- case 4:
- if depth == 0 {
- return 0, ErrUnexpectedEndOfGroupMetrics
- }
- depth--
- case 5:
- iNdEx += 4
- default:
- return 0, fmt.Errorf("proto: illegal wireType %d", wireType)
- }
- if iNdEx < 0 {
- return 0, ErrInvalidLengthMetrics
- }
- if depth == 0 {
- return iNdEx, nil
- }
- }
- return 0, io.ErrUnexpectedEOF
-}
-
-var (
- ErrInvalidLengthMetrics = fmt.Errorf("proto: negative length found during unmarshaling")
- ErrIntOverflowMetrics = fmt.Errorf("proto: integer overflow")
- ErrUnexpectedEndOfGroupMetrics = fmt.Errorf("proto: unexpected end of group")
-)
diff --git a/vendor/github.com/containerd/cgroups/v2/stats/metrics.pb.go b/vendor/github.com/containerd/cgroups/v2/stats/metrics.pb.go
deleted file mode 100644
index 0bd493998..000000000
--- a/vendor/github.com/containerd/cgroups/v2/stats/metrics.pb.go
+++ /dev/null
@@ -1,3992 +0,0 @@
-// Code generated by protoc-gen-gogo. DO NOT EDIT.
-// source: github.com/containerd/cgroups/v2/stats/metrics.proto
-
-package stats
-
-import (
- fmt "fmt"
- _ "github.com/gogo/protobuf/gogoproto"
- proto "github.com/gogo/protobuf/proto"
- io "io"
- math "math"
- math_bits "math/bits"
- reflect "reflect"
- strings "strings"
-)
-
-// Reference imports to suppress errors if they are not otherwise used.
-var _ = proto.Marshal
-var _ = fmt.Errorf
-var _ = math.Inf
-
-// This is a compile-time assertion to ensure that this generated file
-// is compatible with the proto package it is being compiled against.
-// A compilation error at this line likely means your copy of the
-// proto package needs to be updated.
-const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package
-
-type Metrics struct {
- Pids *PidsStat `protobuf:"bytes,1,opt,name=pids,proto3" json:"pids,omitempty"`
- CPU *CPUStat `protobuf:"bytes,2,opt,name=cpu,proto3" json:"cpu,omitempty"`
- Memory *MemoryStat `protobuf:"bytes,4,opt,name=memory,proto3" json:"memory,omitempty"`
- Rdma *RdmaStat `protobuf:"bytes,5,opt,name=rdma,proto3" json:"rdma,omitempty"`
- Io *IOStat `protobuf:"bytes,6,opt,name=io,proto3" json:"io,omitempty"`
- Hugetlb []*HugeTlbStat `protobuf:"bytes,7,rep,name=hugetlb,proto3" json:"hugetlb,omitempty"`
- MemoryEvents *MemoryEvents `protobuf:"bytes,8,opt,name=memory_events,json=memoryEvents,proto3" json:"memory_events,omitempty"`
- XXX_NoUnkeyedLiteral struct{} `json:"-"`
- XXX_unrecognized []byte `json:"-"`
- XXX_sizecache int32 `json:"-"`
-}
-
-func (m *Metrics) Reset() { *m = Metrics{} }
-func (*Metrics) ProtoMessage() {}
-func (*Metrics) Descriptor() ([]byte, []int) {
- return fileDescriptor_2fc6005842049e6b, []int{0}
-}
-func (m *Metrics) XXX_Unmarshal(b []byte) error {
- return m.Unmarshal(b)
-}
-func (m *Metrics) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
- if deterministic {
- return xxx_messageInfo_Metrics.Marshal(b, m, deterministic)
- } else {
- b = b[:cap(b)]
- n, err := m.MarshalToSizedBuffer(b)
- if err != nil {
- return nil, err
- }
- return b[:n], nil
- }
-}
-func (m *Metrics) XXX_Merge(src proto.Message) {
- xxx_messageInfo_Metrics.Merge(m, src)
-}
-func (m *Metrics) XXX_Size() int {
- return m.Size()
-}
-func (m *Metrics) XXX_DiscardUnknown() {
- xxx_messageInfo_Metrics.DiscardUnknown(m)
-}
-
-var xxx_messageInfo_Metrics proto.InternalMessageInfo
-
-type PidsStat struct {
- Current uint64 `protobuf:"varint,1,opt,name=current,proto3" json:"current,omitempty"`
- Limit uint64 `protobuf:"varint,2,opt,name=limit,proto3" json:"limit,omitempty"`
- XXX_NoUnkeyedLiteral struct{} `json:"-"`
- XXX_unrecognized []byte `json:"-"`
- XXX_sizecache int32 `json:"-"`
-}
-
-func (m *PidsStat) Reset() { *m = PidsStat{} }
-func (*PidsStat) ProtoMessage() {}
-func (*PidsStat) Descriptor() ([]byte, []int) {
- return fileDescriptor_2fc6005842049e6b, []int{1}
-}
-func (m *PidsStat) XXX_Unmarshal(b []byte) error {
- return m.Unmarshal(b)
-}
-func (m *PidsStat) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
- if deterministic {
- return xxx_messageInfo_PidsStat.Marshal(b, m, deterministic)
- } else {
- b = b[:cap(b)]
- n, err := m.MarshalToSizedBuffer(b)
- if err != nil {
- return nil, err
- }
- return b[:n], nil
- }
-}
-func (m *PidsStat) XXX_Merge(src proto.Message) {
- xxx_messageInfo_PidsStat.Merge(m, src)
-}
-func (m *PidsStat) XXX_Size() int {
- return m.Size()
-}
-func (m *PidsStat) XXX_DiscardUnknown() {
- xxx_messageInfo_PidsStat.DiscardUnknown(m)
-}
-
-var xxx_messageInfo_PidsStat proto.InternalMessageInfo
-
-type CPUStat struct {
- UsageUsec uint64 `protobuf:"varint,1,opt,name=usage_usec,json=usageUsec,proto3" json:"usage_usec,omitempty"`
- UserUsec uint64 `protobuf:"varint,2,opt,name=user_usec,json=userUsec,proto3" json:"user_usec,omitempty"`
- SystemUsec uint64 `protobuf:"varint,3,opt,name=system_usec,json=systemUsec,proto3" json:"system_usec,omitempty"`
- NrPeriods uint64 `protobuf:"varint,4,opt,name=nr_periods,json=nrPeriods,proto3" json:"nr_periods,omitempty"`
- NrThrottled uint64 `protobuf:"varint,5,opt,name=nr_throttled,json=nrThrottled,proto3" json:"nr_throttled,omitempty"`
- ThrottledUsec uint64 `protobuf:"varint,6,opt,name=throttled_usec,json=throttledUsec,proto3" json:"throttled_usec,omitempty"`
- XXX_NoUnkeyedLiteral struct{} `json:"-"`
- XXX_unrecognized []byte `json:"-"`
- XXX_sizecache int32 `json:"-"`
-}
-
-func (m *CPUStat) Reset() { *m = CPUStat{} }
-func (*CPUStat) ProtoMessage() {}
-func (*CPUStat) Descriptor() ([]byte, []int) {
- return fileDescriptor_2fc6005842049e6b, []int{2}
-}
-func (m *CPUStat) XXX_Unmarshal(b []byte) error {
- return m.Unmarshal(b)
-}
-func (m *CPUStat) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
- if deterministic {
- return xxx_messageInfo_CPUStat.Marshal(b, m, deterministic)
- } else {
- b = b[:cap(b)]
- n, err := m.MarshalToSizedBuffer(b)
- if err != nil {
- return nil, err
- }
- return b[:n], nil
- }
-}
-func (m *CPUStat) XXX_Merge(src proto.Message) {
- xxx_messageInfo_CPUStat.Merge(m, src)
-}
-func (m *CPUStat) XXX_Size() int {
- return m.Size()
-}
-func (m *CPUStat) XXX_DiscardUnknown() {
- xxx_messageInfo_CPUStat.DiscardUnknown(m)
-}
-
-var xxx_messageInfo_CPUStat proto.InternalMessageInfo
-
-type MemoryStat struct {
- Anon uint64 `protobuf:"varint,1,opt,name=anon,proto3" json:"anon,omitempty"`
- File uint64 `protobuf:"varint,2,opt,name=file,proto3" json:"file,omitempty"`
- KernelStack uint64 `protobuf:"varint,3,opt,name=kernel_stack,json=kernelStack,proto3" json:"kernel_stack,omitempty"`
- Slab uint64 `protobuf:"varint,4,opt,name=slab,proto3" json:"slab,omitempty"`
- Sock uint64 `protobuf:"varint,5,opt,name=sock,proto3" json:"sock,omitempty"`
- Shmem uint64 `protobuf:"varint,6,opt,name=shmem,proto3" json:"shmem,omitempty"`
- FileMapped uint64 `protobuf:"varint,7,opt,name=file_mapped,json=fileMapped,proto3" json:"file_mapped,omitempty"`
- FileDirty uint64 `protobuf:"varint,8,opt,name=file_dirty,json=fileDirty,proto3" json:"file_dirty,omitempty"`
- FileWriteback uint64 `protobuf:"varint,9,opt,name=file_writeback,json=fileWriteback,proto3" json:"file_writeback,omitempty"`
- AnonThp uint64 `protobuf:"varint,10,opt,name=anon_thp,json=anonThp,proto3" json:"anon_thp,omitempty"`
- InactiveAnon uint64 `protobuf:"varint,11,opt,name=inactive_anon,json=inactiveAnon,proto3" json:"inactive_anon,omitempty"`
- ActiveAnon uint64 `protobuf:"varint,12,opt,name=active_anon,json=activeAnon,proto3" json:"active_anon,omitempty"`
- InactiveFile uint64 `protobuf:"varint,13,opt,name=inactive_file,json=inactiveFile,proto3" json:"inactive_file,omitempty"`
- ActiveFile uint64 `protobuf:"varint,14,opt,name=active_file,json=activeFile,proto3" json:"active_file,omitempty"`
- Unevictable uint64 `protobuf:"varint,15,opt,name=unevictable,proto3" json:"unevictable,omitempty"`
- SlabReclaimable uint64 `protobuf:"varint,16,opt,name=slab_reclaimable,json=slabReclaimable,proto3" json:"slab_reclaimable,omitempty"`
- SlabUnreclaimable uint64 `protobuf:"varint,17,opt,name=slab_unreclaimable,json=slabUnreclaimable,proto3" json:"slab_unreclaimable,omitempty"`
- Pgfault uint64 `protobuf:"varint,18,opt,name=pgfault,proto3" json:"pgfault,omitempty"`
- Pgmajfault uint64 `protobuf:"varint,19,opt,name=pgmajfault,proto3" json:"pgmajfault,omitempty"`
- WorkingsetRefault uint64 `protobuf:"varint,20,opt,name=workingset_refault,json=workingsetRefault,proto3" json:"workingset_refault,omitempty"`
- WorkingsetActivate uint64 `protobuf:"varint,21,opt,name=workingset_activate,json=workingsetActivate,proto3" json:"workingset_activate,omitempty"`
- WorkingsetNodereclaim uint64 `protobuf:"varint,22,opt,name=workingset_nodereclaim,json=workingsetNodereclaim,proto3" json:"workingset_nodereclaim,omitempty"`
- Pgrefill uint64 `protobuf:"varint,23,opt,name=pgrefill,proto3" json:"pgrefill,omitempty"`
- Pgscan uint64 `protobuf:"varint,24,opt,name=pgscan,proto3" json:"pgscan,omitempty"`
- Pgsteal uint64 `protobuf:"varint,25,opt,name=pgsteal,proto3" json:"pgsteal,omitempty"`
- Pgactivate uint64 `protobuf:"varint,26,opt,name=pgactivate,proto3" json:"pgactivate,omitempty"`
- Pgdeactivate uint64 `protobuf:"varint,27,opt,name=pgdeactivate,proto3" json:"pgdeactivate,omitempty"`
- Pglazyfree uint64 `protobuf:"varint,28,opt,name=pglazyfree,proto3" json:"pglazyfree,omitempty"`
- Pglazyfreed uint64 `protobuf:"varint,29,opt,name=pglazyfreed,proto3" json:"pglazyfreed,omitempty"`
- ThpFaultAlloc uint64 `protobuf:"varint,30,opt,name=thp_fault_alloc,json=thpFaultAlloc,proto3" json:"thp_fault_alloc,omitempty"`
- ThpCollapseAlloc uint64 `protobuf:"varint,31,opt,name=thp_collapse_alloc,json=thpCollapseAlloc,proto3" json:"thp_collapse_alloc,omitempty"`
- Usage uint64 `protobuf:"varint,32,opt,name=usage,proto3" json:"usage,omitempty"`
- UsageLimit uint64 `protobuf:"varint,33,opt,name=usage_limit,json=usageLimit,proto3" json:"usage_limit,omitempty"`
- SwapUsage uint64 `protobuf:"varint,34,opt,name=swap_usage,json=swapUsage,proto3" json:"swap_usage,omitempty"`
- SwapLimit uint64 `protobuf:"varint,35,opt,name=swap_limit,json=swapLimit,proto3" json:"swap_limit,omitempty"`
- XXX_NoUnkeyedLiteral struct{} `json:"-"`
- XXX_unrecognized []byte `json:"-"`
- XXX_sizecache int32 `json:"-"`
-}
-
-func (m *MemoryStat) Reset() { *m = MemoryStat{} }
-func (*MemoryStat) ProtoMessage() {}
-func (*MemoryStat) Descriptor() ([]byte, []int) {
- return fileDescriptor_2fc6005842049e6b, []int{3}
-}
-func (m *MemoryStat) XXX_Unmarshal(b []byte) error {
- return m.Unmarshal(b)
-}
-func (m *MemoryStat) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
- if deterministic {
- return xxx_messageInfo_MemoryStat.Marshal(b, m, deterministic)
- } else {
- b = b[:cap(b)]
- n, err := m.MarshalToSizedBuffer(b)
- if err != nil {
- return nil, err
- }
- return b[:n], nil
- }
-}
-func (m *MemoryStat) XXX_Merge(src proto.Message) {
- xxx_messageInfo_MemoryStat.Merge(m, src)
-}
-func (m *MemoryStat) XXX_Size() int {
- return m.Size()
-}
-func (m *MemoryStat) XXX_DiscardUnknown() {
- xxx_messageInfo_MemoryStat.DiscardUnknown(m)
-}
-
-var xxx_messageInfo_MemoryStat proto.InternalMessageInfo
-
-type MemoryEvents struct {
- Low uint64 `protobuf:"varint,1,opt,name=low,proto3" json:"low,omitempty"`
- High uint64 `protobuf:"varint,2,opt,name=high,proto3" json:"high,omitempty"`
- Max uint64 `protobuf:"varint,3,opt,name=max,proto3" json:"max,omitempty"`
- Oom uint64 `protobuf:"varint,4,opt,name=oom,proto3" json:"oom,omitempty"`
- OomKill uint64 `protobuf:"varint,5,opt,name=oom_kill,json=oomKill,proto3" json:"oom_kill,omitempty"`
- XXX_NoUnkeyedLiteral struct{} `json:"-"`
- XXX_unrecognized []byte `json:"-"`
- XXX_sizecache int32 `json:"-"`
-}
-
-func (m *MemoryEvents) Reset() { *m = MemoryEvents{} }
-func (*MemoryEvents) ProtoMessage() {}
-func (*MemoryEvents) Descriptor() ([]byte, []int) {
- return fileDescriptor_2fc6005842049e6b, []int{4}
-}
-func (m *MemoryEvents) XXX_Unmarshal(b []byte) error {
- return m.Unmarshal(b)
-}
-func (m *MemoryEvents) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
- if deterministic {
- return xxx_messageInfo_MemoryEvents.Marshal(b, m, deterministic)
- } else {
- b = b[:cap(b)]
- n, err := m.MarshalToSizedBuffer(b)
- if err != nil {
- return nil, err
- }
- return b[:n], nil
- }
-}
-func (m *MemoryEvents) XXX_Merge(src proto.Message) {
- xxx_messageInfo_MemoryEvents.Merge(m, src)
-}
-func (m *MemoryEvents) XXX_Size() int {
- return m.Size()
-}
-func (m *MemoryEvents) XXX_DiscardUnknown() {
- xxx_messageInfo_MemoryEvents.DiscardUnknown(m)
-}
-
-var xxx_messageInfo_MemoryEvents proto.InternalMessageInfo
-
-type RdmaStat struct {
- Current []*RdmaEntry `protobuf:"bytes,1,rep,name=current,proto3" json:"current,omitempty"`
- Limit []*RdmaEntry `protobuf:"bytes,2,rep,name=limit,proto3" json:"limit,omitempty"`
- XXX_NoUnkeyedLiteral struct{} `json:"-"`
- XXX_unrecognized []byte `json:"-"`
- XXX_sizecache int32 `json:"-"`
-}
-
-func (m *RdmaStat) Reset() { *m = RdmaStat{} }
-func (*RdmaStat) ProtoMessage() {}
-func (*RdmaStat) Descriptor() ([]byte, []int) {
- return fileDescriptor_2fc6005842049e6b, []int{5}
-}
-func (m *RdmaStat) XXX_Unmarshal(b []byte) error {
- return m.Unmarshal(b)
-}
-func (m *RdmaStat) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
- if deterministic {
- return xxx_messageInfo_RdmaStat.Marshal(b, m, deterministic)
- } else {
- b = b[:cap(b)]
- n, err := m.MarshalToSizedBuffer(b)
- if err != nil {
- return nil, err
- }
- return b[:n], nil
- }
-}
-func (m *RdmaStat) XXX_Merge(src proto.Message) {
- xxx_messageInfo_RdmaStat.Merge(m, src)
-}
-func (m *RdmaStat) XXX_Size() int {
- return m.Size()
-}
-func (m *RdmaStat) XXX_DiscardUnknown() {
- xxx_messageInfo_RdmaStat.DiscardUnknown(m)
-}
-
-var xxx_messageInfo_RdmaStat proto.InternalMessageInfo
-
-type RdmaEntry struct {
- Device string `protobuf:"bytes,1,opt,name=device,proto3" json:"device,omitempty"`
- HcaHandles uint32 `protobuf:"varint,2,opt,name=hca_handles,json=hcaHandles,proto3" json:"hca_handles,omitempty"`
- HcaObjects uint32 `protobuf:"varint,3,opt,name=hca_objects,json=hcaObjects,proto3" json:"hca_objects,omitempty"`
- XXX_NoUnkeyedLiteral struct{} `json:"-"`
- XXX_unrecognized []byte `json:"-"`
- XXX_sizecache int32 `json:"-"`
-}
-
-func (m *RdmaEntry) Reset() { *m = RdmaEntry{} }
-func (*RdmaEntry) ProtoMessage() {}
-func (*RdmaEntry) Descriptor() ([]byte, []int) {
- return fileDescriptor_2fc6005842049e6b, []int{6}
-}
-func (m *RdmaEntry) XXX_Unmarshal(b []byte) error {
- return m.Unmarshal(b)
-}
-func (m *RdmaEntry) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
- if deterministic {
- return xxx_messageInfo_RdmaEntry.Marshal(b, m, deterministic)
- } else {
- b = b[:cap(b)]
- n, err := m.MarshalToSizedBuffer(b)
- if err != nil {
- return nil, err
- }
- return b[:n], nil
- }
-}
-func (m *RdmaEntry) XXX_Merge(src proto.Message) {
- xxx_messageInfo_RdmaEntry.Merge(m, src)
-}
-func (m *RdmaEntry) XXX_Size() int {
- return m.Size()
-}
-func (m *RdmaEntry) XXX_DiscardUnknown() {
- xxx_messageInfo_RdmaEntry.DiscardUnknown(m)
-}
-
-var xxx_messageInfo_RdmaEntry proto.InternalMessageInfo
-
-type IOStat struct {
- Usage []*IOEntry `protobuf:"bytes,1,rep,name=usage,proto3" json:"usage,omitempty"`
- XXX_NoUnkeyedLiteral struct{} `json:"-"`
- XXX_unrecognized []byte `json:"-"`
- XXX_sizecache int32 `json:"-"`
-}
-
-func (m *IOStat) Reset() { *m = IOStat{} }
-func (*IOStat) ProtoMessage() {}
-func (*IOStat) Descriptor() ([]byte, []int) {
- return fileDescriptor_2fc6005842049e6b, []int{7}
-}
-func (m *IOStat) XXX_Unmarshal(b []byte) error {
- return m.Unmarshal(b)
-}
-func (m *IOStat) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
- if deterministic {
- return xxx_messageInfo_IOStat.Marshal(b, m, deterministic)
- } else {
- b = b[:cap(b)]
- n, err := m.MarshalToSizedBuffer(b)
- if err != nil {
- return nil, err
- }
- return b[:n], nil
- }
-}
-func (m *IOStat) XXX_Merge(src proto.Message) {
- xxx_messageInfo_IOStat.Merge(m, src)
-}
-func (m *IOStat) XXX_Size() int {
- return m.Size()
-}
-func (m *IOStat) XXX_DiscardUnknown() {
- xxx_messageInfo_IOStat.DiscardUnknown(m)
-}
-
-var xxx_messageInfo_IOStat proto.InternalMessageInfo
-
-type IOEntry struct {
- Major uint64 `protobuf:"varint,1,opt,name=major,proto3" json:"major,omitempty"`
- Minor uint64 `protobuf:"varint,2,opt,name=minor,proto3" json:"minor,omitempty"`
- Rbytes uint64 `protobuf:"varint,3,opt,name=rbytes,proto3" json:"rbytes,omitempty"`
- Wbytes uint64 `protobuf:"varint,4,opt,name=wbytes,proto3" json:"wbytes,omitempty"`
- Rios uint64 `protobuf:"varint,5,opt,name=rios,proto3" json:"rios,omitempty"`
- Wios uint64 `protobuf:"varint,6,opt,name=wios,proto3" json:"wios,omitempty"`
- XXX_NoUnkeyedLiteral struct{} `json:"-"`
- XXX_unrecognized []byte `json:"-"`
- XXX_sizecache int32 `json:"-"`
-}
-
-func (m *IOEntry) Reset() { *m = IOEntry{} }
-func (*IOEntry) ProtoMessage() {}
-func (*IOEntry) Descriptor() ([]byte, []int) {
- return fileDescriptor_2fc6005842049e6b, []int{8}
-}
-func (m *IOEntry) XXX_Unmarshal(b []byte) error {
- return m.Unmarshal(b)
-}
-func (m *IOEntry) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
- if deterministic {
- return xxx_messageInfo_IOEntry.Marshal(b, m, deterministic)
- } else {
- b = b[:cap(b)]
- n, err := m.MarshalToSizedBuffer(b)
- if err != nil {
- return nil, err
- }
- return b[:n], nil
- }
-}
-func (m *IOEntry) XXX_Merge(src proto.Message) {
- xxx_messageInfo_IOEntry.Merge(m, src)
-}
-func (m *IOEntry) XXX_Size() int {
- return m.Size()
-}
-func (m *IOEntry) XXX_DiscardUnknown() {
- xxx_messageInfo_IOEntry.DiscardUnknown(m)
-}
-
-var xxx_messageInfo_IOEntry proto.InternalMessageInfo
-
-type HugeTlbStat struct {
- Current uint64 `protobuf:"varint,1,opt,name=current,proto3" json:"current,omitempty"`
- Max uint64 `protobuf:"varint,2,opt,name=max,proto3" json:"max,omitempty"`
- Pagesize string `protobuf:"bytes,3,opt,name=pagesize,proto3" json:"pagesize,omitempty"`
- XXX_NoUnkeyedLiteral struct{} `json:"-"`
- XXX_unrecognized []byte `json:"-"`
- XXX_sizecache int32 `json:"-"`
-}
-
-func (m *HugeTlbStat) Reset() { *m = HugeTlbStat{} }
-func (*HugeTlbStat) ProtoMessage() {}
-func (*HugeTlbStat) Descriptor() ([]byte, []int) {
- return fileDescriptor_2fc6005842049e6b, []int{9}
-}
-func (m *HugeTlbStat) XXX_Unmarshal(b []byte) error {
- return m.Unmarshal(b)
-}
-func (m *HugeTlbStat) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
- if deterministic {
- return xxx_messageInfo_HugeTlbStat.Marshal(b, m, deterministic)
- } else {
- b = b[:cap(b)]
- n, err := m.MarshalToSizedBuffer(b)
- if err != nil {
- return nil, err
- }
- return b[:n], nil
- }
-}
-func (m *HugeTlbStat) XXX_Merge(src proto.Message) {
- xxx_messageInfo_HugeTlbStat.Merge(m, src)
-}
-func (m *HugeTlbStat) XXX_Size() int {
- return m.Size()
-}
-func (m *HugeTlbStat) XXX_DiscardUnknown() {
- xxx_messageInfo_HugeTlbStat.DiscardUnknown(m)
-}
-
-var xxx_messageInfo_HugeTlbStat proto.InternalMessageInfo
-
-func init() {
- proto.RegisterType((*Metrics)(nil), "io.containerd.cgroups.v2.Metrics")
- proto.RegisterType((*PidsStat)(nil), "io.containerd.cgroups.v2.PidsStat")
- proto.RegisterType((*CPUStat)(nil), "io.containerd.cgroups.v2.CPUStat")
- proto.RegisterType((*MemoryStat)(nil), "io.containerd.cgroups.v2.MemoryStat")
- proto.RegisterType((*MemoryEvents)(nil), "io.containerd.cgroups.v2.MemoryEvents")
- proto.RegisterType((*RdmaStat)(nil), "io.containerd.cgroups.v2.RdmaStat")
- proto.RegisterType((*RdmaEntry)(nil), "io.containerd.cgroups.v2.RdmaEntry")
- proto.RegisterType((*IOStat)(nil), "io.containerd.cgroups.v2.IOStat")
- proto.RegisterType((*IOEntry)(nil), "io.containerd.cgroups.v2.IOEntry")
- proto.RegisterType((*HugeTlbStat)(nil), "io.containerd.cgroups.v2.HugeTlbStat")
-}
-
-func init() {
- proto.RegisterFile("github.com/containerd/cgroups/v2/stats/metrics.proto", fileDescriptor_2fc6005842049e6b)
-}
-
-var fileDescriptor_2fc6005842049e6b = []byte{
- // 1198 bytes of a gzipped FileDescriptorProto
- 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x8c, 0x56, 0x4d, 0x73, 0xd4, 0x46,
- 0x13, 0x66, 0xed, 0xc5, 0xeb, 0xed, 0xb5, 0xc1, 0x0c, 0x86, 0x57, 0xc0, 0xcb, 0xda, 0x5e, 0x02,
- 0x45, 0xaa, 0x92, 0xdd, 0x94, 0xf3, 0x55, 0x49, 0x91, 0x4a, 0x19, 0x02, 0x45, 0x8a, 0x10, 0x5c,
- 0x02, 0x57, 0x8e, 0xaa, 0x59, 0x69, 0x2c, 0x0d, 0x96, 0x34, 0xaa, 0x99, 0x91, 0x1d, 0x73, 0xca,
- 0x21, 0xd7, 0x54, 0x7e, 0x4d, 0xfe, 0x03, 0xb7, 0xe4, 0x98, 0x53, 0x2a, 0xf8, 0x97, 0xa4, 0xba,
- 0x67, 0x64, 0x29, 0x07, 0x43, 0x6e, 0xd3, 0x4f, 0x3f, 0xdd, 0xea, 0x8f, 0x99, 0x6e, 0xc1, 0x27,
- 0xa9, 0xb4, 0x59, 0x3d, 0x9f, 0xc6, 0xaa, 0x98, 0xc5, 0xaa, 0xb4, 0x5c, 0x96, 0x42, 0x27, 0xb3,
- 0x38, 0xd5, 0xaa, 0xae, 0xcc, 0xec, 0x70, 0x7b, 0x66, 0x2c, 0xb7, 0x66, 0x56, 0x08, 0xab, 0x65,
- 0x6c, 0xa6, 0x95, 0x56, 0x56, 0xb1, 0x40, 0xaa, 0x69, 0xcb, 0x9e, 0x7a, 0xf6, 0xf4, 0x70, 0xfb,
- 0xfa, 0x7a, 0xaa, 0x52, 0x45, 0xa4, 0x19, 0x9e, 0x1c, 0x7f, 0xf2, 0xdb, 0x22, 0x0c, 0x9e, 0x3a,
- 0x0f, 0xec, 0x33, 0xe8, 0x57, 0x32, 0x31, 0x41, 0x6f, 0xb3, 0x77, 0x77, 0xb4, 0x3d, 0x99, 0x9e,
- 0xe5, 0x6a, 0xba, 0x2b, 0x13, 0xf3, 0xdc, 0x72, 0x1b, 0x12, 0x9f, 0xdd, 0x83, 0xc5, 0xb8, 0xaa,
- 0x83, 0x05, 0x32, 0xdb, 0x3a, 0xdb, 0xec, 0xc1, 0xee, 0x1e, 0x5a, 0xdd, 0x1f, 0x9c, 0xfc, 0xb5,
- 0xb1, 0xf8, 0x60, 0x77, 0x2f, 0x44, 0x33, 0x76, 0x0f, 0x96, 0x0a, 0x51, 0x28, 0x7d, 0x1c, 0xf4,
- 0xc9, 0xc1, 0x7b, 0x67, 0x3b, 0x78, 0x4a, 0x3c, 0xfa, 0xb2, 0xb7, 0xc1, 0x98, 0x75, 0x52, 0xf0,
- 0xe0, 0xfc, 0xbb, 0x62, 0x0e, 0x93, 0x82, 0xbb, 0x98, 0x91, 0xcf, 0x3e, 0x82, 0x05, 0xa9, 0x82,
- 0x25, 0xb2, 0xda, 0x3c, 0xdb, 0xea, 0xdb, 0x67, 0x64, 0xb3, 0x20, 0x15, 0xfb, 0x1a, 0x06, 0x59,
- 0x9d, 0x0a, 0x9b, 0xcf, 0x83, 0xc1, 0xe6, 0xe2, 0xdd, 0xd1, 0xf6, 0xed, 0xb3, 0xcd, 0x1e, 0xd7,
- 0xa9, 0x78, 0x91, 0xcf, 0xc9, 0xb6, 0xb1, 0x62, 0x4f, 0x60, 0xd5, 0x05, 0x1d, 0x89, 0x43, 0x51,
- 0x5a, 0x13, 0x2c, 0xd3, 0xd7, 0xef, 0xbc, 0x2b, 0xdf, 0x87, 0xc4, 0x0e, 0x57, 0x8a, 0x8e, 0x34,
- 0xf9, 0x12, 0x96, 0x9b, 0x2e, 0xb0, 0x00, 0x06, 0x71, 0xad, 0xb5, 0x28, 0x2d, 0xb5, 0xae, 0x1f,
- 0x36, 0x22, 0x5b, 0x87, 0xf3, 0xb9, 0x2c, 0xa4, 0xa5, 0xde, 0xf4, 0x43, 0x27, 0x4c, 0x7e, 0xef,
- 0xc1, 0xc0, 0xf7, 0x82, 0xdd, 0x04, 0xa8, 0x0d, 0x4f, 0x45, 0x54, 0x1b, 0x11, 0x7b, 0xf3, 0x21,
- 0x21, 0x7b, 0x46, 0xc4, 0xec, 0x06, 0x0c, 0x6b, 0x23, 0xb4, 0xd3, 0x3a, 0x27, 0xcb, 0x08, 0x90,
- 0x72, 0x03, 0x46, 0xe6, 0xd8, 0x58, 0x51, 0x38, 0xf5, 0x22, 0xa9, 0xc1, 0x41, 0x44, 0xb8, 0x09,
- 0x50, 0xea, 0xa8, 0x12, 0x5a, 0xaa, 0xc4, 0x50, 0x7b, 0xfb, 0xe1, 0xb0, 0xd4, 0xbb, 0x0e, 0x60,
- 0x5b, 0xb0, 0x52, 0xea, 0xc8, 0x66, 0x5a, 0x59, 0x9b, 0x8b, 0x84, 0x7a, 0xd8, 0x0f, 0x47, 0xa5,
- 0x7e, 0xd1, 0x40, 0xec, 0x36, 0x5c, 0x38, 0xd5, 0xbb, 0xaf, 0x2c, 0x11, 0x69, 0xf5, 0x14, 0xc5,
- 0x0f, 0x4d, 0x7e, 0x1d, 0x02, 0xb4, 0x97, 0x83, 0x31, 0xe8, 0xf3, 0x52, 0x95, 0x3e, 0x1d, 0x3a,
- 0x23, 0xb6, 0x2f, 0x73, 0xe1, 0x93, 0xa0, 0x33, 0x06, 0x70, 0x20, 0x74, 0x29, 0xf2, 0xc8, 0x58,
- 0x1e, 0x1f, 0xf8, 0x0c, 0x46, 0x0e, 0x7b, 0x8e, 0x10, 0x9a, 0x99, 0x9c, 0xcf, 0x7d, 0xf0, 0x74,
- 0x26, 0x4c, 0xc5, 0x07, 0x3e, 0x5e, 0x3a, 0x63, 0xa5, 0x4d, 0x56, 0x88, 0xc2, 0xc7, 0xe7, 0x04,
- 0xac, 0x10, 0x7e, 0x28, 0x2a, 0x78, 0x55, 0x89, 0x24, 0x18, 0xb8, 0x0a, 0x21, 0xf4, 0x94, 0x10,
- 0xac, 0x10, 0x11, 0x12, 0xa9, 0xed, 0x31, 0x5d, 0x88, 0x7e, 0x38, 0x44, 0xe4, 0x1b, 0x04, 0x30,
- 0x7d, 0x52, 0x1f, 0x69, 0x69, 0xc5, 0x1c, 0x43, 0x1c, 0xba, 0xf4, 0x11, 0xfd, 0xa1, 0x01, 0xd9,
- 0x35, 0x58, 0xc6, 0x1c, 0x23, 0x9b, 0x55, 0x01, 0xb8, 0x1b, 0x80, 0xf2, 0x8b, 0xac, 0x62, 0xb7,
- 0x60, 0x55, 0x96, 0x3c, 0xb6, 0xf2, 0x50, 0x44, 0x54, 0x93, 0x11, 0xe9, 0x57, 0x1a, 0x70, 0x07,
- 0x6b, 0xb3, 0x01, 0xa3, 0x2e, 0x65, 0xc5, 0x85, 0xd9, 0x21, 0x74, 0xbd, 0x50, 0x15, 0x57, 0xff,
- 0xed, 0xe5, 0x11, 0x56, 0xb3, 0xf5, 0x42, 0x94, 0x0b, 0x5d, 0x2f, 0x44, 0xd8, 0x84, 0x51, 0x5d,
- 0x8a, 0x43, 0x19, 0x5b, 0x3e, 0xcf, 0x45, 0x70, 0xd1, 0x55, 0xbb, 0x03, 0xb1, 0xf7, 0x61, 0x0d,
- 0x2b, 0x1c, 0x69, 0x11, 0xe7, 0x5c, 0x16, 0x44, 0x5b, 0x23, 0xda, 0x45, 0xc4, 0xc3, 0x16, 0x66,
- 0x1f, 0x02, 0x23, 0x6a, 0x5d, 0x76, 0xc9, 0x97, 0x88, 0x7c, 0x09, 0x35, 0x7b, 0x5d, 0x05, 0xbe,
- 0x91, 0x2a, 0xdd, 0xe7, 0x75, 0x6e, 0x03, 0xe6, 0x2a, 0xe4, 0x45, 0x36, 0x06, 0xa8, 0xd2, 0x82,
- 0xbf, 0x74, 0xca, 0xcb, 0x2e, 0xea, 0x16, 0xc1, 0x0f, 0x1d, 0x29, 0x7d, 0x20, 0xcb, 0xd4, 0x08,
- 0x1b, 0x69, 0xe1, 0x78, 0xeb, 0xee, 0x43, 0xad, 0x26, 0x74, 0x0a, 0x36, 0x83, 0xcb, 0x1d, 0x3a,
- 0x65, 0xcf, 0xad, 0x08, 0xae, 0x10, 0xbf, 0xe3, 0x69, 0xc7, 0x6b, 0xd8, 0xa7, 0x70, 0xb5, 0x63,
- 0x50, 0xaa, 0x44, 0xf8, 0xb8, 0x83, 0xab, 0x64, 0x73, 0xa5, 0xd5, 0x7e, 0xdf, 0x2a, 0xd9, 0x75,
- 0x58, 0xae, 0x52, 0x2d, 0xf6, 0x65, 0x9e, 0x07, 0xff, 0x73, 0x0f, 0xb3, 0x91, 0xd9, 0x55, 0x58,
- 0xaa, 0x52, 0x13, 0xf3, 0x32, 0x08, 0x48, 0xe3, 0x25, 0x57, 0x04, 0x63, 0x05, 0xcf, 0x83, 0x6b,
- 0x4d, 0x11, 0x48, 0x74, 0x45, 0x38, 0x0d, 0xf6, 0x7a, 0x53, 0x84, 0x06, 0x61, 0x13, 0x58, 0xa9,
- 0xd2, 0x44, 0x9c, 0x32, 0x6e, 0xb8, 0xfe, 0x77, 0x31, 0xe7, 0x23, 0xe7, 0xaf, 0x8e, 0xf7, 0xb5,
- 0x10, 0xc1, 0xff, 0x1b, 0x1f, 0x0d, 0x82, 0xed, 0x6f, 0xa5, 0x24, 0xb8, 0xe9, 0xda, 0xdf, 0x81,
- 0xd8, 0x1d, 0xb8, 0x68, 0xb3, 0x2a, 0xa2, 0x42, 0x46, 0x3c, 0xcf, 0x55, 0x1c, 0x8c, 0x9b, 0xe7,
- 0x5e, 0x3d, 0x42, 0x74, 0x07, 0x41, 0xf6, 0x01, 0x30, 0xe4, 0xc5, 0x2a, 0xcf, 0x79, 0x65, 0x84,
- 0xa7, 0x6e, 0x10, 0x75, 0xcd, 0x66, 0xd5, 0x03, 0xaf, 0x70, 0xec, 0x75, 0x38, 0x4f, 0x03, 0x2d,
- 0xd8, 0x74, 0x4f, 0x93, 0x04, 0xbc, 0xad, 0x6e, 0xf0, 0xb9, 0x01, 0xb9, 0xe5, 0xc2, 0x25, 0xe8,
- 0x3b, 0x44, 0xf0, 0x69, 0x9a, 0x23, 0x5e, 0x45, 0xce, 0x76, 0xe2, 0x9e, 0x26, 0x22, 0x7b, 0x64,
- 0xdf, 0xa8, 0x9d, 0xf9, 0xad, 0x56, 0x4d, 0xd6, 0x13, 0x03, 0x2b, 0xdd, 0xe9, 0xcd, 0xd6, 0x60,
- 0x31, 0x57, 0x47, 0x7e, 0x22, 0xe1, 0x11, 0xa7, 0x48, 0x26, 0xd3, 0xac, 0x19, 0x48, 0x78, 0x46,
- 0x56, 0xc1, 0x7f, 0xf4, 0x73, 0x08, 0x8f, 0x88, 0x28, 0x55, 0xf8, 0xf1, 0x83, 0x47, 0x7c, 0xec,
- 0x4a, 0x15, 0xd1, 0x01, 0x36, 0xde, 0x4d, 0xa0, 0x81, 0x52, 0xc5, 0x13, 0x99, 0xe7, 0x93, 0x9f,
- 0x7b, 0xb0, 0xdc, 0xec, 0x39, 0xf6, 0x55, 0x77, 0x2b, 0xe0, 0xbe, 0xba, 0xf5, 0xf6, 0xe5, 0xf8,
- 0xb0, 0xb4, 0xfa, 0xb8, 0x5d, 0x1d, 0x5f, 0xb4, 0xab, 0xe3, 0x3f, 0x1b, 0xfb, 0xfd, 0x22, 0x60,
- 0x78, 0x8a, 0xe1, 0x5d, 0x4c, 0xf0, 0x81, 0x0b, 0xca, 0x7d, 0x18, 0x7a, 0x09, 0xeb, 0x9f, 0xc5,
- 0x3c, 0xca, 0x78, 0x99, 0xe4, 0xc2, 0x50, 0x15, 0x56, 0x43, 0xc8, 0x62, 0xfe, 0xd8, 0x21, 0x0d,
- 0x41, 0xcd, 0x5f, 0x8a, 0xd8, 0x1a, 0xaa, 0x89, 0x23, 0x3c, 0x73, 0xc8, 0x64, 0x07, 0x96, 0xdc,
- 0x7a, 0x66, 0x9f, 0x37, 0x1d, 0x76, 0x89, 0x6e, 0xbd, 0x6d, 0x9f, 0xfb, 0x48, 0x89, 0x3f, 0xf9,
- 0xa5, 0x07, 0x03, 0x0f, 0xe1, 0x35, 0x29, 0xf8, 0x4b, 0xa5, 0x7d, 0x8f, 0x9c, 0x40, 0xa8, 0x2c,
- 0x95, 0x6e, 0x36, 0x28, 0x09, 0x98, 0x94, 0x9e, 0x1f, 0x5b, 0x61, 0x7c, 0xab, 0xbc, 0x84, 0xf8,
- 0x91, 0xc3, 0x5d, 0xc3, 0xbc, 0x84, 0xbd, 0xd6, 0x52, 0x99, 0x66, 0x63, 0xe0, 0x19, 0xb1, 0x23,
- 0xc4, 0xdc, 0xc2, 0xa0, 0xf3, 0x64, 0x0f, 0x46, 0x9d, 0x5f, 0x87, 0xb7, 0x2c, 0x76, 0x7f, 0x51,
- 0x16, 0xda, 0x8b, 0x82, 0xf3, 0x80, 0xa7, 0xc2, 0xc8, 0x57, 0x82, 0x82, 0x1a, 0x86, 0xa7, 0xf2,
- 0xfd, 0xe0, 0xf5, 0x9b, 0xf1, 0xb9, 0x3f, 0xdf, 0x8c, 0xcf, 0xfd, 0x74, 0x32, 0xee, 0xbd, 0x3e,
- 0x19, 0xf7, 0xfe, 0x38, 0x19, 0xf7, 0xfe, 0x3e, 0x19, 0xf7, 0xe6, 0x4b, 0xf4, 0x17, 0xf8, 0xf1,
- 0x3f, 0x01, 0x00, 0x00, 0xff, 0xff, 0x4f, 0x2b, 0x30, 0xd6, 0x6d, 0x0a, 0x00, 0x00,
-}
-
-func (m *Metrics) Marshal() (dAtA []byte, err error) {
- size := m.Size()
- dAtA = make([]byte, size)
- n, err := m.MarshalToSizedBuffer(dAtA[:size])
- if err != nil {
- return nil, err
- }
- return dAtA[:n], nil
-}
-
-func (m *Metrics) MarshalTo(dAtA []byte) (int, error) {
- size := m.Size()
- return m.MarshalToSizedBuffer(dAtA[:size])
-}
-
-func (m *Metrics) MarshalToSizedBuffer(dAtA []byte) (int, error) {
- i := len(dAtA)
- _ = i
- var l int
- _ = l
- if m.XXX_unrecognized != nil {
- i -= len(m.XXX_unrecognized)
- copy(dAtA[i:], m.XXX_unrecognized)
- }
- if m.MemoryEvents != nil {
- {
- size, err := m.MemoryEvents.MarshalToSizedBuffer(dAtA[:i])
- if err != nil {
- return 0, err
- }
- i -= size
- i = encodeVarintMetrics(dAtA, i, uint64(size))
- }
- i--
- dAtA[i] = 0x42
- }
- if len(m.Hugetlb) > 0 {
- for iNdEx := len(m.Hugetlb) - 1; iNdEx >= 0; iNdEx-- {
- {
- size, err := m.Hugetlb[iNdEx].MarshalToSizedBuffer(dAtA[:i])
- if err != nil {
- return 0, err
- }
- i -= size
- i = encodeVarintMetrics(dAtA, i, uint64(size))
- }
- i--
- dAtA[i] = 0x3a
- }
- }
- if m.Io != nil {
- {
- size, err := m.Io.MarshalToSizedBuffer(dAtA[:i])
- if err != nil {
- return 0, err
- }
- i -= size
- i = encodeVarintMetrics(dAtA, i, uint64(size))
- }
- i--
- dAtA[i] = 0x32
- }
- if m.Rdma != nil {
- {
- size, err := m.Rdma.MarshalToSizedBuffer(dAtA[:i])
- if err != nil {
- return 0, err
- }
- i -= size
- i = encodeVarintMetrics(dAtA, i, uint64(size))
- }
- i--
- dAtA[i] = 0x2a
- }
- if m.Memory != nil {
- {
- size, err := m.Memory.MarshalToSizedBuffer(dAtA[:i])
- if err != nil {
- return 0, err
- }
- i -= size
- i = encodeVarintMetrics(dAtA, i, uint64(size))
- }
- i--
- dAtA[i] = 0x22
- }
- if m.CPU != nil {
- {
- size, err := m.CPU.MarshalToSizedBuffer(dAtA[:i])
- if err != nil {
- return 0, err
- }
- i -= size
- i = encodeVarintMetrics(dAtA, i, uint64(size))
- }
- i--
- dAtA[i] = 0x12
- }
- if m.Pids != nil {
- {
- size, err := m.Pids.MarshalToSizedBuffer(dAtA[:i])
- if err != nil {
- return 0, err
- }
- i -= size
- i = encodeVarintMetrics(dAtA, i, uint64(size))
- }
- i--
- dAtA[i] = 0xa
- }
- return len(dAtA) - i, nil
-}
-
-func (m *PidsStat) Marshal() (dAtA []byte, err error) {
- size := m.Size()
- dAtA = make([]byte, size)
- n, err := m.MarshalToSizedBuffer(dAtA[:size])
- if err != nil {
- return nil, err
- }
- return dAtA[:n], nil
-}
-
-func (m *PidsStat) MarshalTo(dAtA []byte) (int, error) {
- size := m.Size()
- return m.MarshalToSizedBuffer(dAtA[:size])
-}
-
-func (m *PidsStat) MarshalToSizedBuffer(dAtA []byte) (int, error) {
- i := len(dAtA)
- _ = i
- var l int
- _ = l
- if m.XXX_unrecognized != nil {
- i -= len(m.XXX_unrecognized)
- copy(dAtA[i:], m.XXX_unrecognized)
- }
- if m.Limit != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.Limit))
- i--
- dAtA[i] = 0x10
- }
- if m.Current != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.Current))
- i--
- dAtA[i] = 0x8
- }
- return len(dAtA) - i, nil
-}
-
-func (m *CPUStat) Marshal() (dAtA []byte, err error) {
- size := m.Size()
- dAtA = make([]byte, size)
- n, err := m.MarshalToSizedBuffer(dAtA[:size])
- if err != nil {
- return nil, err
- }
- return dAtA[:n], nil
-}
-
-func (m *CPUStat) MarshalTo(dAtA []byte) (int, error) {
- size := m.Size()
- return m.MarshalToSizedBuffer(dAtA[:size])
-}
-
-func (m *CPUStat) MarshalToSizedBuffer(dAtA []byte) (int, error) {
- i := len(dAtA)
- _ = i
- var l int
- _ = l
- if m.XXX_unrecognized != nil {
- i -= len(m.XXX_unrecognized)
- copy(dAtA[i:], m.XXX_unrecognized)
- }
- if m.ThrottledUsec != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.ThrottledUsec))
- i--
- dAtA[i] = 0x30
- }
- if m.NrThrottled != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.NrThrottled))
- i--
- dAtA[i] = 0x28
- }
- if m.NrPeriods != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.NrPeriods))
- i--
- dAtA[i] = 0x20
- }
- if m.SystemUsec != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.SystemUsec))
- i--
- dAtA[i] = 0x18
- }
- if m.UserUsec != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.UserUsec))
- i--
- dAtA[i] = 0x10
- }
- if m.UsageUsec != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.UsageUsec))
- i--
- dAtA[i] = 0x8
- }
- return len(dAtA) - i, nil
-}
-
-func (m *MemoryStat) Marshal() (dAtA []byte, err error) {
- size := m.Size()
- dAtA = make([]byte, size)
- n, err := m.MarshalToSizedBuffer(dAtA[:size])
- if err != nil {
- return nil, err
- }
- return dAtA[:n], nil
-}
-
-func (m *MemoryStat) MarshalTo(dAtA []byte) (int, error) {
- size := m.Size()
- return m.MarshalToSizedBuffer(dAtA[:size])
-}
-
-func (m *MemoryStat) MarshalToSizedBuffer(dAtA []byte) (int, error) {
- i := len(dAtA)
- _ = i
- var l int
- _ = l
- if m.XXX_unrecognized != nil {
- i -= len(m.XXX_unrecognized)
- copy(dAtA[i:], m.XXX_unrecognized)
- }
- if m.SwapLimit != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.SwapLimit))
- i--
- dAtA[i] = 0x2
- i--
- dAtA[i] = 0x98
- }
- if m.SwapUsage != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.SwapUsage))
- i--
- dAtA[i] = 0x2
- i--
- dAtA[i] = 0x90
- }
- if m.UsageLimit != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.UsageLimit))
- i--
- dAtA[i] = 0x2
- i--
- dAtA[i] = 0x88
- }
- if m.Usage != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.Usage))
- i--
- dAtA[i] = 0x2
- i--
- dAtA[i] = 0x80
- }
- if m.ThpCollapseAlloc != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.ThpCollapseAlloc))
- i--
- dAtA[i] = 0x1
- i--
- dAtA[i] = 0xf8
- }
- if m.ThpFaultAlloc != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.ThpFaultAlloc))
- i--
- dAtA[i] = 0x1
- i--
- dAtA[i] = 0xf0
- }
- if m.Pglazyfreed != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.Pglazyfreed))
- i--
- dAtA[i] = 0x1
- i--
- dAtA[i] = 0xe8
- }
- if m.Pglazyfree != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.Pglazyfree))
- i--
- dAtA[i] = 0x1
- i--
- dAtA[i] = 0xe0
- }
- if m.Pgdeactivate != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.Pgdeactivate))
- i--
- dAtA[i] = 0x1
- i--
- dAtA[i] = 0xd8
- }
- if m.Pgactivate != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.Pgactivate))
- i--
- dAtA[i] = 0x1
- i--
- dAtA[i] = 0xd0
- }
- if m.Pgsteal != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.Pgsteal))
- i--
- dAtA[i] = 0x1
- i--
- dAtA[i] = 0xc8
- }
- if m.Pgscan != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.Pgscan))
- i--
- dAtA[i] = 0x1
- i--
- dAtA[i] = 0xc0
- }
- if m.Pgrefill != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.Pgrefill))
- i--
- dAtA[i] = 0x1
- i--
- dAtA[i] = 0xb8
- }
- if m.WorkingsetNodereclaim != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.WorkingsetNodereclaim))
- i--
- dAtA[i] = 0x1
- i--
- dAtA[i] = 0xb0
- }
- if m.WorkingsetActivate != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.WorkingsetActivate))
- i--
- dAtA[i] = 0x1
- i--
- dAtA[i] = 0xa8
- }
- if m.WorkingsetRefault != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.WorkingsetRefault))
- i--
- dAtA[i] = 0x1
- i--
- dAtA[i] = 0xa0
- }
- if m.Pgmajfault != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.Pgmajfault))
- i--
- dAtA[i] = 0x1
- i--
- dAtA[i] = 0x98
- }
- if m.Pgfault != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.Pgfault))
- i--
- dAtA[i] = 0x1
- i--
- dAtA[i] = 0x90
- }
- if m.SlabUnreclaimable != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.SlabUnreclaimable))
- i--
- dAtA[i] = 0x1
- i--
- dAtA[i] = 0x88
- }
- if m.SlabReclaimable != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.SlabReclaimable))
- i--
- dAtA[i] = 0x1
- i--
- dAtA[i] = 0x80
- }
- if m.Unevictable != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.Unevictable))
- i--
- dAtA[i] = 0x78
- }
- if m.ActiveFile != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.ActiveFile))
- i--
- dAtA[i] = 0x70
- }
- if m.InactiveFile != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.InactiveFile))
- i--
- dAtA[i] = 0x68
- }
- if m.ActiveAnon != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.ActiveAnon))
- i--
- dAtA[i] = 0x60
- }
- if m.InactiveAnon != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.InactiveAnon))
- i--
- dAtA[i] = 0x58
- }
- if m.AnonThp != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.AnonThp))
- i--
- dAtA[i] = 0x50
- }
- if m.FileWriteback != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.FileWriteback))
- i--
- dAtA[i] = 0x48
- }
- if m.FileDirty != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.FileDirty))
- i--
- dAtA[i] = 0x40
- }
- if m.FileMapped != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.FileMapped))
- i--
- dAtA[i] = 0x38
- }
- if m.Shmem != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.Shmem))
- i--
- dAtA[i] = 0x30
- }
- if m.Sock != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.Sock))
- i--
- dAtA[i] = 0x28
- }
- if m.Slab != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.Slab))
- i--
- dAtA[i] = 0x20
- }
- if m.KernelStack != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.KernelStack))
- i--
- dAtA[i] = 0x18
- }
- if m.File != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.File))
- i--
- dAtA[i] = 0x10
- }
- if m.Anon != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.Anon))
- i--
- dAtA[i] = 0x8
- }
- return len(dAtA) - i, nil
-}
-
-func (m *MemoryEvents) Marshal() (dAtA []byte, err error) {
- size := m.Size()
- dAtA = make([]byte, size)
- n, err := m.MarshalToSizedBuffer(dAtA[:size])
- if err != nil {
- return nil, err
- }
- return dAtA[:n], nil
-}
-
-func (m *MemoryEvents) MarshalTo(dAtA []byte) (int, error) {
- size := m.Size()
- return m.MarshalToSizedBuffer(dAtA[:size])
-}
-
-func (m *MemoryEvents) MarshalToSizedBuffer(dAtA []byte) (int, error) {
- i := len(dAtA)
- _ = i
- var l int
- _ = l
- if m.XXX_unrecognized != nil {
- i -= len(m.XXX_unrecognized)
- copy(dAtA[i:], m.XXX_unrecognized)
- }
- if m.OomKill != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.OomKill))
- i--
- dAtA[i] = 0x28
- }
- if m.Oom != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.Oom))
- i--
- dAtA[i] = 0x20
- }
- if m.Max != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.Max))
- i--
- dAtA[i] = 0x18
- }
- if m.High != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.High))
- i--
- dAtA[i] = 0x10
- }
- if m.Low != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.Low))
- i--
- dAtA[i] = 0x8
- }
- return len(dAtA) - i, nil
-}
-
-func (m *RdmaStat) Marshal() (dAtA []byte, err error) {
- size := m.Size()
- dAtA = make([]byte, size)
- n, err := m.MarshalToSizedBuffer(dAtA[:size])
- if err != nil {
- return nil, err
- }
- return dAtA[:n], nil
-}
-
-func (m *RdmaStat) MarshalTo(dAtA []byte) (int, error) {
- size := m.Size()
- return m.MarshalToSizedBuffer(dAtA[:size])
-}
-
-func (m *RdmaStat) MarshalToSizedBuffer(dAtA []byte) (int, error) {
- i := len(dAtA)
- _ = i
- var l int
- _ = l
- if m.XXX_unrecognized != nil {
- i -= len(m.XXX_unrecognized)
- copy(dAtA[i:], m.XXX_unrecognized)
- }
- if len(m.Limit) > 0 {
- for iNdEx := len(m.Limit) - 1; iNdEx >= 0; iNdEx-- {
- {
- size, err := m.Limit[iNdEx].MarshalToSizedBuffer(dAtA[:i])
- if err != nil {
- return 0, err
- }
- i -= size
- i = encodeVarintMetrics(dAtA, i, uint64(size))
- }
- i--
- dAtA[i] = 0x12
- }
- }
- if len(m.Current) > 0 {
- for iNdEx := len(m.Current) - 1; iNdEx >= 0; iNdEx-- {
- {
- size, err := m.Current[iNdEx].MarshalToSizedBuffer(dAtA[:i])
- if err != nil {
- return 0, err
- }
- i -= size
- i = encodeVarintMetrics(dAtA, i, uint64(size))
- }
- i--
- dAtA[i] = 0xa
- }
- }
- return len(dAtA) - i, nil
-}
-
-func (m *RdmaEntry) Marshal() (dAtA []byte, err error) {
- size := m.Size()
- dAtA = make([]byte, size)
- n, err := m.MarshalToSizedBuffer(dAtA[:size])
- if err != nil {
- return nil, err
- }
- return dAtA[:n], nil
-}
-
-func (m *RdmaEntry) MarshalTo(dAtA []byte) (int, error) {
- size := m.Size()
- return m.MarshalToSizedBuffer(dAtA[:size])
-}
-
-func (m *RdmaEntry) MarshalToSizedBuffer(dAtA []byte) (int, error) {
- i := len(dAtA)
- _ = i
- var l int
- _ = l
- if m.XXX_unrecognized != nil {
- i -= len(m.XXX_unrecognized)
- copy(dAtA[i:], m.XXX_unrecognized)
- }
- if m.HcaObjects != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.HcaObjects))
- i--
- dAtA[i] = 0x18
- }
- if m.HcaHandles != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.HcaHandles))
- i--
- dAtA[i] = 0x10
- }
- if len(m.Device) > 0 {
- i -= len(m.Device)
- copy(dAtA[i:], m.Device)
- i = encodeVarintMetrics(dAtA, i, uint64(len(m.Device)))
- i--
- dAtA[i] = 0xa
- }
- return len(dAtA) - i, nil
-}
-
-func (m *IOStat) Marshal() (dAtA []byte, err error) {
- size := m.Size()
- dAtA = make([]byte, size)
- n, err := m.MarshalToSizedBuffer(dAtA[:size])
- if err != nil {
- return nil, err
- }
- return dAtA[:n], nil
-}
-
-func (m *IOStat) MarshalTo(dAtA []byte) (int, error) {
- size := m.Size()
- return m.MarshalToSizedBuffer(dAtA[:size])
-}
-
-func (m *IOStat) MarshalToSizedBuffer(dAtA []byte) (int, error) {
- i := len(dAtA)
- _ = i
- var l int
- _ = l
- if m.XXX_unrecognized != nil {
- i -= len(m.XXX_unrecognized)
- copy(dAtA[i:], m.XXX_unrecognized)
- }
- if len(m.Usage) > 0 {
- for iNdEx := len(m.Usage) - 1; iNdEx >= 0; iNdEx-- {
- {
- size, err := m.Usage[iNdEx].MarshalToSizedBuffer(dAtA[:i])
- if err != nil {
- return 0, err
- }
- i -= size
- i = encodeVarintMetrics(dAtA, i, uint64(size))
- }
- i--
- dAtA[i] = 0xa
- }
- }
- return len(dAtA) - i, nil
-}
-
-func (m *IOEntry) Marshal() (dAtA []byte, err error) {
- size := m.Size()
- dAtA = make([]byte, size)
- n, err := m.MarshalToSizedBuffer(dAtA[:size])
- if err != nil {
- return nil, err
- }
- return dAtA[:n], nil
-}
-
-func (m *IOEntry) MarshalTo(dAtA []byte) (int, error) {
- size := m.Size()
- return m.MarshalToSizedBuffer(dAtA[:size])
-}
-
-func (m *IOEntry) MarshalToSizedBuffer(dAtA []byte) (int, error) {
- i := len(dAtA)
- _ = i
- var l int
- _ = l
- if m.XXX_unrecognized != nil {
- i -= len(m.XXX_unrecognized)
- copy(dAtA[i:], m.XXX_unrecognized)
- }
- if m.Wios != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.Wios))
- i--
- dAtA[i] = 0x30
- }
- if m.Rios != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.Rios))
- i--
- dAtA[i] = 0x28
- }
- if m.Wbytes != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.Wbytes))
- i--
- dAtA[i] = 0x20
- }
- if m.Rbytes != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.Rbytes))
- i--
- dAtA[i] = 0x18
- }
- if m.Minor != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.Minor))
- i--
- dAtA[i] = 0x10
- }
- if m.Major != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.Major))
- i--
- dAtA[i] = 0x8
- }
- return len(dAtA) - i, nil
-}
-
-func (m *HugeTlbStat) Marshal() (dAtA []byte, err error) {
- size := m.Size()
- dAtA = make([]byte, size)
- n, err := m.MarshalToSizedBuffer(dAtA[:size])
- if err != nil {
- return nil, err
- }
- return dAtA[:n], nil
-}
-
-func (m *HugeTlbStat) MarshalTo(dAtA []byte) (int, error) {
- size := m.Size()
- return m.MarshalToSizedBuffer(dAtA[:size])
-}
-
-func (m *HugeTlbStat) MarshalToSizedBuffer(dAtA []byte) (int, error) {
- i := len(dAtA)
- _ = i
- var l int
- _ = l
- if m.XXX_unrecognized != nil {
- i -= len(m.XXX_unrecognized)
- copy(dAtA[i:], m.XXX_unrecognized)
- }
- if len(m.Pagesize) > 0 {
- i -= len(m.Pagesize)
- copy(dAtA[i:], m.Pagesize)
- i = encodeVarintMetrics(dAtA, i, uint64(len(m.Pagesize)))
- i--
- dAtA[i] = 0x1a
- }
- if m.Max != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.Max))
- i--
- dAtA[i] = 0x10
- }
- if m.Current != 0 {
- i = encodeVarintMetrics(dAtA, i, uint64(m.Current))
- i--
- dAtA[i] = 0x8
- }
- return len(dAtA) - i, nil
-}
-
-func encodeVarintMetrics(dAtA []byte, offset int, v uint64) int {
- offset -= sovMetrics(v)
- base := offset
- for v >= 1<<7 {
- dAtA[offset] = uint8(v&0x7f | 0x80)
- v >>= 7
- offset++
- }
- dAtA[offset] = uint8(v)
- return base
-}
-func (m *Metrics) Size() (n int) {
- if m == nil {
- return 0
- }
- var l int
- _ = l
- if m.Pids != nil {
- l = m.Pids.Size()
- n += 1 + l + sovMetrics(uint64(l))
- }
- if m.CPU != nil {
- l = m.CPU.Size()
- n += 1 + l + sovMetrics(uint64(l))
- }
- if m.Memory != nil {
- l = m.Memory.Size()
- n += 1 + l + sovMetrics(uint64(l))
- }
- if m.Rdma != nil {
- l = m.Rdma.Size()
- n += 1 + l + sovMetrics(uint64(l))
- }
- if m.Io != nil {
- l = m.Io.Size()
- n += 1 + l + sovMetrics(uint64(l))
- }
- if len(m.Hugetlb) > 0 {
- for _, e := range m.Hugetlb {
- l = e.Size()
- n += 1 + l + sovMetrics(uint64(l))
- }
- }
- if m.MemoryEvents != nil {
- l = m.MemoryEvents.Size()
- n += 1 + l + sovMetrics(uint64(l))
- }
- if m.XXX_unrecognized != nil {
- n += len(m.XXX_unrecognized)
- }
- return n
-}
-
-func (m *PidsStat) Size() (n int) {
- if m == nil {
- return 0
- }
- var l int
- _ = l
- if m.Current != 0 {
- n += 1 + sovMetrics(uint64(m.Current))
- }
- if m.Limit != 0 {
- n += 1 + sovMetrics(uint64(m.Limit))
- }
- if m.XXX_unrecognized != nil {
- n += len(m.XXX_unrecognized)
- }
- return n
-}
-
-func (m *CPUStat) Size() (n int) {
- if m == nil {
- return 0
- }
- var l int
- _ = l
- if m.UsageUsec != 0 {
- n += 1 + sovMetrics(uint64(m.UsageUsec))
- }
- if m.UserUsec != 0 {
- n += 1 + sovMetrics(uint64(m.UserUsec))
- }
- if m.SystemUsec != 0 {
- n += 1 + sovMetrics(uint64(m.SystemUsec))
- }
- if m.NrPeriods != 0 {
- n += 1 + sovMetrics(uint64(m.NrPeriods))
- }
- if m.NrThrottled != 0 {
- n += 1 + sovMetrics(uint64(m.NrThrottled))
- }
- if m.ThrottledUsec != 0 {
- n += 1 + sovMetrics(uint64(m.ThrottledUsec))
- }
- if m.XXX_unrecognized != nil {
- n += len(m.XXX_unrecognized)
- }
- return n
-}
-
-func (m *MemoryStat) Size() (n int) {
- if m == nil {
- return 0
- }
- var l int
- _ = l
- if m.Anon != 0 {
- n += 1 + sovMetrics(uint64(m.Anon))
- }
- if m.File != 0 {
- n += 1 + sovMetrics(uint64(m.File))
- }
- if m.KernelStack != 0 {
- n += 1 + sovMetrics(uint64(m.KernelStack))
- }
- if m.Slab != 0 {
- n += 1 + sovMetrics(uint64(m.Slab))
- }
- if m.Sock != 0 {
- n += 1 + sovMetrics(uint64(m.Sock))
- }
- if m.Shmem != 0 {
- n += 1 + sovMetrics(uint64(m.Shmem))
- }
- if m.FileMapped != 0 {
- n += 1 + sovMetrics(uint64(m.FileMapped))
- }
- if m.FileDirty != 0 {
- n += 1 + sovMetrics(uint64(m.FileDirty))
- }
- if m.FileWriteback != 0 {
- n += 1 + sovMetrics(uint64(m.FileWriteback))
- }
- if m.AnonThp != 0 {
- n += 1 + sovMetrics(uint64(m.AnonThp))
- }
- if m.InactiveAnon != 0 {
- n += 1 + sovMetrics(uint64(m.InactiveAnon))
- }
- if m.ActiveAnon != 0 {
- n += 1 + sovMetrics(uint64(m.ActiveAnon))
- }
- if m.InactiveFile != 0 {
- n += 1 + sovMetrics(uint64(m.InactiveFile))
- }
- if m.ActiveFile != 0 {
- n += 1 + sovMetrics(uint64(m.ActiveFile))
- }
- if m.Unevictable != 0 {
- n += 1 + sovMetrics(uint64(m.Unevictable))
- }
- if m.SlabReclaimable != 0 {
- n += 2 + sovMetrics(uint64(m.SlabReclaimable))
- }
- if m.SlabUnreclaimable != 0 {
- n += 2 + sovMetrics(uint64(m.SlabUnreclaimable))
- }
- if m.Pgfault != 0 {
- n += 2 + sovMetrics(uint64(m.Pgfault))
- }
- if m.Pgmajfault != 0 {
- n += 2 + sovMetrics(uint64(m.Pgmajfault))
- }
- if m.WorkingsetRefault != 0 {
- n += 2 + sovMetrics(uint64(m.WorkingsetRefault))
- }
- if m.WorkingsetActivate != 0 {
- n += 2 + sovMetrics(uint64(m.WorkingsetActivate))
- }
- if m.WorkingsetNodereclaim != 0 {
- n += 2 + sovMetrics(uint64(m.WorkingsetNodereclaim))
- }
- if m.Pgrefill != 0 {
- n += 2 + sovMetrics(uint64(m.Pgrefill))
- }
- if m.Pgscan != 0 {
- n += 2 + sovMetrics(uint64(m.Pgscan))
- }
- if m.Pgsteal != 0 {
- n += 2 + sovMetrics(uint64(m.Pgsteal))
- }
- if m.Pgactivate != 0 {
- n += 2 + sovMetrics(uint64(m.Pgactivate))
- }
- if m.Pgdeactivate != 0 {
- n += 2 + sovMetrics(uint64(m.Pgdeactivate))
- }
- if m.Pglazyfree != 0 {
- n += 2 + sovMetrics(uint64(m.Pglazyfree))
- }
- if m.Pglazyfreed != 0 {
- n += 2 + sovMetrics(uint64(m.Pglazyfreed))
- }
- if m.ThpFaultAlloc != 0 {
- n += 2 + sovMetrics(uint64(m.ThpFaultAlloc))
- }
- if m.ThpCollapseAlloc != 0 {
- n += 2 + sovMetrics(uint64(m.ThpCollapseAlloc))
- }
- if m.Usage != 0 {
- n += 2 + sovMetrics(uint64(m.Usage))
- }
- if m.UsageLimit != 0 {
- n += 2 + sovMetrics(uint64(m.UsageLimit))
- }
- if m.SwapUsage != 0 {
- n += 2 + sovMetrics(uint64(m.SwapUsage))
- }
- if m.SwapLimit != 0 {
- n += 2 + sovMetrics(uint64(m.SwapLimit))
- }
- if m.XXX_unrecognized != nil {
- n += len(m.XXX_unrecognized)
- }
- return n
-}
-
-func (m *MemoryEvents) Size() (n int) {
- if m == nil {
- return 0
- }
- var l int
- _ = l
- if m.Low != 0 {
- n += 1 + sovMetrics(uint64(m.Low))
- }
- if m.High != 0 {
- n += 1 + sovMetrics(uint64(m.High))
- }
- if m.Max != 0 {
- n += 1 + sovMetrics(uint64(m.Max))
- }
- if m.Oom != 0 {
- n += 1 + sovMetrics(uint64(m.Oom))
- }
- if m.OomKill != 0 {
- n += 1 + sovMetrics(uint64(m.OomKill))
- }
- if m.XXX_unrecognized != nil {
- n += len(m.XXX_unrecognized)
- }
- return n
-}
-
-func (m *RdmaStat) Size() (n int) {
- if m == nil {
- return 0
- }
- var l int
- _ = l
- if len(m.Current) > 0 {
- for _, e := range m.Current {
- l = e.Size()
- n += 1 + l + sovMetrics(uint64(l))
- }
- }
- if len(m.Limit) > 0 {
- for _, e := range m.Limit {
- l = e.Size()
- n += 1 + l + sovMetrics(uint64(l))
- }
- }
- if m.XXX_unrecognized != nil {
- n += len(m.XXX_unrecognized)
- }
- return n
-}
-
-func (m *RdmaEntry) Size() (n int) {
- if m == nil {
- return 0
- }
- var l int
- _ = l
- l = len(m.Device)
- if l > 0 {
- n += 1 + l + sovMetrics(uint64(l))
- }
- if m.HcaHandles != 0 {
- n += 1 + sovMetrics(uint64(m.HcaHandles))
- }
- if m.HcaObjects != 0 {
- n += 1 + sovMetrics(uint64(m.HcaObjects))
- }
- if m.XXX_unrecognized != nil {
- n += len(m.XXX_unrecognized)
- }
- return n
-}
-
-func (m *IOStat) Size() (n int) {
- if m == nil {
- return 0
- }
- var l int
- _ = l
- if len(m.Usage) > 0 {
- for _, e := range m.Usage {
- l = e.Size()
- n += 1 + l + sovMetrics(uint64(l))
- }
- }
- if m.XXX_unrecognized != nil {
- n += len(m.XXX_unrecognized)
- }
- return n
-}
-
-func (m *IOEntry) Size() (n int) {
- if m == nil {
- return 0
- }
- var l int
- _ = l
- if m.Major != 0 {
- n += 1 + sovMetrics(uint64(m.Major))
- }
- if m.Minor != 0 {
- n += 1 + sovMetrics(uint64(m.Minor))
- }
- if m.Rbytes != 0 {
- n += 1 + sovMetrics(uint64(m.Rbytes))
- }
- if m.Wbytes != 0 {
- n += 1 + sovMetrics(uint64(m.Wbytes))
- }
- if m.Rios != 0 {
- n += 1 + sovMetrics(uint64(m.Rios))
- }
- if m.Wios != 0 {
- n += 1 + sovMetrics(uint64(m.Wios))
- }
- if m.XXX_unrecognized != nil {
- n += len(m.XXX_unrecognized)
- }
- return n
-}
-
-func (m *HugeTlbStat) Size() (n int) {
- if m == nil {
- return 0
- }
- var l int
- _ = l
- if m.Current != 0 {
- n += 1 + sovMetrics(uint64(m.Current))
- }
- if m.Max != 0 {
- n += 1 + sovMetrics(uint64(m.Max))
- }
- l = len(m.Pagesize)
- if l > 0 {
- n += 1 + l + sovMetrics(uint64(l))
- }
- if m.XXX_unrecognized != nil {
- n += len(m.XXX_unrecognized)
- }
- return n
-}
-
-func sovMetrics(x uint64) (n int) {
- return (math_bits.Len64(x|1) + 6) / 7
-}
-func sozMetrics(x uint64) (n int) {
- return sovMetrics(uint64((x << 1) ^ uint64((int64(x) >> 63))))
-}
-func (this *Metrics) String() string {
- if this == nil {
- return "nil"
- }
- repeatedStringForHugetlb := "[]*HugeTlbStat{"
- for _, f := range this.Hugetlb {
- repeatedStringForHugetlb += strings.Replace(f.String(), "HugeTlbStat", "HugeTlbStat", 1) + ","
- }
- repeatedStringForHugetlb += "}"
- s := strings.Join([]string{`&Metrics{`,
- `Pids:` + strings.Replace(this.Pids.String(), "PidsStat", "PidsStat", 1) + `,`,
- `CPU:` + strings.Replace(this.CPU.String(), "CPUStat", "CPUStat", 1) + `,`,
- `Memory:` + strings.Replace(this.Memory.String(), "MemoryStat", "MemoryStat", 1) + `,`,
- `Rdma:` + strings.Replace(this.Rdma.String(), "RdmaStat", "RdmaStat", 1) + `,`,
- `Io:` + strings.Replace(this.Io.String(), "IOStat", "IOStat", 1) + `,`,
- `Hugetlb:` + repeatedStringForHugetlb + `,`,
- `MemoryEvents:` + strings.Replace(this.MemoryEvents.String(), "MemoryEvents", "MemoryEvents", 1) + `,`,
- `XXX_unrecognized:` + fmt.Sprintf("%v", this.XXX_unrecognized) + `,`,
- `}`,
- }, "")
- return s
-}
-func (this *PidsStat) String() string {
- if this == nil {
- return "nil"
- }
- s := strings.Join([]string{`&PidsStat{`,
- `Current:` + fmt.Sprintf("%v", this.Current) + `,`,
- `Limit:` + fmt.Sprintf("%v", this.Limit) + `,`,
- `XXX_unrecognized:` + fmt.Sprintf("%v", this.XXX_unrecognized) + `,`,
- `}`,
- }, "")
- return s
-}
-func (this *CPUStat) String() string {
- if this == nil {
- return "nil"
- }
- s := strings.Join([]string{`&CPUStat{`,
- `UsageUsec:` + fmt.Sprintf("%v", this.UsageUsec) + `,`,
- `UserUsec:` + fmt.Sprintf("%v", this.UserUsec) + `,`,
- `SystemUsec:` + fmt.Sprintf("%v", this.SystemUsec) + `,`,
- `NrPeriods:` + fmt.Sprintf("%v", this.NrPeriods) + `,`,
- `NrThrottled:` + fmt.Sprintf("%v", this.NrThrottled) + `,`,
- `ThrottledUsec:` + fmt.Sprintf("%v", this.ThrottledUsec) + `,`,
- `XXX_unrecognized:` + fmt.Sprintf("%v", this.XXX_unrecognized) + `,`,
- `}`,
- }, "")
- return s
-}
-func (this *MemoryStat) String() string {
- if this == nil {
- return "nil"
- }
- s := strings.Join([]string{`&MemoryStat{`,
- `Anon:` + fmt.Sprintf("%v", this.Anon) + `,`,
- `File:` + fmt.Sprintf("%v", this.File) + `,`,
- `KernelStack:` + fmt.Sprintf("%v", this.KernelStack) + `,`,
- `Slab:` + fmt.Sprintf("%v", this.Slab) + `,`,
- `Sock:` + fmt.Sprintf("%v", this.Sock) + `,`,
- `Shmem:` + fmt.Sprintf("%v", this.Shmem) + `,`,
- `FileMapped:` + fmt.Sprintf("%v", this.FileMapped) + `,`,
- `FileDirty:` + fmt.Sprintf("%v", this.FileDirty) + `,`,
- `FileWriteback:` + fmt.Sprintf("%v", this.FileWriteback) + `,`,
- `AnonThp:` + fmt.Sprintf("%v", this.AnonThp) + `,`,
- `InactiveAnon:` + fmt.Sprintf("%v", this.InactiveAnon) + `,`,
- `ActiveAnon:` + fmt.Sprintf("%v", this.ActiveAnon) + `,`,
- `InactiveFile:` + fmt.Sprintf("%v", this.InactiveFile) + `,`,
- `ActiveFile:` + fmt.Sprintf("%v", this.ActiveFile) + `,`,
- `Unevictable:` + fmt.Sprintf("%v", this.Unevictable) + `,`,
- `SlabReclaimable:` + fmt.Sprintf("%v", this.SlabReclaimable) + `,`,
- `SlabUnreclaimable:` + fmt.Sprintf("%v", this.SlabUnreclaimable) + `,`,
- `Pgfault:` + fmt.Sprintf("%v", this.Pgfault) + `,`,
- `Pgmajfault:` + fmt.Sprintf("%v", this.Pgmajfault) + `,`,
- `WorkingsetRefault:` + fmt.Sprintf("%v", this.WorkingsetRefault) + `,`,
- `WorkingsetActivate:` + fmt.Sprintf("%v", this.WorkingsetActivate) + `,`,
- `WorkingsetNodereclaim:` + fmt.Sprintf("%v", this.WorkingsetNodereclaim) + `,`,
- `Pgrefill:` + fmt.Sprintf("%v", this.Pgrefill) + `,`,
- `Pgscan:` + fmt.Sprintf("%v", this.Pgscan) + `,`,
- `Pgsteal:` + fmt.Sprintf("%v", this.Pgsteal) + `,`,
- `Pgactivate:` + fmt.Sprintf("%v", this.Pgactivate) + `,`,
- `Pgdeactivate:` + fmt.Sprintf("%v", this.Pgdeactivate) + `,`,
- `Pglazyfree:` + fmt.Sprintf("%v", this.Pglazyfree) + `,`,
- `Pglazyfreed:` + fmt.Sprintf("%v", this.Pglazyfreed) + `,`,
- `ThpFaultAlloc:` + fmt.Sprintf("%v", this.ThpFaultAlloc) + `,`,
- `ThpCollapseAlloc:` + fmt.Sprintf("%v", this.ThpCollapseAlloc) + `,`,
- `Usage:` + fmt.Sprintf("%v", this.Usage) + `,`,
- `UsageLimit:` + fmt.Sprintf("%v", this.UsageLimit) + `,`,
- `SwapUsage:` + fmt.Sprintf("%v", this.SwapUsage) + `,`,
- `SwapLimit:` + fmt.Sprintf("%v", this.SwapLimit) + `,`,
- `XXX_unrecognized:` + fmt.Sprintf("%v", this.XXX_unrecognized) + `,`,
- `}`,
- }, "")
- return s
-}
-func (this *MemoryEvents) String() string {
- if this == nil {
- return "nil"
- }
- s := strings.Join([]string{`&MemoryEvents{`,
- `Low:` + fmt.Sprintf("%v", this.Low) + `,`,
- `High:` + fmt.Sprintf("%v", this.High) + `,`,
- `Max:` + fmt.Sprintf("%v", this.Max) + `,`,
- `Oom:` + fmt.Sprintf("%v", this.Oom) + `,`,
- `OomKill:` + fmt.Sprintf("%v", this.OomKill) + `,`,
- `XXX_unrecognized:` + fmt.Sprintf("%v", this.XXX_unrecognized) + `,`,
- `}`,
- }, "")
- return s
-}
-func (this *RdmaStat) String() string {
- if this == nil {
- return "nil"
- }
- repeatedStringForCurrent := "[]*RdmaEntry{"
- for _, f := range this.Current {
- repeatedStringForCurrent += strings.Replace(f.String(), "RdmaEntry", "RdmaEntry", 1) + ","
- }
- repeatedStringForCurrent += "}"
- repeatedStringForLimit := "[]*RdmaEntry{"
- for _, f := range this.Limit {
- repeatedStringForLimit += strings.Replace(f.String(), "RdmaEntry", "RdmaEntry", 1) + ","
- }
- repeatedStringForLimit += "}"
- s := strings.Join([]string{`&RdmaStat{`,
- `Current:` + repeatedStringForCurrent + `,`,
- `Limit:` + repeatedStringForLimit + `,`,
- `XXX_unrecognized:` + fmt.Sprintf("%v", this.XXX_unrecognized) + `,`,
- `}`,
- }, "")
- return s
-}
-func (this *RdmaEntry) String() string {
- if this == nil {
- return "nil"
- }
- s := strings.Join([]string{`&RdmaEntry{`,
- `Device:` + fmt.Sprintf("%v", this.Device) + `,`,
- `HcaHandles:` + fmt.Sprintf("%v", this.HcaHandles) + `,`,
- `HcaObjects:` + fmt.Sprintf("%v", this.HcaObjects) + `,`,
- `XXX_unrecognized:` + fmt.Sprintf("%v", this.XXX_unrecognized) + `,`,
- `}`,
- }, "")
- return s
-}
-func (this *IOStat) String() string {
- if this == nil {
- return "nil"
- }
- repeatedStringForUsage := "[]*IOEntry{"
- for _, f := range this.Usage {
- repeatedStringForUsage += strings.Replace(f.String(), "IOEntry", "IOEntry", 1) + ","
- }
- repeatedStringForUsage += "}"
- s := strings.Join([]string{`&IOStat{`,
- `Usage:` + repeatedStringForUsage + `,`,
- `XXX_unrecognized:` + fmt.Sprintf("%v", this.XXX_unrecognized) + `,`,
- `}`,
- }, "")
- return s
-}
-func (this *IOEntry) String() string {
- if this == nil {
- return "nil"
- }
- s := strings.Join([]string{`&IOEntry{`,
- `Major:` + fmt.Sprintf("%v", this.Major) + `,`,
- `Minor:` + fmt.Sprintf("%v", this.Minor) + `,`,
- `Rbytes:` + fmt.Sprintf("%v", this.Rbytes) + `,`,
- `Wbytes:` + fmt.Sprintf("%v", this.Wbytes) + `,`,
- `Rios:` + fmt.Sprintf("%v", this.Rios) + `,`,
- `Wios:` + fmt.Sprintf("%v", this.Wios) + `,`,
- `XXX_unrecognized:` + fmt.Sprintf("%v", this.XXX_unrecognized) + `,`,
- `}`,
- }, "")
- return s
-}
-func (this *HugeTlbStat) String() string {
- if this == nil {
- return "nil"
- }
- s := strings.Join([]string{`&HugeTlbStat{`,
- `Current:` + fmt.Sprintf("%v", this.Current) + `,`,
- `Max:` + fmt.Sprintf("%v", this.Max) + `,`,
- `Pagesize:` + fmt.Sprintf("%v", this.Pagesize) + `,`,
- `XXX_unrecognized:` + fmt.Sprintf("%v", this.XXX_unrecognized) + `,`,
- `}`,
- }, "")
- return s
-}
-func valueToStringMetrics(v interface{}) string {
- rv := reflect.ValueOf(v)
- if rv.IsNil() {
- return "nil"
- }
- pv := reflect.Indirect(rv).Interface()
- return fmt.Sprintf("*%v", pv)
-}
-func (m *Metrics) Unmarshal(dAtA []byte) error {
- l := len(dAtA)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- wire |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: Metrics: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: Metrics: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Pids", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- msglen |= int(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthMetrics
- }
- postIndex := iNdEx + msglen
- if postIndex < 0 {
- return ErrInvalidLengthMetrics
- }
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.Pids == nil {
- m.Pids = &PidsStat{}
- }
- if err := m.Pids.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field CPU", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- msglen |= int(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthMetrics
- }
- postIndex := iNdEx + msglen
- if postIndex < 0 {
- return ErrInvalidLengthMetrics
- }
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.CPU == nil {
- m.CPU = &CPUStat{}
- }
- if err := m.CPU.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 4:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Memory", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- msglen |= int(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthMetrics
- }
- postIndex := iNdEx + msglen
- if postIndex < 0 {
- return ErrInvalidLengthMetrics
- }
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.Memory == nil {
- m.Memory = &MemoryStat{}
- }
- if err := m.Memory.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 5:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Rdma", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- msglen |= int(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthMetrics
- }
- postIndex := iNdEx + msglen
- if postIndex < 0 {
- return ErrInvalidLengthMetrics
- }
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.Rdma == nil {
- m.Rdma = &RdmaStat{}
- }
- if err := m.Rdma.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 6:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Io", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- msglen |= int(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthMetrics
- }
- postIndex := iNdEx + msglen
- if postIndex < 0 {
- return ErrInvalidLengthMetrics
- }
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.Io == nil {
- m.Io = &IOStat{}
- }
- if err := m.Io.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 7:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Hugetlb", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- msglen |= int(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthMetrics
- }
- postIndex := iNdEx + msglen
- if postIndex < 0 {
- return ErrInvalidLengthMetrics
- }
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Hugetlb = append(m.Hugetlb, &HugeTlbStat{})
- if err := m.Hugetlb[len(m.Hugetlb)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 8:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field MemoryEvents", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- msglen |= int(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthMetrics
- }
- postIndex := iNdEx + msglen
- if postIndex < 0 {
- return ErrInvalidLengthMetrics
- }
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- if m.MemoryEvents == nil {
- m.MemoryEvents = &MemoryEvents{}
- }
- if err := m.MemoryEvents.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipMetrics(dAtA[iNdEx:])
- if err != nil {
- return err
- }
- if (skippy < 0) || (iNdEx+skippy) < 0 {
- return ErrInvalidLengthMetrics
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...)
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *PidsStat) Unmarshal(dAtA []byte) error {
- l := len(dAtA)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- wire |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: PidsStat: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: PidsStat: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Current", wireType)
- }
- m.Current = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.Current |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 2:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Limit", wireType)
- }
- m.Limit = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.Limit |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- default:
- iNdEx = preIndex
- skippy, err := skipMetrics(dAtA[iNdEx:])
- if err != nil {
- return err
- }
- if (skippy < 0) || (iNdEx+skippy) < 0 {
- return ErrInvalidLengthMetrics
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...)
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *CPUStat) Unmarshal(dAtA []byte) error {
- l := len(dAtA)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- wire |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: CPUStat: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: CPUStat: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field UsageUsec", wireType)
- }
- m.UsageUsec = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.UsageUsec |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 2:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field UserUsec", wireType)
- }
- m.UserUsec = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.UserUsec |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 3:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field SystemUsec", wireType)
- }
- m.SystemUsec = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.SystemUsec |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 4:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field NrPeriods", wireType)
- }
- m.NrPeriods = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.NrPeriods |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 5:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field NrThrottled", wireType)
- }
- m.NrThrottled = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.NrThrottled |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 6:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field ThrottledUsec", wireType)
- }
- m.ThrottledUsec = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.ThrottledUsec |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- default:
- iNdEx = preIndex
- skippy, err := skipMetrics(dAtA[iNdEx:])
- if err != nil {
- return err
- }
- if (skippy < 0) || (iNdEx+skippy) < 0 {
- return ErrInvalidLengthMetrics
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...)
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *MemoryStat) Unmarshal(dAtA []byte) error {
- l := len(dAtA)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- wire |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: MemoryStat: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: MemoryStat: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Anon", wireType)
- }
- m.Anon = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.Anon |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 2:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field File", wireType)
- }
- m.File = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.File |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 3:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field KernelStack", wireType)
- }
- m.KernelStack = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.KernelStack |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 4:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Slab", wireType)
- }
- m.Slab = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.Slab |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 5:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Sock", wireType)
- }
- m.Sock = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.Sock |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 6:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Shmem", wireType)
- }
- m.Shmem = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.Shmem |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 7:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field FileMapped", wireType)
- }
- m.FileMapped = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.FileMapped |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 8:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field FileDirty", wireType)
- }
- m.FileDirty = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.FileDirty |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 9:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field FileWriteback", wireType)
- }
- m.FileWriteback = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.FileWriteback |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 10:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field AnonThp", wireType)
- }
- m.AnonThp = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.AnonThp |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 11:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field InactiveAnon", wireType)
- }
- m.InactiveAnon = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.InactiveAnon |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 12:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field ActiveAnon", wireType)
- }
- m.ActiveAnon = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.ActiveAnon |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 13:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field InactiveFile", wireType)
- }
- m.InactiveFile = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.InactiveFile |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 14:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field ActiveFile", wireType)
- }
- m.ActiveFile = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.ActiveFile |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 15:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Unevictable", wireType)
- }
- m.Unevictable = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.Unevictable |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 16:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field SlabReclaimable", wireType)
- }
- m.SlabReclaimable = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.SlabReclaimable |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 17:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field SlabUnreclaimable", wireType)
- }
- m.SlabUnreclaimable = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.SlabUnreclaimable |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 18:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Pgfault", wireType)
- }
- m.Pgfault = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.Pgfault |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 19:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Pgmajfault", wireType)
- }
- m.Pgmajfault = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.Pgmajfault |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 20:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field WorkingsetRefault", wireType)
- }
- m.WorkingsetRefault = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.WorkingsetRefault |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 21:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field WorkingsetActivate", wireType)
- }
- m.WorkingsetActivate = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.WorkingsetActivate |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 22:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field WorkingsetNodereclaim", wireType)
- }
- m.WorkingsetNodereclaim = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.WorkingsetNodereclaim |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 23:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Pgrefill", wireType)
- }
- m.Pgrefill = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.Pgrefill |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 24:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Pgscan", wireType)
- }
- m.Pgscan = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.Pgscan |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 25:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Pgsteal", wireType)
- }
- m.Pgsteal = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.Pgsteal |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 26:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Pgactivate", wireType)
- }
- m.Pgactivate = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.Pgactivate |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 27:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Pgdeactivate", wireType)
- }
- m.Pgdeactivate = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.Pgdeactivate |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 28:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Pglazyfree", wireType)
- }
- m.Pglazyfree = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.Pglazyfree |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 29:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Pglazyfreed", wireType)
- }
- m.Pglazyfreed = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.Pglazyfreed |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 30:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field ThpFaultAlloc", wireType)
- }
- m.ThpFaultAlloc = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.ThpFaultAlloc |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 31:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field ThpCollapseAlloc", wireType)
- }
- m.ThpCollapseAlloc = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.ThpCollapseAlloc |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 32:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Usage", wireType)
- }
- m.Usage = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.Usage |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 33:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field UsageLimit", wireType)
- }
- m.UsageLimit = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.UsageLimit |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 34:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field SwapUsage", wireType)
- }
- m.SwapUsage = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.SwapUsage |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 35:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field SwapLimit", wireType)
- }
- m.SwapLimit = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.SwapLimit |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- default:
- iNdEx = preIndex
- skippy, err := skipMetrics(dAtA[iNdEx:])
- if err != nil {
- return err
- }
- if (skippy < 0) || (iNdEx+skippy) < 0 {
- return ErrInvalidLengthMetrics
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...)
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *MemoryEvents) Unmarshal(dAtA []byte) error {
- l := len(dAtA)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- wire |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: MemoryEvents: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: MemoryEvents: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Low", wireType)
- }
- m.Low = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.Low |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 2:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field High", wireType)
- }
- m.High = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.High |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 3:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Max", wireType)
- }
- m.Max = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.Max |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 4:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Oom", wireType)
- }
- m.Oom = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.Oom |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 5:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field OomKill", wireType)
- }
- m.OomKill = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.OomKill |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- default:
- iNdEx = preIndex
- skippy, err := skipMetrics(dAtA[iNdEx:])
- if err != nil {
- return err
- }
- if (skippy < 0) || (iNdEx+skippy) < 0 {
- return ErrInvalidLengthMetrics
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...)
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *RdmaStat) Unmarshal(dAtA []byte) error {
- l := len(dAtA)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- wire |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: RdmaStat: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: RdmaStat: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Current", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- msglen |= int(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthMetrics
- }
- postIndex := iNdEx + msglen
- if postIndex < 0 {
- return ErrInvalidLengthMetrics
- }
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Current = append(m.Current, &RdmaEntry{})
- if err := m.Current[len(m.Current)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- case 2:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Limit", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- msglen |= int(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthMetrics
- }
- postIndex := iNdEx + msglen
- if postIndex < 0 {
- return ErrInvalidLengthMetrics
- }
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Limit = append(m.Limit, &RdmaEntry{})
- if err := m.Limit[len(m.Limit)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipMetrics(dAtA[iNdEx:])
- if err != nil {
- return err
- }
- if (skippy < 0) || (iNdEx+skippy) < 0 {
- return ErrInvalidLengthMetrics
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...)
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *RdmaEntry) Unmarshal(dAtA []byte) error {
- l := len(dAtA)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- wire |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: RdmaEntry: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: RdmaEntry: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Device", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- stringLen |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthMetrics
- }
- postIndex := iNdEx + intStringLen
- if postIndex < 0 {
- return ErrInvalidLengthMetrics
- }
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Device = string(dAtA[iNdEx:postIndex])
- iNdEx = postIndex
- case 2:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field HcaHandles", wireType)
- }
- m.HcaHandles = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.HcaHandles |= uint32(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 3:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field HcaObjects", wireType)
- }
- m.HcaObjects = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.HcaObjects |= uint32(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- default:
- iNdEx = preIndex
- skippy, err := skipMetrics(dAtA[iNdEx:])
- if err != nil {
- return err
- }
- if (skippy < 0) || (iNdEx+skippy) < 0 {
- return ErrInvalidLengthMetrics
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...)
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *IOStat) Unmarshal(dAtA []byte) error {
- l := len(dAtA)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- wire |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: IOStat: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: IOStat: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Usage", wireType)
- }
- var msglen int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- msglen |= int(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if msglen < 0 {
- return ErrInvalidLengthMetrics
- }
- postIndex := iNdEx + msglen
- if postIndex < 0 {
- return ErrInvalidLengthMetrics
- }
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Usage = append(m.Usage, &IOEntry{})
- if err := m.Usage[len(m.Usage)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
- return err
- }
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipMetrics(dAtA[iNdEx:])
- if err != nil {
- return err
- }
- if (skippy < 0) || (iNdEx+skippy) < 0 {
- return ErrInvalidLengthMetrics
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...)
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *IOEntry) Unmarshal(dAtA []byte) error {
- l := len(dAtA)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- wire |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: IOEntry: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: IOEntry: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Major", wireType)
- }
- m.Major = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.Major |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 2:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Minor", wireType)
- }
- m.Minor = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.Minor |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 3:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Rbytes", wireType)
- }
- m.Rbytes = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.Rbytes |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 4:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Wbytes", wireType)
- }
- m.Wbytes = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.Wbytes |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 5:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Rios", wireType)
- }
- m.Rios = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.Rios |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 6:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Wios", wireType)
- }
- m.Wios = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.Wios |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- default:
- iNdEx = preIndex
- skippy, err := skipMetrics(dAtA[iNdEx:])
- if err != nil {
- return err
- }
- if (skippy < 0) || (iNdEx+skippy) < 0 {
- return ErrInvalidLengthMetrics
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...)
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func (m *HugeTlbStat) Unmarshal(dAtA []byte) error {
- l := len(dAtA)
- iNdEx := 0
- for iNdEx < l {
- preIndex := iNdEx
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- wire |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- fieldNum := int32(wire >> 3)
- wireType := int(wire & 0x7)
- if wireType == 4 {
- return fmt.Errorf("proto: HugeTlbStat: wiretype end group for non-group")
- }
- if fieldNum <= 0 {
- return fmt.Errorf("proto: HugeTlbStat: illegal tag %d (wire type %d)", fieldNum, wire)
- }
- switch fieldNum {
- case 1:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Current", wireType)
- }
- m.Current = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.Current |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 2:
- if wireType != 0 {
- return fmt.Errorf("proto: wrong wireType = %d for field Max", wireType)
- }
- m.Max = 0
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- m.Max |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- case 3:
- if wireType != 2 {
- return fmt.Errorf("proto: wrong wireType = %d for field Pagesize", wireType)
- }
- var stringLen uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- stringLen |= uint64(b&0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- intStringLen := int(stringLen)
- if intStringLen < 0 {
- return ErrInvalidLengthMetrics
- }
- postIndex := iNdEx + intStringLen
- if postIndex < 0 {
- return ErrInvalidLengthMetrics
- }
- if postIndex > l {
- return io.ErrUnexpectedEOF
- }
- m.Pagesize = string(dAtA[iNdEx:postIndex])
- iNdEx = postIndex
- default:
- iNdEx = preIndex
- skippy, err := skipMetrics(dAtA[iNdEx:])
- if err != nil {
- return err
- }
- if (skippy < 0) || (iNdEx+skippy) < 0 {
- return ErrInvalidLengthMetrics
- }
- if (iNdEx + skippy) > l {
- return io.ErrUnexpectedEOF
- }
- m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...)
- iNdEx += skippy
- }
- }
-
- if iNdEx > l {
- return io.ErrUnexpectedEOF
- }
- return nil
-}
-func skipMetrics(dAtA []byte) (n int, err error) {
- l := len(dAtA)
- iNdEx := 0
- depth := 0
- for iNdEx < l {
- var wire uint64
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return 0, ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return 0, io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- wire |= (uint64(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- wireType := int(wire & 0x7)
- switch wireType {
- case 0:
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return 0, ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return 0, io.ErrUnexpectedEOF
- }
- iNdEx++
- if dAtA[iNdEx-1] < 0x80 {
- break
- }
- }
- case 1:
- iNdEx += 8
- case 2:
- var length int
- for shift := uint(0); ; shift += 7 {
- if shift >= 64 {
- return 0, ErrIntOverflowMetrics
- }
- if iNdEx >= l {
- return 0, io.ErrUnexpectedEOF
- }
- b := dAtA[iNdEx]
- iNdEx++
- length |= (int(b) & 0x7F) << shift
- if b < 0x80 {
- break
- }
- }
- if length < 0 {
- return 0, ErrInvalidLengthMetrics
- }
- iNdEx += length
- case 3:
- depth++
- case 4:
- if depth == 0 {
- return 0, ErrUnexpectedEndOfGroupMetrics
- }
- depth--
- case 5:
- iNdEx += 4
- default:
- return 0, fmt.Errorf("proto: illegal wireType %d", wireType)
- }
- if iNdEx < 0 {
- return 0, ErrInvalidLengthMetrics
- }
- if depth == 0 {
- return iNdEx, nil
- }
- }
- return 0, io.ErrUnexpectedEOF
-}
-
-var (
- ErrInvalidLengthMetrics = fmt.Errorf("proto: negative length found during unmarshaling")
- ErrIntOverflowMetrics = fmt.Errorf("proto: integer overflow")
- ErrUnexpectedEndOfGroupMetrics = fmt.Errorf("proto: unexpected end of group")
-)
diff --git a/vendor/github.com/containerd/cgroups/.gitignore b/vendor/github.com/containerd/cgroups/v3/.gitignore
index 3465c14cf..3465c14cf 100644
--- a/vendor/github.com/containerd/cgroups/.gitignore
+++ b/vendor/github.com/containerd/cgroups/v3/.gitignore
diff --git a/vendor/github.com/containerd/cgroups/LICENSE b/vendor/github.com/containerd/cgroups/v3/LICENSE
index 261eeb9e9..261eeb9e9 100644
--- a/vendor/github.com/containerd/cgroups/LICENSE
+++ b/vendor/github.com/containerd/cgroups/v3/LICENSE
diff --git a/vendor/github.com/containerd/cgroups/Makefile b/vendor/github.com/containerd/cgroups/v3/Makefile
index 19e660756..088572980 100644
--- a/vendor/github.com/containerd/cgroups/Makefile
+++ b/vendor/github.com/containerd/cgroups/v3/Makefile
@@ -22,3 +22,5 @@ cgutil:
proto:
protobuild --quiet ${PACKAGES}
+ # Keep them Go-idiomatic and backward-compatible with the gogo/protobuf era.
+ go-fix-acronym -w -a '(Cpu|Tcp|Rss)' $(shell find cgroup1/stats/ cgroup2/stats/ -name '*.pb.go')
diff --git a/vendor/github.com/containerd/cgroups/v3/Protobuild.toml b/vendor/github.com/containerd/cgroups/v3/Protobuild.toml
new file mode 100644
index 000000000..cf94b1c1a
--- /dev/null
+++ b/vendor/github.com/containerd/cgroups/v3/Protobuild.toml
@@ -0,0 +1,31 @@
+version = "2"
+generators = ["go"]
+
+# Control protoc include paths. Below are usually some good defaults, but feel
+# free to try it without them if it works for your project.
+[includes]
+ # Include paths that will be added before all others. Typically, you want to
+ # treat the root of the project as an include, but this may not be necessary.
+ # before = ["."]
+
+ # Paths that will be added untouched to the end of the includes. We use
+ # `/usr/local/include` to pickup the common install location of protobuf.
+ # This is the default.
+ after = ["/usr/local/include", "/usr/include"]
+
+# Aggregrate the API descriptors to lock down API changes.
+[[descriptors]]
+prefix = "github.com/containerd/cgroups/cgroup1/stats"
+target = "cgroup1/stats/metrics.pb.txt"
+ignore_files = [
+ "google/protobuf/descriptor.proto",
+]
+[[descriptors]]
+prefix = "github.com/containerd/cgroups/cgroup2/stats"
+target = "cgroup2/stats/metrics.pb.txt"
+ignore_files = [
+ "google/protobuf/descriptor.proto",
+]
+
+[parameters.go]
+paths = "source_relative"
diff --git a/vendor/github.com/containerd/cgroups/README.md b/vendor/github.com/containerd/cgroups/v3/README.md
index eccb9d984..a90b87266 100644
--- a/vendor/github.com/containerd/cgroups/README.md
+++ b/vendor/github.com/containerd/cgroups/v3/README.md
@@ -9,7 +9,7 @@ Go package for creating, managing, inspecting, and destroying cgroups.
The resources format for settings on the cgroup uses the OCI runtime-spec found
[here](https://github.com/opencontainers/runtime-spec).
-## Examples
+## Examples (v1)
### Create a new cgroup
@@ -25,7 +25,7 @@ uses the v1 implementation of cgroups.
```go
shares := uint64(100)
-control, err := cgroups.New(cgroups.V1, cgroups.StaticPath("/test"), &specs.LinuxResources{
+control, err := cgroup1.New(cgroup1.StaticPath("/test"), &specs.LinuxResources{
CPU: &specs.LinuxCPU{
Shares: &shares,
},
@@ -37,7 +37,7 @@ defer control.Delete()
```go
-control, err := cgroups.New(cgroups.Systemd, cgroups.Slice("system.slice", "runc-test"), &specs.LinuxResources{
+control, err := cgroup1.New(cgroup1.Systemd, cgroup1.Slice("system.slice", "runc-test"), &specs.LinuxResources{
CPU: &specs.CPU{
Shares: &shares,
},
@@ -48,17 +48,17 @@ control, err := cgroups.New(cgroups.Systemd, cgroups.Slice("system.slice", "runc
### Load an existing cgroup
```go
-control, err = cgroups.Load(cgroups.V1, cgroups.StaticPath("/test"))
+control, err = cgroup1.Load(cgroup1.Default, cgroups.StaticPath("/test"))
```
### Add a process to the cgroup
```go
-if err := control.Add(cgroups.Process{Pid:1234}); err != nil {
+if err := control.Add(cgroup1.Process{Pid:1234}); err != nil {
}
```
-### Update the cgroup
+### Update the cgroup
To update the resources applied in the cgroup
@@ -84,7 +84,7 @@ if err := control.Thaw(); err != nil {
### List all processes in the cgroup or recursively
```go
-processes, err := control.Processes(cgroups.Devices, recursive)
+processes, err := control.Processes(cgroup1.Devices, recursive)
```
### Get Stats on the cgroup
@@ -95,7 +95,7 @@ stats, err := control.Stat()
By adding `cgroups.IgnoreNotExist` all non-existent files will be ignored, e.g. swap memory stats without swap enabled
```go
-stats, err := control.Stat(cgroups.IgnoreNotExist)
+stats, err := control.Stat(cgroup1.IgnoreNotExist)
```
### Move process across cgroups
@@ -117,22 +117,90 @@ subCgroup, err := control.New("child", resources)
This allows you to get notified by an eventfd for v1 memory cgroups events.
```go
-event := cgroups.MemoryThresholdEvent(50 * 1024 * 1024, false)
+event := cgroup1.MemoryThresholdEvent(50 * 1024 * 1024, false)
efd, err := control.RegisterMemoryEvent(event)
```
```go
-event := cgroups.MemoryPressureEvent(cgroups.MediumPressure, cgroups.DefaultMode)
+event := cgroup1.MemoryPressureEvent(cgroup1.MediumPressure, cgroup1.DefaultMode)
efd, err := control.RegisterMemoryEvent(event)
```
```go
efd, err := control.OOMEventFD()
// or by using RegisterMemoryEvent
-event := cgroups.OOMEvent()
+event := cgroup1.OOMEvent()
efd, err := control.RegisterMemoryEvent(event)
```
+## Examples (v2/unified)
+
+### Check that the current system is running cgroups v2
+
+```go
+var cgroupV2 bool
+if cgroups.Mode() == cgroups.Unified {
+ cgroupV2 = true
+}
+```
+
+### Create a new cgroup
+
+This creates a new systemd v2 cgroup slice. Systemd slices consider ["-" a special character](https://www.freedesktop.org/software/systemd/man/systemd.slice.html),
+so the resulting slice would be located here on disk:
+
+* /sys/fs/cgroup/my.slice/my-cgroup.slice/my-cgroup-abc.slice
+
+```go
+import (
+ "github.com/containerd/cgroups/v3/cgroup2"
+ specs "github.com/opencontainers/runtime-spec/specs-go"
+)
+
+res := cgroup2.Resources{}
+// dummy PID of -1 is used for creating a "general slice" to be used as a parent cgroup.
+// see https://github.com/containerd/cgroups/blob/1df78138f1e1e6ee593db155c6b369466f577651/v2/manager.go#L732-L735
+m, err := cgroup2.NewSystemd("/", "my-cgroup-abc.slice", -1, &res)
+if err != nil {
+ return err
+}
+```
+
+### Load an existing cgroup
+
+```go
+m, err := cgroup2.LoadSystemd("/", "my-cgroup-abc.slice")
+if err != nil {
+ return err
+}
+```
+
+### Delete a cgroup
+
+```go
+m, err := cgroup2.LoadSystemd("/", "my-cgroup-abc.slice")
+if err != nil {
+ return err
+}
+err = m.DeleteSystemd()
+if err != nil {
+ return err
+}
+```
+
+### Kill all processes in a cgroup
+
+```go
+m, err := cgroup2.LoadSystemd("/", "my-cgroup-abc.slice")
+if err != nil {
+ return err
+}
+err = m.Kill()
+if err != nil {
+ return err
+}
+```
+
### Attention
All static path should not include `/sys/fs/cgroup/` prefix, it should start with your own cgroups name
diff --git a/vendor/github.com/containerd/cgroups/blkio.go b/vendor/github.com/containerd/cgroups/v3/cgroup1/blkio.go
index f59c75bb5..9ee96e139 100644
--- a/vendor/github.com/containerd/cgroups/blkio.go
+++ b/vendor/github.com/containerd/cgroups/v3/cgroup1/blkio.go
@@ -14,7 +14,7 @@
limitations under the License.
*/
-package cgroups
+package cgroup1
import (
"bufio"
@@ -25,7 +25,8 @@ import (
"strconv"
"strings"
- v1 "github.com/containerd/cgroups/stats/v1"
+ v1 "github.com/containerd/cgroups/v3/cgroup1/stats"
+
specs "github.com/opencontainers/runtime-spec/specs-go"
)
@@ -71,7 +72,7 @@ func (b *blkioController) Create(path string, resources *specs.LinuxResources) e
}
for _, t := range createBlkioSettings(resources.BlockIO) {
if t.value != nil {
- if err := retryingWriteFile(
+ if err := os.WriteFile(
filepath.Join(b.Path(path), "blkio."+t.name),
t.format(t.value),
defaultFilePerm,
diff --git a/vendor/github.com/containerd/cgroups/cgroup.go b/vendor/github.com/containerd/cgroups/v3/cgroup1/cgroup.go
index 0fab1cecf..2a31b8041 100644
--- a/vendor/github.com/containerd/cgroups/cgroup.go
+++ b/vendor/github.com/containerd/cgroups/v3/cgroup1/cgroup.go
@@ -14,31 +14,34 @@
limitations under the License.
*/
-package cgroups
+package cgroup1
import (
"errors"
"fmt"
+ "io/fs"
"os"
"path/filepath"
"strconv"
"strings"
"sync"
+ "syscall"
+ "time"
- v1 "github.com/containerd/cgroups/stats/v1"
+ v1 "github.com/containerd/cgroups/v3/cgroup1/stats"
"github.com/opencontainers/runtime-spec/specs-go"
)
// New returns a new control via the cgroup cgroups interface
-func New(hierarchy Hierarchy, path Path, resources *specs.LinuxResources, opts ...InitOpts) (Cgroup, error) {
+func New(path Path, resources *specs.LinuxResources, opts ...InitOpts) (Cgroup, error) {
config := newInitConfig()
for _, o := range opts {
if err := o(config); err != nil {
return nil, err
}
}
- subsystems, err := hierarchy()
+ subsystems, err := config.hiearchy()
if err != nil {
return nil, err
}
@@ -68,7 +71,7 @@ func New(hierarchy Hierarchy, path Path, resources *specs.LinuxResources, opts .
// Load will load an existing cgroup and allow it to be controlled
// All static path should not include `/sys/fs/cgroup/` prefix, it should start with your own cgroups name
-func Load(hierarchy Hierarchy, path Path, opts ...InitOpts) (Cgroup, error) {
+func Load(path Path, opts ...InitOpts) (Cgroup, error) {
config := newInitConfig()
for _, o := range opts {
if err := o(config); err != nil {
@@ -76,7 +79,7 @@ func Load(hierarchy Hierarchy, path Path, opts ...InitOpts) (Cgroup, error) {
}
}
var activeSubsystems []Subsystem
- subsystems, err := hierarchy()
+ subsystems, err := config.hiearchy()
if err != nil {
return nil, err
}
@@ -84,7 +87,7 @@ func Load(hierarchy Hierarchy, path Path, opts ...InitOpts) (Cgroup, error) {
for _, s := range pathers(subsystems) {
p, err := path(s.Name())
if err != nil {
- if errors.Is(err, os.ErrNotExist) {
+ if errors.Is(err, os.ErrNotExist) {
return nil, ErrCgroupDeleted
}
if err == ErrControllerNotActive {
@@ -193,6 +196,31 @@ func (c *cgroup) AddTask(process Process, subsystems ...Name) error {
return c.add(process, cgroupTasks, subsystems...)
}
+// writeCgroupsProcs writes to the file, but retries on EINVAL.
+func writeCgroupProcs(path string, content []byte, perm fs.FileMode) error {
+ f, err := os.OpenFile(path, os.O_CREATE|os.O_WRONLY, perm)
+ if err != nil {
+ return err
+ }
+ defer f.Close()
+
+ for i := 0; i < 5; i++ {
+ _, err = f.Write(content)
+ if err == nil {
+ return nil
+ }
+ // If the process's associated task's state is TASK_NEW, the kernel
+ // returns EINVAL. The function will retry on the error like runc.
+ // https://github.com/torvalds/linux/blob/v6.0/kernel/sched/core.c#L10308-L10337
+ // https://github.com/opencontainers/runc/pull/1950
+ if !errors.Is(err, syscall.EINVAL) {
+ return err
+ }
+ time.Sleep(30 * time.Millisecond)
+ }
+ return err
+}
+
func (c *cgroup) add(process Process, pType procType, subsystems ...Name) error {
if process.Pid <= 0 {
return ErrInvalidPid
@@ -207,7 +235,7 @@ func (c *cgroup) add(process Process, pType procType, subsystems ...Name) error
if err != nil {
return err
}
- err = retryingWriteFile(
+ err = writeCgroupProcs(
filepath.Join(s.Path(p), pType),
[]byte(strconv.Itoa(process.Pid)),
defaultFilePerm,
@@ -228,6 +256,15 @@ func (c *cgroup) Delete() error {
}
var errs []string
for _, s := range c.subsystems {
+ // kernel prevents cgroups with running process from being removed, check the tree is empty
+ procs, err := c.processes(s.Name(), true, cgroupProcs)
+ if err != nil {
+ return err
+ }
+ if len(procs) > 0 {
+ errs = append(errs, fmt.Sprintf("%s (contains running processes)", string(s.Name())))
+ continue
+ }
if d, ok := s.(deleter); ok {
sp, err := c.path(s.Name())
if err != nil {
@@ -247,6 +284,7 @@ func (c *cgroup) Delete() error {
if err := remove(path); err != nil {
errs = append(errs, path)
}
+ continue
}
}
if len(errs) > 0 {
diff --git a/vendor/github.com/containerd/cgroups/control.go b/vendor/github.com/containerd/cgroups/v3/cgroup1/control.go
index 5fcaac6d0..6cbf5323e 100644
--- a/vendor/github.com/containerd/cgroups/control.go
+++ b/vendor/github.com/containerd/cgroups/v3/cgroup1/control.go
@@ -14,12 +14,12 @@
limitations under the License.
*/
-package cgroups
+package cgroup1
import (
"os"
- v1 "github.com/containerd/cgroups/stats/v1"
+ v1 "github.com/containerd/cgroups/v3/cgroup1/stats"
specs "github.com/opencontainers/runtime-spec/specs-go"
)
diff --git a/vendor/github.com/containerd/cgroups/cpu.go b/vendor/github.com/containerd/cgroups/v3/cgroup1/cpu.go
index 27024f17b..e02ca0d8e 100644
--- a/vendor/github.com/containerd/cgroups/cpu.go
+++ b/vendor/github.com/containerd/cgroups/v3/cgroup1/cpu.go
@@ -14,7 +14,7 @@
limitations under the License.
*/
-package cgroups
+package cgroup1
import (
"bufio"
@@ -22,7 +22,7 @@ import (
"path/filepath"
"strconv"
- v1 "github.com/containerd/cgroups/stats/v1"
+ v1 "github.com/containerd/cgroups/v3/cgroup1/stats"
specs "github.com/opencontainers/runtime-spec/specs-go"
)
@@ -82,7 +82,7 @@ func (c *cpuController) Create(path string, resources *specs.LinuxResources) err
value = []byte(strconv.FormatInt(*t.ivalue, 10))
}
if value != nil {
- if err := retryingWriteFile(
+ if err := os.WriteFile(
filepath.Join(c.Path(path), "cpu."+t.name),
value,
defaultFilePerm,
diff --git a/vendor/github.com/containerd/cgroups/cpuacct.go b/vendor/github.com/containerd/cgroups/v3/cgroup1/cpuacct.go
index e5fc864bd..b7a3e8f6a 100644
--- a/vendor/github.com/containerd/cgroups/cpuacct.go
+++ b/vendor/github.com/containerd/cgroups/v3/cgroup1/cpuacct.go
@@ -14,16 +14,17 @@
limitations under the License.
*/
-package cgroups
+package cgroup1
import (
+ "bufio"
"fmt"
- "io/ioutil"
+ "os"
"path/filepath"
"strconv"
"strings"
- v1 "github.com/containerd/cgroups/stats/v1"
+ v1 "github.com/containerd/cgroups/v3/cgroup1/stats"
)
const nanosecondsInSecond = 1000000000
@@ -70,7 +71,7 @@ func (c *cpuacctController) Stat(path string, stats *v1.Metrics) error {
func (c *cpuacctController) percpuUsage(path string) ([]uint64, error) {
var usage []uint64
- data, err := ioutil.ReadFile(filepath.Join(c.Path(path), "cpuacct.usage_percpu"))
+ data, err := os.ReadFile(filepath.Join(c.Path(path), "cpuacct.usage_percpu"))
if err != nil {
return nil, err
}
@@ -86,36 +87,41 @@ func (c *cpuacctController) percpuUsage(path string) ([]uint64, error) {
func (c *cpuacctController) getUsage(path string) (user uint64, kernel uint64, err error) {
statPath := filepath.Join(c.Path(path), "cpuacct.stat")
- data, err := ioutil.ReadFile(statPath)
+ f, err := os.Open(statPath)
if err != nil {
return 0, 0, err
}
- fields := strings.Fields(string(data))
- if len(fields) != 4 {
- return 0, 0, fmt.Errorf("%q is expected to have 4 fields", statPath)
+ defer f.Close()
+ var (
+ raw = make(map[string]uint64)
+ sc = bufio.NewScanner(f)
+ )
+ for sc.Scan() {
+ key, v, err := parseKV(sc.Text())
+ if err != nil {
+ return 0, 0, err
+ }
+ raw[key] = v
+ }
+ if err := sc.Err(); err != nil {
+ return 0, 0, err
}
for _, t := range []struct {
- index int
name string
value *uint64
}{
{
- index: 0,
name: "user",
value: &user,
},
{
- index: 2,
name: "system",
value: &kernel,
},
} {
- if fields[t.index] != t.name {
- return 0, 0, fmt.Errorf("expected field %q but found %q in %q", t.name, fields[t.index], statPath)
- }
- v, err := strconv.ParseUint(fields[t.index+1], 10, 64)
- if err != nil {
- return 0, 0, err
+ v, ok := raw[t.name]
+ if !ok {
+ return 0, 0, fmt.Errorf("expected field %q but not found in %q", t.name, statPath)
}
*t.value = v
}
diff --git a/vendor/github.com/containerd/cgroups/cpuset.go b/vendor/github.com/containerd/cgroups/v3/cgroup1/cpuset.go
index 3cae173bd..242f77ed5 100644
--- a/vendor/github.com/containerd/cgroups/cpuset.go
+++ b/vendor/github.com/containerd/cgroups/v3/cgroup1/cpuset.go
@@ -14,12 +14,11 @@
limitations under the License.
*/
-package cgroups
+package cgroup1
import (
"bytes"
"fmt"
- "io/ioutil"
"os"
"path/filepath"
@@ -69,7 +68,7 @@ func (c *cpusetController) Create(path string, resources *specs.LinuxResources)
},
} {
if t.value != "" {
- if err := retryingWriteFile(
+ if err := os.WriteFile(
filepath.Join(c.Path(path), "cpuset."+t.name),
[]byte(t.value),
defaultFilePerm,
@@ -87,10 +86,10 @@ func (c *cpusetController) Update(path string, resources *specs.LinuxResources)
}
func (c *cpusetController) getValues(path string) (cpus []byte, mems []byte, err error) {
- if cpus, err = ioutil.ReadFile(filepath.Join(path, "cpuset.cpus")); err != nil && !os.IsNotExist(err) {
+ if cpus, err = os.ReadFile(filepath.Join(path, "cpuset.cpus")); err != nil && !os.IsNotExist(err) {
return
}
- if mems, err = ioutil.ReadFile(filepath.Join(path, "cpuset.mems")); err != nil && !os.IsNotExist(err) {
+ if mems, err = os.ReadFile(filepath.Join(path, "cpuset.mems")); err != nil && !os.IsNotExist(err) {
return
}
return cpus, mems, nil
@@ -134,7 +133,7 @@ func (c *cpusetController) copyIfNeeded(current, parent string) error {
return err
}
if isEmpty(currentCpus) {
- if err := retryingWriteFile(
+ if err := os.WriteFile(
filepath.Join(current, "cpuset.cpus"),
parentCpus,
defaultFilePerm,
@@ -143,7 +142,7 @@ func (c *cpusetController) copyIfNeeded(current, parent string) error {
}
}
if isEmpty(currentMems) {
- if err := retryingWriteFile(
+ if err := os.WriteFile(
filepath.Join(current, "cpuset.mems"),
parentMems,
defaultFilePerm,
diff --git a/vendor/github.com/containerd/cgroups/devices.go b/vendor/github.com/containerd/cgroups/v3/cgroup1/devices.go
index 7792566d5..80d76fa30 100644
--- a/vendor/github.com/containerd/cgroups/devices.go
+++ b/vendor/github.com/containerd/cgroups/v3/cgroup1/devices.go
@@ -14,7 +14,7 @@
limitations under the License.
*/
-package cgroups
+package cgroup1
import (
"fmt"
@@ -60,7 +60,7 @@ func (d *devicesController) Create(path string, resources *specs.LinuxResources)
if device.Type == "" {
device.Type = "a"
}
- if err := retryingWriteFile(
+ if err := os.WriteFile(
filepath.Join(d.Path(path), file),
[]byte(deviceString(device)),
defaultFilePerm,
diff --git a/vendor/github.com/containerd/cgroups/errors.go b/vendor/github.com/containerd/cgroups/v3/cgroup1/errors.go
index f1ad8315c..d3ff6fbd1 100644
--- a/vendor/github.com/containerd/cgroups/errors.go
+++ b/vendor/github.com/containerd/cgroups/v3/cgroup1/errors.go
@@ -14,7 +14,7 @@
limitations under the License.
*/
-package cgroups
+package cgroup1
import (
"errors"
diff --git a/vendor/github.com/containerd/cgroups/freezer.go b/vendor/github.com/containerd/cgroups/v3/cgroup1/freezer.go
index 59a7e7128..05d9f6c27 100644
--- a/vendor/github.com/containerd/cgroups/freezer.go
+++ b/vendor/github.com/containerd/cgroups/v3/cgroup1/freezer.go
@@ -14,10 +14,10 @@
limitations under the License.
*/
-package cgroups
+package cgroup1
import (
- "io/ioutil"
+ "os"
"path/filepath"
"strings"
"time"
@@ -50,7 +50,7 @@ func (f *freezerController) Thaw(path string) error {
}
func (f *freezerController) changeState(path string, state State) error {
- return retryingWriteFile(
+ return os.WriteFile(
filepath.Join(f.root, path, "freezer.state"),
[]byte(strings.ToUpper(string(state))),
defaultFilePerm,
@@ -58,7 +58,7 @@ func (f *freezerController) changeState(path string, state State) error {
}
func (f *freezerController) state(path string) (State, error) {
- current, err := ioutil.ReadFile(filepath.Join(f.root, path, "freezer.state"))
+ current, err := os.ReadFile(filepath.Join(f.root, path, "freezer.state"))
if err != nil {
return "", err
}
diff --git a/vendor/github.com/containerd/cgroups/hierarchy.go b/vendor/github.com/containerd/cgroups/v3/cgroup1/hierarchy.go
index ca3f1b938..1af9aa6be 100644
--- a/vendor/github.com/containerd/cgroups/hierarchy.go
+++ b/vendor/github.com/containerd/cgroups/v3/cgroup1/hierarchy.go
@@ -14,7 +14,7 @@
limitations under the License.
*/
-package cgroups
+package cgroup1
// Hierarchy enables both unified and split hierarchy for cgroups
type Hierarchy func() ([]Subsystem, error)
diff --git a/vendor/github.com/containerd/cgroups/hugetlb.go b/vendor/github.com/containerd/cgroups/v3/cgroup1/hugetlb.go
index c0eb03b24..75519d9da 100644
--- a/vendor/github.com/containerd/cgroups/hugetlb.go
+++ b/vendor/github.com/containerd/cgroups/v3/cgroup1/hugetlb.go
@@ -14,7 +14,7 @@
limitations under the License.
*/
-package cgroups
+package cgroup1
import (
"os"
@@ -22,7 +22,7 @@ import (
"strconv"
"strings"
- v1 "github.com/containerd/cgroups/stats/v1"
+ v1 "github.com/containerd/cgroups/v3/cgroup1/stats"
specs "github.com/opencontainers/runtime-spec/specs-go"
)
@@ -56,7 +56,7 @@ func (h *hugetlbController) Create(path string, resources *specs.LinuxResources)
return err
}
for _, limit := range resources.HugepageLimits {
- if err := retryingWriteFile(
+ if err := os.WriteFile(
filepath.Join(h.Path(path), strings.Join([]string{"hugetlb", limit.Pagesize, "limit_in_bytes"}, ".")),
[]byte(strconv.FormatUint(limit.Limit, 10)),
defaultFilePerm,
diff --git a/vendor/github.com/containerd/cgroups/memory.go b/vendor/github.com/containerd/cgroups/v3/cgroup1/memory.go
index e271866ef..e84ec2b3c 100644
--- a/vendor/github.com/containerd/cgroups/memory.go
+++ b/vendor/github.com/containerd/cgroups/v3/cgroup1/memory.go
@@ -14,7 +14,7 @@
limitations under the License.
*/
-package cgroups
+package cgroup1
import (
"bufio"
@@ -25,7 +25,7 @@ import (
"strconv"
"strings"
- v1 "github.com/containerd/cgroups/stats/v1"
+ v1 "github.com/containerd/cgroups/v3/cgroup1/stats"
specs "github.com/opencontainers/runtime-spec/specs-go"
"golang.org/x/sys/unix"
)
@@ -43,7 +43,7 @@ type memoryThresholdEvent struct {
swap bool
}
-// MemoryThresholdEvent returns a new memory threshold event to be used with RegisterMemoryEvent.
+// MemoryThresholdEvent returns a new [MemoryEvent] representing the memory threshold set.
// If swap is true, the event will be registered using memory.memsw.usage_in_bytes
func MemoryThresholdEvent(threshold uint64, swap bool) MemoryEvent {
return &memoryThresholdEvent{
@@ -83,7 +83,7 @@ type memoryPressureEvent struct {
hierarchy EventNotificationMode
}
-// MemoryPressureEvent returns a new memory pressure event to be used with RegisterMemoryEvent.
+// MemoryPressureEvent returns a new [MemoryEvent] representing the memory pressure set.
func MemoryPressureEvent(pressureLevel MemoryPressureLevel, hierarchy EventNotificationMode) MemoryEvent {
return &memoryPressureEvent{
pressureLevel,
@@ -104,22 +104,22 @@ func (m *memoryPressureEvent) EventFile() string {
type MemoryPressureLevel string
// The three memory pressure levels are as follows.
-// - The "low" level means that the system is reclaiming memory for new
-// allocations. Monitoring this reclaiming activity might be useful for
-// maintaining cache level. Upon notification, the program (typically
-// "Activity Manager") might analyze vmstat and act in advance (i.e.
-// prematurely shutdown unimportant services).
-// - The "medium" level means that the system is experiencing medium memory
-// pressure, the system might be making swap, paging out active file caches,
-// etc. Upon this event applications may decide to further analyze
-// vmstat/zoneinfo/memcg or internal memory usage statistics and free any
-// resources that can be easily reconstructed or re-read from a disk.
-// - The "critical" level means that the system is actively thrashing, it is
-// about to out of memory (OOM) or even the in-kernel OOM killer is on its
-// way to trigger. Applications should do whatever they can to help the
-// system. It might be too late to consult with vmstat or any other
-// statistics, so it is advisable to take an immediate action.
-// "https://www.kernel.org/doc/Documentation/cgroup-v1/memory.txt" Section 11
+// - The "low" level means that the system is reclaiming memory for new
+// allocations. Monitoring this reclaiming activity might be useful for
+// maintaining cache level. Upon notification, the program (typically
+// "Activity Manager") might analyze vmstat and act in advance (i.e.
+// prematurely shutdown unimportant services).
+// - The "medium" level means that the system is experiencing medium memory
+// pressure, the system might be making swap, paging out active file caches,
+// etc. Upon this event applications may decide to further analyze
+// vmstat/zoneinfo/memcg or internal memory usage statistics and free any
+// resources that can be easily reconstructed or re-read from a disk.
+// - The "critical" level means that the system is actively thrashing, it is
+// about to out of memory (OOM) or even the in-kernel OOM killer is on its
+// way to trigger. Applications should do whatever they can to help the
+// system. It might be too late to consult with vmstat or any other
+// statistics, so it is advisable to take an immediate action.
+// "https://www.kernel.org/doc/Documentation/cgroup-v1/memory.txt" Section 11
const (
LowPressure MemoryPressureLevel = "low"
MediumPressure MemoryPressureLevel = "medium"
@@ -131,21 +131,21 @@ const (
type EventNotificationMode string
// There are three optional modes that specify different propagation behavior:
-// - "default": this is the default behavior specified above. This mode is the
-// same as omitting the optional mode parameter, preserved by backwards
-// compatibility.
-// - "hierarchy": events always propagate up to the root, similar to the default
-// behavior, except that propagation continues regardless of whether there are
-// event listeners at each level, with the "hierarchy" mode. In the above
-// example, groups A, B, and C will receive notification of memory pressure.
-// - "local": events are pass-through, i.e. they only receive notifications when
-// memory pressure is experienced in the memcg for which the notification is
-// registered. In the above example, group C will receive notification if
-// registered for "local" notification and the group experiences memory
-// pressure. However, group B will never receive notification, regardless if
-// there is an event listener for group C or not, if group B is registered for
-// local notification.
-// "https://www.kernel.org/doc/Documentation/cgroup-v1/memory.txt" Section 11
+// - "default": this is the default behavior specified above. This mode is the
+// same as omitting the optional mode parameter, preserved by backwards
+// compatibility.
+// - "hierarchy": events always propagate up to the root, similar to the default
+// behavior, except that propagation continues regardless of whether there are
+// event listeners at each level, with the "hierarchy" mode. In the above
+// example, groups A, B, and C will receive notification of memory pressure.
+// - "local": events are pass-through, i.e. they only receive notifications when
+// memory pressure is experienced in the memcg for which the notification is
+// registered. In the above example, group C will receive notification if
+// registered for "local" notification and the group experiences memory
+// pressure. However, group B will never receive notification, regardless if
+// there is an event listener for group C or not, if group B is registered for
+// local notification.
+// "https://www.kernel.org/doc/Documentation/cgroup-v1/memory.txt" Section 11
const (
DefaultMode EventNotificationMode = "default"
LocalMode EventNotificationMode = "local"
@@ -394,7 +394,7 @@ func (m *memoryController) parseOomControlStats(r io.Reader, stat *v1.MemoryOomC
func (m *memoryController) set(path string, settings []memorySettings) error {
for _, t := range settings {
if t.value != nil {
- if err := retryingWriteFile(
+ if err := os.WriteFile(
filepath.Join(m.Path(path), "memory."+t.name),
[]byte(strconv.FormatInt(*t.value, 10)),
defaultFilePerm,
@@ -472,7 +472,7 @@ func (m *memoryController) memoryEvent(path string, event MemoryEvent) (uintptr,
defer evtFile.Close()
data := fmt.Sprintf("%d %d %s", efd, evtFile.Fd(), event.Arg())
evctlPath := filepath.Join(root, "cgroup.event_control")
- if err := retryingWriteFile(evctlPath, []byte(data), 0700); err != nil {
+ if err := os.WriteFile(evctlPath, []byte(data), 0700); err != nil {
unix.Close(efd)
return 0, err
}
diff --git a/vendor/github.com/containerd/cgroups/named.go b/vendor/github.com/containerd/cgroups/v3/cgroup1/named.go
index 06b16c3b1..95bda388e 100644
--- a/vendor/github.com/containerd/cgroups/named.go
+++ b/vendor/github.com/containerd/cgroups/v3/cgroup1/named.go
@@ -14,7 +14,7 @@
limitations under the License.
*/
-package cgroups
+package cgroup1
import "path/filepath"
diff --git a/vendor/github.com/containerd/cgroups/net_cls.go b/vendor/github.com/containerd/cgroups/v3/cgroup1/net_cls.go
index 839b06de0..22b3c95bb 100644
--- a/vendor/github.com/containerd/cgroups/net_cls.go
+++ b/vendor/github.com/containerd/cgroups/v3/cgroup1/net_cls.go
@@ -14,7 +14,7 @@
limitations under the License.
*/
-package cgroups
+package cgroup1
import (
"os"
@@ -47,7 +47,7 @@ func (n *netclsController) Create(path string, resources *specs.LinuxResources)
return err
}
if resources.Network != nil && resources.Network.ClassID != nil && *resources.Network.ClassID > 0 {
- return retryingWriteFile(
+ return os.WriteFile(
filepath.Join(n.Path(path), "net_cls.classid"),
[]byte(strconv.FormatUint(uint64(*resources.Network.ClassID), 10)),
defaultFilePerm,
diff --git a/vendor/github.com/containerd/cgroups/net_prio.go b/vendor/github.com/containerd/cgroups/v3/cgroup1/net_prio.go
index 6362fd084..0936442b9 100644
--- a/vendor/github.com/containerd/cgroups/net_prio.go
+++ b/vendor/github.com/containerd/cgroups/v3/cgroup1/net_prio.go
@@ -14,7 +14,7 @@
limitations under the License.
*/
-package cgroups
+package cgroup1
import (
"fmt"
@@ -48,7 +48,7 @@ func (n *netprioController) Create(path string, resources *specs.LinuxResources)
}
if resources.Network != nil {
for _, prio := range resources.Network.Priorities {
- if err := retryingWriteFile(
+ if err := os.WriteFile(
filepath.Join(n.Path(path), "net_prio.ifpriomap"),
formatPrio(prio.Name, prio.Priority),
defaultFilePerm,
diff --git a/vendor/github.com/containerd/cgroups/opts.go b/vendor/github.com/containerd/cgroups/v3/cgroup1/opts.go
index 1e428d048..187e0f5ea 100644
--- a/vendor/github.com/containerd/cgroups/opts.go
+++ b/vendor/github.com/containerd/cgroups/v3/cgroup1/opts.go
@@ -14,7 +14,7 @@
limitations under the License.
*/
-package cgroups
+package cgroup1
import (
"errors"
@@ -36,11 +36,13 @@ type InitOpts func(*InitConfig) error
type InitConfig struct {
// InitCheck can be used to check initialization errors from the subsystem
InitCheck InitCheck
+ hiearchy Hierarchy
}
func newInitConfig() *InitConfig {
return &InitConfig{
InitCheck: RequireDevices,
+ hiearchy: Default,
}
}
@@ -59,3 +61,12 @@ func RequireDevices(s Subsystem, _ Path, _ error) error {
}
return ErrIgnoreSubsystem
}
+
+// WithHiearchy sets a list of cgroup subsystems.
+// The default list is coming from /proc/self/mountinfo.
+func WithHiearchy(h Hierarchy) InitOpts {
+ return func(c *InitConfig) error {
+ c.hiearchy = h
+ return nil
+ }
+}
diff --git a/vendor/github.com/containerd/cgroups/paths.go b/vendor/github.com/containerd/cgroups/v3/cgroup1/paths.go
index bddc4e9cd..54de9a18e 100644
--- a/vendor/github.com/containerd/cgroups/paths.go
+++ b/vendor/github.com/containerd/cgroups/v3/cgroup1/paths.go
@@ -14,7 +14,7 @@
limitations under the License.
*/
-package cgroups
+package cgroup1
import (
"errors"
diff --git a/vendor/github.com/containerd/cgroups/perf_event.go b/vendor/github.com/containerd/cgroups/v3/cgroup1/perf_event.go
index 648786db6..4bd6d7e23 100644
--- a/vendor/github.com/containerd/cgroups/perf_event.go
+++ b/vendor/github.com/containerd/cgroups/v3/cgroup1/perf_event.go
@@ -14,7 +14,7 @@
limitations under the License.
*/
-package cgroups
+package cgroup1
import "path/filepath"
diff --git a/vendor/github.com/containerd/cgroups/pids.go b/vendor/github.com/containerd/cgroups/v3/cgroup1/pids.go
index ce78e44c1..9b5b263af 100644
--- a/vendor/github.com/containerd/cgroups/pids.go
+++ b/vendor/github.com/containerd/cgroups/v3/cgroup1/pids.go
@@ -14,16 +14,15 @@
limitations under the License.
*/
-package cgroups
+package cgroup1
import (
- "io/ioutil"
"os"
"path/filepath"
"strconv"
"strings"
- v1 "github.com/containerd/cgroups/stats/v1"
+ v1 "github.com/containerd/cgroups/v3/cgroup1/stats"
specs "github.com/opencontainers/runtime-spec/specs-go"
)
@@ -50,7 +49,7 @@ func (p *pidsController) Create(path string, resources *specs.LinuxResources) er
return err
}
if resources.Pids != nil && resources.Pids.Limit > 0 {
- return retryingWriteFile(
+ return os.WriteFile(
filepath.Join(p.Path(path), "pids.max"),
[]byte(strconv.FormatInt(resources.Pids.Limit, 10)),
defaultFilePerm,
@@ -69,7 +68,7 @@ func (p *pidsController) Stat(path string, stats *v1.Metrics) error {
return err
}
var max uint64
- maxData, err := ioutil.ReadFile(filepath.Join(p.Path(path), "pids.max"))
+ maxData, err := os.ReadFile(filepath.Join(p.Path(path), "pids.max"))
if err != nil {
return err
}
diff --git a/vendor/github.com/containerd/cgroups/rdma.go b/vendor/github.com/containerd/cgroups/v3/cgroup1/rdma.go
index 3b59b1071..99299070c 100644
--- a/vendor/github.com/containerd/cgroups/rdma.go
+++ b/vendor/github.com/containerd/cgroups/v3/cgroup1/rdma.go
@@ -14,17 +14,16 @@
limitations under the License.
*/
-package cgroups
+package cgroup1
import (
- "io/ioutil"
"math"
"os"
"path/filepath"
"strconv"
"strings"
- v1 "github.com/containerd/cgroups/stats/v1"
+ v1 "github.com/containerd/cgroups/v3/cgroup1/stats"
specs "github.com/opencontainers/runtime-spec/specs-go"
)
@@ -68,7 +67,7 @@ func (p *rdmaController) Create(path string, resources *specs.LinuxResources) er
for device, limit := range resources.Rdma {
if device != "" && (limit.HcaHandles != nil || limit.HcaObjects != nil) {
limit := limit
- return retryingWriteFile(
+ return os.WriteFile(
filepath.Join(p.Path(path), "rdma.max"),
[]byte(createCmdString(device, &limit)),
defaultFilePerm,
@@ -126,13 +125,13 @@ func toRdmaEntry(strEntries []string) []*v1.RdmaEntry {
func (p *rdmaController) Stat(path string, stats *v1.Metrics) error {
- currentData, err := ioutil.ReadFile(filepath.Join(p.Path(path), "rdma.current"))
+ currentData, err := os.ReadFile(filepath.Join(p.Path(path), "rdma.current"))
if err != nil {
return err
}
currentPerDevices := strings.Split(string(currentData), "\n")
- maxData, err := ioutil.ReadFile(filepath.Join(p.Path(path), "rdma.max"))
+ maxData, err := os.ReadFile(filepath.Join(p.Path(path), "rdma.max"))
if err != nil {
return err
}
diff --git a/vendor/github.com/containerd/cgroups/state.go b/vendor/github.com/containerd/cgroups/v3/cgroup1/state.go
index cfeabbbc6..6ea81cccc 100644
--- a/vendor/github.com/containerd/cgroups/state.go
+++ b/vendor/github.com/containerd/cgroups/v3/cgroup1/state.go
@@ -14,7 +14,7 @@
limitations under the License.
*/
-package cgroups
+package cgroup1
// State is a type that represents the state of the current cgroup
type State string
diff --git a/vendor/github.com/containerd/cgroups/v2/stats/doc.go b/vendor/github.com/containerd/cgroups/v3/cgroup1/stats/doc.go
index e51e12f80..e51e12f80 100644
--- a/vendor/github.com/containerd/cgroups/v2/stats/doc.go
+++ b/vendor/github.com/containerd/cgroups/v3/cgroup1/stats/doc.go
diff --git a/vendor/github.com/containerd/cgroups/v3/cgroup1/stats/metrics.pb.go b/vendor/github.com/containerd/cgroups/v3/cgroup1/stats/metrics.pb.go
new file mode 100644
index 000000000..75206889b
--- /dev/null
+++ b/vendor/github.com/containerd/cgroups/v3/cgroup1/stats/metrics.pb.go
@@ -0,0 +1,1959 @@
+// Code generated by protoc-gen-go. DO NOT EDIT.
+// versions:
+// protoc-gen-go v1.28.1
+// protoc v3.21.5
+// source: github.com/containerd/cgroups/cgroup1/stats/metrics.proto
+
+package stats
+
+import (
+ protoreflect "google.golang.org/protobuf/reflect/protoreflect"
+ protoimpl "google.golang.org/protobuf/runtime/protoimpl"
+ reflect "reflect"
+ sync "sync"
+)
+
+const (
+ // Verify that this generated code is sufficiently up-to-date.
+ _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion)
+ // Verify that runtime/protoimpl is sufficiently up-to-date.
+ _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
+)
+
+type Metrics struct {
+ state protoimpl.MessageState
+ sizeCache protoimpl.SizeCache
+ unknownFields protoimpl.UnknownFields
+
+ Hugetlb []*HugetlbStat `protobuf:"bytes,1,rep,name=hugetlb,proto3" json:"hugetlb,omitempty"`
+ Pids *PidsStat `protobuf:"bytes,2,opt,name=pids,proto3" json:"pids,omitempty"`
+ CPU *CPUStat `protobuf:"bytes,3,opt,name=cpu,proto3" json:"cpu,omitempty"`
+ Memory *MemoryStat `protobuf:"bytes,4,opt,name=memory,proto3" json:"memory,omitempty"`
+ Blkio *BlkIOStat `protobuf:"bytes,5,opt,name=blkio,proto3" json:"blkio,omitempty"`
+ Rdma *RdmaStat `protobuf:"bytes,6,opt,name=rdma,proto3" json:"rdma,omitempty"`
+ Network []*NetworkStat `protobuf:"bytes,7,rep,name=network,proto3" json:"network,omitempty"`
+ CgroupStats *CgroupStats `protobuf:"bytes,8,opt,name=cgroup_stats,json=cgroupStats,proto3" json:"cgroup_stats,omitempty"`
+ MemoryOomControl *MemoryOomControl `protobuf:"bytes,9,opt,name=memory_oom_control,json=memoryOomControl,proto3" json:"memory_oom_control,omitempty"`
+}
+
+func (x *Metrics) Reset() {
+ *x = Metrics{}
+ if protoimpl.UnsafeEnabled {
+ mi := &file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_msgTypes[0]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
+ }
+}
+
+func (x *Metrics) String() string {
+ return protoimpl.X.MessageStringOf(x)
+}
+
+func (*Metrics) ProtoMessage() {}
+
+func (x *Metrics) ProtoReflect() protoreflect.Message {
+ mi := &file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_msgTypes[0]
+ if protoimpl.UnsafeEnabled && x != nil {
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ if ms.LoadMessageInfo() == nil {
+ ms.StoreMessageInfo(mi)
+ }
+ return ms
+ }
+ return mi.MessageOf(x)
+}
+
+// Deprecated: Use Metrics.ProtoReflect.Descriptor instead.
+func (*Metrics) Descriptor() ([]byte, []int) {
+ return file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_rawDescGZIP(), []int{0}
+}
+
+func (x *Metrics) GetHugetlb() []*HugetlbStat {
+ if x != nil {
+ return x.Hugetlb
+ }
+ return nil
+}
+
+func (x *Metrics) GetPids() *PidsStat {
+ if x != nil {
+ return x.Pids
+ }
+ return nil
+}
+
+func (x *Metrics) GetCPU() *CPUStat {
+ if x != nil {
+ return x.CPU
+ }
+ return nil
+}
+
+func (x *Metrics) GetMemory() *MemoryStat {
+ if x != nil {
+ return x.Memory
+ }
+ return nil
+}
+
+func (x *Metrics) GetBlkio() *BlkIOStat {
+ if x != nil {
+ return x.Blkio
+ }
+ return nil
+}
+
+func (x *Metrics) GetRdma() *RdmaStat {
+ if x != nil {
+ return x.Rdma
+ }
+ return nil
+}
+
+func (x *Metrics) GetNetwork() []*NetworkStat {
+ if x != nil {
+ return x.Network
+ }
+ return nil
+}
+
+func (x *Metrics) GetCgroupStats() *CgroupStats {
+ if x != nil {
+ return x.CgroupStats
+ }
+ return nil
+}
+
+func (x *Metrics) GetMemoryOomControl() *MemoryOomControl {
+ if x != nil {
+ return x.MemoryOomControl
+ }
+ return nil
+}
+
+type HugetlbStat struct {
+ state protoimpl.MessageState
+ sizeCache protoimpl.SizeCache
+ unknownFields protoimpl.UnknownFields
+
+ Usage uint64 `protobuf:"varint,1,opt,name=usage,proto3" json:"usage,omitempty"`
+ Max uint64 `protobuf:"varint,2,opt,name=max,proto3" json:"max,omitempty"`
+ Failcnt uint64 `protobuf:"varint,3,opt,name=failcnt,proto3" json:"failcnt,omitempty"`
+ Pagesize string `protobuf:"bytes,4,opt,name=pagesize,proto3" json:"pagesize,omitempty"`
+}
+
+func (x *HugetlbStat) Reset() {
+ *x = HugetlbStat{}
+ if protoimpl.UnsafeEnabled {
+ mi := &file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_msgTypes[1]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
+ }
+}
+
+func (x *HugetlbStat) String() string {
+ return protoimpl.X.MessageStringOf(x)
+}
+
+func (*HugetlbStat) ProtoMessage() {}
+
+func (x *HugetlbStat) ProtoReflect() protoreflect.Message {
+ mi := &file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_msgTypes[1]
+ if protoimpl.UnsafeEnabled && x != nil {
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ if ms.LoadMessageInfo() == nil {
+ ms.StoreMessageInfo(mi)
+ }
+ return ms
+ }
+ return mi.MessageOf(x)
+}
+
+// Deprecated: Use HugetlbStat.ProtoReflect.Descriptor instead.
+func (*HugetlbStat) Descriptor() ([]byte, []int) {
+ return file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_rawDescGZIP(), []int{1}
+}
+
+func (x *HugetlbStat) GetUsage() uint64 {
+ if x != nil {
+ return x.Usage
+ }
+ return 0
+}
+
+func (x *HugetlbStat) GetMax() uint64 {
+ if x != nil {
+ return x.Max
+ }
+ return 0
+}
+
+func (x *HugetlbStat) GetFailcnt() uint64 {
+ if x != nil {
+ return x.Failcnt
+ }
+ return 0
+}
+
+func (x *HugetlbStat) GetPagesize() string {
+ if x != nil {
+ return x.Pagesize
+ }
+ return ""
+}
+
+type PidsStat struct {
+ state protoimpl.MessageState
+ sizeCache protoimpl.SizeCache
+ unknownFields protoimpl.UnknownFields
+
+ Current uint64 `protobuf:"varint,1,opt,name=current,proto3" json:"current,omitempty"`
+ Limit uint64 `protobuf:"varint,2,opt,name=limit,proto3" json:"limit,omitempty"`
+}
+
+func (x *PidsStat) Reset() {
+ *x = PidsStat{}
+ if protoimpl.UnsafeEnabled {
+ mi := &file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_msgTypes[2]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
+ }
+}
+
+func (x *PidsStat) String() string {
+ return protoimpl.X.MessageStringOf(x)
+}
+
+func (*PidsStat) ProtoMessage() {}
+
+func (x *PidsStat) ProtoReflect() protoreflect.Message {
+ mi := &file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_msgTypes[2]
+ if protoimpl.UnsafeEnabled && x != nil {
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ if ms.LoadMessageInfo() == nil {
+ ms.StoreMessageInfo(mi)
+ }
+ return ms
+ }
+ return mi.MessageOf(x)
+}
+
+// Deprecated: Use PidsStat.ProtoReflect.Descriptor instead.
+func (*PidsStat) Descriptor() ([]byte, []int) {
+ return file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_rawDescGZIP(), []int{2}
+}
+
+func (x *PidsStat) GetCurrent() uint64 {
+ if x != nil {
+ return x.Current
+ }
+ return 0
+}
+
+func (x *PidsStat) GetLimit() uint64 {
+ if x != nil {
+ return x.Limit
+ }
+ return 0
+}
+
+type CPUStat struct {
+ state protoimpl.MessageState
+ sizeCache protoimpl.SizeCache
+ unknownFields protoimpl.UnknownFields
+
+ Usage *CPUUsage `protobuf:"bytes,1,opt,name=usage,proto3" json:"usage,omitempty"`
+ Throttling *Throttle `protobuf:"bytes,2,opt,name=throttling,proto3" json:"throttling,omitempty"`
+}
+
+func (x *CPUStat) Reset() {
+ *x = CPUStat{}
+ if protoimpl.UnsafeEnabled {
+ mi := &file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_msgTypes[3]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
+ }
+}
+
+func (x *CPUStat) String() string {
+ return protoimpl.X.MessageStringOf(x)
+}
+
+func (*CPUStat) ProtoMessage() {}
+
+func (x *CPUStat) ProtoReflect() protoreflect.Message {
+ mi := &file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_msgTypes[3]
+ if protoimpl.UnsafeEnabled && x != nil {
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ if ms.LoadMessageInfo() == nil {
+ ms.StoreMessageInfo(mi)
+ }
+ return ms
+ }
+ return mi.MessageOf(x)
+}
+
+// Deprecated: Use CPUStat.ProtoReflect.Descriptor instead.
+func (*CPUStat) Descriptor() ([]byte, []int) {
+ return file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_rawDescGZIP(), []int{3}
+}
+
+func (x *CPUStat) GetUsage() *CPUUsage {
+ if x != nil {
+ return x.Usage
+ }
+ return nil
+}
+
+func (x *CPUStat) GetThrottling() *Throttle {
+ if x != nil {
+ return x.Throttling
+ }
+ return nil
+}
+
+type CPUUsage struct {
+ state protoimpl.MessageState
+ sizeCache protoimpl.SizeCache
+ unknownFields protoimpl.UnknownFields
+
+ // values in nanoseconds
+ Total uint64 `protobuf:"varint,1,opt,name=total,proto3" json:"total,omitempty"`
+ Kernel uint64 `protobuf:"varint,2,opt,name=kernel,proto3" json:"kernel,omitempty"`
+ User uint64 `protobuf:"varint,3,opt,name=user,proto3" json:"user,omitempty"`
+ PerCPU []uint64 `protobuf:"varint,4,rep,packed,name=per_cpu,json=perCpu,proto3" json:"per_cpu,omitempty"`
+}
+
+func (x *CPUUsage) Reset() {
+ *x = CPUUsage{}
+ if protoimpl.UnsafeEnabled {
+ mi := &file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_msgTypes[4]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
+ }
+}
+
+func (x *CPUUsage) String() string {
+ return protoimpl.X.MessageStringOf(x)
+}
+
+func (*CPUUsage) ProtoMessage() {}
+
+func (x *CPUUsage) ProtoReflect() protoreflect.Message {
+ mi := &file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_msgTypes[4]
+ if protoimpl.UnsafeEnabled && x != nil {
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ if ms.LoadMessageInfo() == nil {
+ ms.StoreMessageInfo(mi)
+ }
+ return ms
+ }
+ return mi.MessageOf(x)
+}
+
+// Deprecated: Use CPUUsage.ProtoReflect.Descriptor instead.
+func (*CPUUsage) Descriptor() ([]byte, []int) {
+ return file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_rawDescGZIP(), []int{4}
+}
+
+func (x *CPUUsage) GetTotal() uint64 {
+ if x != nil {
+ return x.Total
+ }
+ return 0
+}
+
+func (x *CPUUsage) GetKernel() uint64 {
+ if x != nil {
+ return x.Kernel
+ }
+ return 0
+}
+
+func (x *CPUUsage) GetUser() uint64 {
+ if x != nil {
+ return x.User
+ }
+ return 0
+}
+
+func (x *CPUUsage) GetPerCPU() []uint64 {
+ if x != nil {
+ return x.PerCPU
+ }
+ return nil
+}
+
+type Throttle struct {
+ state protoimpl.MessageState
+ sizeCache protoimpl.SizeCache
+ unknownFields protoimpl.UnknownFields
+
+ Periods uint64 `protobuf:"varint,1,opt,name=periods,proto3" json:"periods,omitempty"`
+ ThrottledPeriods uint64 `protobuf:"varint,2,opt,name=throttled_periods,json=throttledPeriods,proto3" json:"throttled_periods,omitempty"`
+ ThrottledTime uint64 `protobuf:"varint,3,opt,name=throttled_time,json=throttledTime,proto3" json:"throttled_time,omitempty"`
+}
+
+func (x *Throttle) Reset() {
+ *x = Throttle{}
+ if protoimpl.UnsafeEnabled {
+ mi := &file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_msgTypes[5]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
+ }
+}
+
+func (x *Throttle) String() string {
+ return protoimpl.X.MessageStringOf(x)
+}
+
+func (*Throttle) ProtoMessage() {}
+
+func (x *Throttle) ProtoReflect() protoreflect.Message {
+ mi := &file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_msgTypes[5]
+ if protoimpl.UnsafeEnabled && x != nil {
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ if ms.LoadMessageInfo() == nil {
+ ms.StoreMessageInfo(mi)
+ }
+ return ms
+ }
+ return mi.MessageOf(x)
+}
+
+// Deprecated: Use Throttle.ProtoReflect.Descriptor instead.
+func (*Throttle) Descriptor() ([]byte, []int) {
+ return file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_rawDescGZIP(), []int{5}
+}
+
+func (x *Throttle) GetPeriods() uint64 {
+ if x != nil {
+ return x.Periods
+ }
+ return 0
+}
+
+func (x *Throttle) GetThrottledPeriods() uint64 {
+ if x != nil {
+ return x.ThrottledPeriods
+ }
+ return 0
+}
+
+func (x *Throttle) GetThrottledTime() uint64 {
+ if x != nil {
+ return x.ThrottledTime
+ }
+ return 0
+}
+
+type MemoryStat struct {
+ state protoimpl.MessageState
+ sizeCache protoimpl.SizeCache
+ unknownFields protoimpl.UnknownFields
+
+ Cache uint64 `protobuf:"varint,1,opt,name=cache,proto3" json:"cache,omitempty"`
+ RSS uint64 `protobuf:"varint,2,opt,name=rss,proto3" json:"rss,omitempty"`
+ RSSHuge uint64 `protobuf:"varint,3,opt,name=rss_huge,json=rssHuge,proto3" json:"rss_huge,omitempty"`
+ MappedFile uint64 `protobuf:"varint,4,opt,name=mapped_file,json=mappedFile,proto3" json:"mapped_file,omitempty"`
+ Dirty uint64 `protobuf:"varint,5,opt,name=dirty,proto3" json:"dirty,omitempty"`
+ Writeback uint64 `protobuf:"varint,6,opt,name=writeback,proto3" json:"writeback,omitempty"`
+ PgPgIn uint64 `protobuf:"varint,7,opt,name=pg_pg_in,json=pgPgIn,proto3" json:"pg_pg_in,omitempty"`
+ PgPgOut uint64 `protobuf:"varint,8,opt,name=pg_pg_out,json=pgPgOut,proto3" json:"pg_pg_out,omitempty"`
+ PgFault uint64 `protobuf:"varint,9,opt,name=pg_fault,json=pgFault,proto3" json:"pg_fault,omitempty"`
+ PgMajFault uint64 `protobuf:"varint,10,opt,name=pg_maj_fault,json=pgMajFault,proto3" json:"pg_maj_fault,omitempty"`
+ InactiveAnon uint64 `protobuf:"varint,11,opt,name=inactive_anon,json=inactiveAnon,proto3" json:"inactive_anon,omitempty"`
+ ActiveAnon uint64 `protobuf:"varint,12,opt,name=active_anon,json=activeAnon,proto3" json:"active_anon,omitempty"`
+ InactiveFile uint64 `protobuf:"varint,13,opt,name=inactive_file,json=inactiveFile,proto3" json:"inactive_file,omitempty"`
+ ActiveFile uint64 `protobuf:"varint,14,opt,name=active_file,json=activeFile,proto3" json:"active_file,omitempty"`
+ Unevictable uint64 `protobuf:"varint,15,opt,name=unevictable,proto3" json:"unevictable,omitempty"`
+ HierarchicalMemoryLimit uint64 `protobuf:"varint,16,opt,name=hierarchical_memory_limit,json=hierarchicalMemoryLimit,proto3" json:"hierarchical_memory_limit,omitempty"`
+ HierarchicalSwapLimit uint64 `protobuf:"varint,17,opt,name=hierarchical_swap_limit,json=hierarchicalSwapLimit,proto3" json:"hierarchical_swap_limit,omitempty"`
+ TotalCache uint64 `protobuf:"varint,18,opt,name=total_cache,json=totalCache,proto3" json:"total_cache,omitempty"`
+ TotalRSS uint64 `protobuf:"varint,19,opt,name=total_rss,json=totalRss,proto3" json:"total_rss,omitempty"`
+ TotalRSSHuge uint64 `protobuf:"varint,20,opt,name=total_rss_huge,json=totalRssHuge,proto3" json:"total_rss_huge,omitempty"`
+ TotalMappedFile uint64 `protobuf:"varint,21,opt,name=total_mapped_file,json=totalMappedFile,proto3" json:"total_mapped_file,omitempty"`
+ TotalDirty uint64 `protobuf:"varint,22,opt,name=total_dirty,json=totalDirty,proto3" json:"total_dirty,omitempty"`
+ TotalWriteback uint64 `protobuf:"varint,23,opt,name=total_writeback,json=totalWriteback,proto3" json:"total_writeback,omitempty"`
+ TotalPgPgIn uint64 `protobuf:"varint,24,opt,name=total_pg_pg_in,json=totalPgPgIn,proto3" json:"total_pg_pg_in,omitempty"`
+ TotalPgPgOut uint64 `protobuf:"varint,25,opt,name=total_pg_pg_out,json=totalPgPgOut,proto3" json:"total_pg_pg_out,omitempty"`
+ TotalPgFault uint64 `protobuf:"varint,26,opt,name=total_pg_fault,json=totalPgFault,proto3" json:"total_pg_fault,omitempty"`
+ TotalPgMajFault uint64 `protobuf:"varint,27,opt,name=total_pg_maj_fault,json=totalPgMajFault,proto3" json:"total_pg_maj_fault,omitempty"`
+ TotalInactiveAnon uint64 `protobuf:"varint,28,opt,name=total_inactive_anon,json=totalInactiveAnon,proto3" json:"total_inactive_anon,omitempty"`
+ TotalActiveAnon uint64 `protobuf:"varint,29,opt,name=total_active_anon,json=totalActiveAnon,proto3" json:"total_active_anon,omitempty"`
+ TotalInactiveFile uint64 `protobuf:"varint,30,opt,name=total_inactive_file,json=totalInactiveFile,proto3" json:"total_inactive_file,omitempty"`
+ TotalActiveFile uint64 `protobuf:"varint,31,opt,name=total_active_file,json=totalActiveFile,proto3" json:"total_active_file,omitempty"`
+ TotalUnevictable uint64 `protobuf:"varint,32,opt,name=total_unevictable,json=totalUnevictable,proto3" json:"total_unevictable,omitempty"`
+ Usage *MemoryEntry `protobuf:"bytes,33,opt,name=usage,proto3" json:"usage,omitempty"`
+ Swap *MemoryEntry `protobuf:"bytes,34,opt,name=swap,proto3" json:"swap,omitempty"`
+ Kernel *MemoryEntry `protobuf:"bytes,35,opt,name=kernel,proto3" json:"kernel,omitempty"`
+ KernelTCP *MemoryEntry `protobuf:"bytes,36,opt,name=kernel_tcp,json=kernelTcp,proto3" json:"kernel_tcp,omitempty"`
+}
+
+func (x *MemoryStat) Reset() {
+ *x = MemoryStat{}
+ if protoimpl.UnsafeEnabled {
+ mi := &file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_msgTypes[6]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
+ }
+}
+
+func (x *MemoryStat) String() string {
+ return protoimpl.X.MessageStringOf(x)
+}
+
+func (*MemoryStat) ProtoMessage() {}
+
+func (x *MemoryStat) ProtoReflect() protoreflect.Message {
+ mi := &file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_msgTypes[6]
+ if protoimpl.UnsafeEnabled && x != nil {
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ if ms.LoadMessageInfo() == nil {
+ ms.StoreMessageInfo(mi)
+ }
+ return ms
+ }
+ return mi.MessageOf(x)
+}
+
+// Deprecated: Use MemoryStat.ProtoReflect.Descriptor instead.
+func (*MemoryStat) Descriptor() ([]byte, []int) {
+ return file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_rawDescGZIP(), []int{6}
+}
+
+func (x *MemoryStat) GetCache() uint64 {
+ if x != nil {
+ return x.Cache
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetRSS() uint64 {
+ if x != nil {
+ return x.RSS
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetRSSHuge() uint64 {
+ if x != nil {
+ return x.RSSHuge
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetMappedFile() uint64 {
+ if x != nil {
+ return x.MappedFile
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetDirty() uint64 {
+ if x != nil {
+ return x.Dirty
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetWriteback() uint64 {
+ if x != nil {
+ return x.Writeback
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetPgPgIn() uint64 {
+ if x != nil {
+ return x.PgPgIn
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetPgPgOut() uint64 {
+ if x != nil {
+ return x.PgPgOut
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetPgFault() uint64 {
+ if x != nil {
+ return x.PgFault
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetPgMajFault() uint64 {
+ if x != nil {
+ return x.PgMajFault
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetInactiveAnon() uint64 {
+ if x != nil {
+ return x.InactiveAnon
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetActiveAnon() uint64 {
+ if x != nil {
+ return x.ActiveAnon
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetInactiveFile() uint64 {
+ if x != nil {
+ return x.InactiveFile
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetActiveFile() uint64 {
+ if x != nil {
+ return x.ActiveFile
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetUnevictable() uint64 {
+ if x != nil {
+ return x.Unevictable
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetHierarchicalMemoryLimit() uint64 {
+ if x != nil {
+ return x.HierarchicalMemoryLimit
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetHierarchicalSwapLimit() uint64 {
+ if x != nil {
+ return x.HierarchicalSwapLimit
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetTotalCache() uint64 {
+ if x != nil {
+ return x.TotalCache
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetTotalRSS() uint64 {
+ if x != nil {
+ return x.TotalRSS
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetTotalRSSHuge() uint64 {
+ if x != nil {
+ return x.TotalRSSHuge
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetTotalMappedFile() uint64 {
+ if x != nil {
+ return x.TotalMappedFile
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetTotalDirty() uint64 {
+ if x != nil {
+ return x.TotalDirty
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetTotalWriteback() uint64 {
+ if x != nil {
+ return x.TotalWriteback
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetTotalPgPgIn() uint64 {
+ if x != nil {
+ return x.TotalPgPgIn
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetTotalPgPgOut() uint64 {
+ if x != nil {
+ return x.TotalPgPgOut
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetTotalPgFault() uint64 {
+ if x != nil {
+ return x.TotalPgFault
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetTotalPgMajFault() uint64 {
+ if x != nil {
+ return x.TotalPgMajFault
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetTotalInactiveAnon() uint64 {
+ if x != nil {
+ return x.TotalInactiveAnon
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetTotalActiveAnon() uint64 {
+ if x != nil {
+ return x.TotalActiveAnon
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetTotalInactiveFile() uint64 {
+ if x != nil {
+ return x.TotalInactiveFile
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetTotalActiveFile() uint64 {
+ if x != nil {
+ return x.TotalActiveFile
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetTotalUnevictable() uint64 {
+ if x != nil {
+ return x.TotalUnevictable
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetUsage() *MemoryEntry {
+ if x != nil {
+ return x.Usage
+ }
+ return nil
+}
+
+func (x *MemoryStat) GetSwap() *MemoryEntry {
+ if x != nil {
+ return x.Swap
+ }
+ return nil
+}
+
+func (x *MemoryStat) GetKernel() *MemoryEntry {
+ if x != nil {
+ return x.Kernel
+ }
+ return nil
+}
+
+func (x *MemoryStat) GetKernelTCP() *MemoryEntry {
+ if x != nil {
+ return x.KernelTCP
+ }
+ return nil
+}
+
+type MemoryEntry struct {
+ state protoimpl.MessageState
+ sizeCache protoimpl.SizeCache
+ unknownFields protoimpl.UnknownFields
+
+ Limit uint64 `protobuf:"varint,1,opt,name=limit,proto3" json:"limit,omitempty"`
+ Usage uint64 `protobuf:"varint,2,opt,name=usage,proto3" json:"usage,omitempty"`
+ Max uint64 `protobuf:"varint,3,opt,name=max,proto3" json:"max,omitempty"`
+ Failcnt uint64 `protobuf:"varint,4,opt,name=failcnt,proto3" json:"failcnt,omitempty"`
+}
+
+func (x *MemoryEntry) Reset() {
+ *x = MemoryEntry{}
+ if protoimpl.UnsafeEnabled {
+ mi := &file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_msgTypes[7]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
+ }
+}
+
+func (x *MemoryEntry) String() string {
+ return protoimpl.X.MessageStringOf(x)
+}
+
+func (*MemoryEntry) ProtoMessage() {}
+
+func (x *MemoryEntry) ProtoReflect() protoreflect.Message {
+ mi := &file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_msgTypes[7]
+ if protoimpl.UnsafeEnabled && x != nil {
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ if ms.LoadMessageInfo() == nil {
+ ms.StoreMessageInfo(mi)
+ }
+ return ms
+ }
+ return mi.MessageOf(x)
+}
+
+// Deprecated: Use MemoryEntry.ProtoReflect.Descriptor instead.
+func (*MemoryEntry) Descriptor() ([]byte, []int) {
+ return file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_rawDescGZIP(), []int{7}
+}
+
+func (x *MemoryEntry) GetLimit() uint64 {
+ if x != nil {
+ return x.Limit
+ }
+ return 0
+}
+
+func (x *MemoryEntry) GetUsage() uint64 {
+ if x != nil {
+ return x.Usage
+ }
+ return 0
+}
+
+func (x *MemoryEntry) GetMax() uint64 {
+ if x != nil {
+ return x.Max
+ }
+ return 0
+}
+
+func (x *MemoryEntry) GetFailcnt() uint64 {
+ if x != nil {
+ return x.Failcnt
+ }
+ return 0
+}
+
+type MemoryOomControl struct {
+ state protoimpl.MessageState
+ sizeCache protoimpl.SizeCache
+ unknownFields protoimpl.UnknownFields
+
+ OomKillDisable uint64 `protobuf:"varint,1,opt,name=oom_kill_disable,json=oomKillDisable,proto3" json:"oom_kill_disable,omitempty"`
+ UnderOom uint64 `protobuf:"varint,2,opt,name=under_oom,json=underOom,proto3" json:"under_oom,omitempty"`
+ OomKill uint64 `protobuf:"varint,3,opt,name=oom_kill,json=oomKill,proto3" json:"oom_kill,omitempty"`
+}
+
+func (x *MemoryOomControl) Reset() {
+ *x = MemoryOomControl{}
+ if protoimpl.UnsafeEnabled {
+ mi := &file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_msgTypes[8]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
+ }
+}
+
+func (x *MemoryOomControl) String() string {
+ return protoimpl.X.MessageStringOf(x)
+}
+
+func (*MemoryOomControl) ProtoMessage() {}
+
+func (x *MemoryOomControl) ProtoReflect() protoreflect.Message {
+ mi := &file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_msgTypes[8]
+ if protoimpl.UnsafeEnabled && x != nil {
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ if ms.LoadMessageInfo() == nil {
+ ms.StoreMessageInfo(mi)
+ }
+ return ms
+ }
+ return mi.MessageOf(x)
+}
+
+// Deprecated: Use MemoryOomControl.ProtoReflect.Descriptor instead.
+func (*MemoryOomControl) Descriptor() ([]byte, []int) {
+ return file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_rawDescGZIP(), []int{8}
+}
+
+func (x *MemoryOomControl) GetOomKillDisable() uint64 {
+ if x != nil {
+ return x.OomKillDisable
+ }
+ return 0
+}
+
+func (x *MemoryOomControl) GetUnderOom() uint64 {
+ if x != nil {
+ return x.UnderOom
+ }
+ return 0
+}
+
+func (x *MemoryOomControl) GetOomKill() uint64 {
+ if x != nil {
+ return x.OomKill
+ }
+ return 0
+}
+
+type BlkIOStat struct {
+ state protoimpl.MessageState
+ sizeCache protoimpl.SizeCache
+ unknownFields protoimpl.UnknownFields
+
+ IoServiceBytesRecursive []*BlkIOEntry `protobuf:"bytes,1,rep,name=io_service_bytes_recursive,json=ioServiceBytesRecursive,proto3" json:"io_service_bytes_recursive,omitempty"`
+ IoServicedRecursive []*BlkIOEntry `protobuf:"bytes,2,rep,name=io_serviced_recursive,json=ioServicedRecursive,proto3" json:"io_serviced_recursive,omitempty"`
+ IoQueuedRecursive []*BlkIOEntry `protobuf:"bytes,3,rep,name=io_queued_recursive,json=ioQueuedRecursive,proto3" json:"io_queued_recursive,omitempty"`
+ IoServiceTimeRecursive []*BlkIOEntry `protobuf:"bytes,4,rep,name=io_service_time_recursive,json=ioServiceTimeRecursive,proto3" json:"io_service_time_recursive,omitempty"`
+ IoWaitTimeRecursive []*BlkIOEntry `protobuf:"bytes,5,rep,name=io_wait_time_recursive,json=ioWaitTimeRecursive,proto3" json:"io_wait_time_recursive,omitempty"`
+ IoMergedRecursive []*BlkIOEntry `protobuf:"bytes,6,rep,name=io_merged_recursive,json=ioMergedRecursive,proto3" json:"io_merged_recursive,omitempty"`
+ IoTimeRecursive []*BlkIOEntry `protobuf:"bytes,7,rep,name=io_time_recursive,json=ioTimeRecursive,proto3" json:"io_time_recursive,omitempty"`
+ SectorsRecursive []*BlkIOEntry `protobuf:"bytes,8,rep,name=sectors_recursive,json=sectorsRecursive,proto3" json:"sectors_recursive,omitempty"`
+}
+
+func (x *BlkIOStat) Reset() {
+ *x = BlkIOStat{}
+ if protoimpl.UnsafeEnabled {
+ mi := &file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_msgTypes[9]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
+ }
+}
+
+func (x *BlkIOStat) String() string {
+ return protoimpl.X.MessageStringOf(x)
+}
+
+func (*BlkIOStat) ProtoMessage() {}
+
+func (x *BlkIOStat) ProtoReflect() protoreflect.Message {
+ mi := &file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_msgTypes[9]
+ if protoimpl.UnsafeEnabled && x != nil {
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ if ms.LoadMessageInfo() == nil {
+ ms.StoreMessageInfo(mi)
+ }
+ return ms
+ }
+ return mi.MessageOf(x)
+}
+
+// Deprecated: Use BlkIOStat.ProtoReflect.Descriptor instead.
+func (*BlkIOStat) Descriptor() ([]byte, []int) {
+ return file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_rawDescGZIP(), []int{9}
+}
+
+func (x *BlkIOStat) GetIoServiceBytesRecursive() []*BlkIOEntry {
+ if x != nil {
+ return x.IoServiceBytesRecursive
+ }
+ return nil
+}
+
+func (x *BlkIOStat) GetIoServicedRecursive() []*BlkIOEntry {
+ if x != nil {
+ return x.IoServicedRecursive
+ }
+ return nil
+}
+
+func (x *BlkIOStat) GetIoQueuedRecursive() []*BlkIOEntry {
+ if x != nil {
+ return x.IoQueuedRecursive
+ }
+ return nil
+}
+
+func (x *BlkIOStat) GetIoServiceTimeRecursive() []*BlkIOEntry {
+ if x != nil {
+ return x.IoServiceTimeRecursive
+ }
+ return nil
+}
+
+func (x *BlkIOStat) GetIoWaitTimeRecursive() []*BlkIOEntry {
+ if x != nil {
+ return x.IoWaitTimeRecursive
+ }
+ return nil
+}
+
+func (x *BlkIOStat) GetIoMergedRecursive() []*BlkIOEntry {
+ if x != nil {
+ return x.IoMergedRecursive
+ }
+ return nil
+}
+
+func (x *BlkIOStat) GetIoTimeRecursive() []*BlkIOEntry {
+ if x != nil {
+ return x.IoTimeRecursive
+ }
+ return nil
+}
+
+func (x *BlkIOStat) GetSectorsRecursive() []*BlkIOEntry {
+ if x != nil {
+ return x.SectorsRecursive
+ }
+ return nil
+}
+
+type BlkIOEntry struct {
+ state protoimpl.MessageState
+ sizeCache protoimpl.SizeCache
+ unknownFields protoimpl.UnknownFields
+
+ Op string `protobuf:"bytes,1,opt,name=op,proto3" json:"op,omitempty"`
+ Device string `protobuf:"bytes,2,opt,name=device,proto3" json:"device,omitempty"`
+ Major uint64 `protobuf:"varint,3,opt,name=major,proto3" json:"major,omitempty"`
+ Minor uint64 `protobuf:"varint,4,opt,name=minor,proto3" json:"minor,omitempty"`
+ Value uint64 `protobuf:"varint,5,opt,name=value,proto3" json:"value,omitempty"`
+}
+
+func (x *BlkIOEntry) Reset() {
+ *x = BlkIOEntry{}
+ if protoimpl.UnsafeEnabled {
+ mi := &file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_msgTypes[10]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
+ }
+}
+
+func (x *BlkIOEntry) String() string {
+ return protoimpl.X.MessageStringOf(x)
+}
+
+func (*BlkIOEntry) ProtoMessage() {}
+
+func (x *BlkIOEntry) ProtoReflect() protoreflect.Message {
+ mi := &file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_msgTypes[10]
+ if protoimpl.UnsafeEnabled && x != nil {
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ if ms.LoadMessageInfo() == nil {
+ ms.StoreMessageInfo(mi)
+ }
+ return ms
+ }
+ return mi.MessageOf(x)
+}
+
+// Deprecated: Use BlkIOEntry.ProtoReflect.Descriptor instead.
+func (*BlkIOEntry) Descriptor() ([]byte, []int) {
+ return file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_rawDescGZIP(), []int{10}
+}
+
+func (x *BlkIOEntry) GetOp() string {
+ if x != nil {
+ return x.Op
+ }
+ return ""
+}
+
+func (x *BlkIOEntry) GetDevice() string {
+ if x != nil {
+ return x.Device
+ }
+ return ""
+}
+
+func (x *BlkIOEntry) GetMajor() uint64 {
+ if x != nil {
+ return x.Major
+ }
+ return 0
+}
+
+func (x *BlkIOEntry) GetMinor() uint64 {
+ if x != nil {
+ return x.Minor
+ }
+ return 0
+}
+
+func (x *BlkIOEntry) GetValue() uint64 {
+ if x != nil {
+ return x.Value
+ }
+ return 0
+}
+
+type RdmaStat struct {
+ state protoimpl.MessageState
+ sizeCache protoimpl.SizeCache
+ unknownFields protoimpl.UnknownFields
+
+ Current []*RdmaEntry `protobuf:"bytes,1,rep,name=current,proto3" json:"current,omitempty"`
+ Limit []*RdmaEntry `protobuf:"bytes,2,rep,name=limit,proto3" json:"limit,omitempty"`
+}
+
+func (x *RdmaStat) Reset() {
+ *x = RdmaStat{}
+ if protoimpl.UnsafeEnabled {
+ mi := &file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_msgTypes[11]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
+ }
+}
+
+func (x *RdmaStat) String() string {
+ return protoimpl.X.MessageStringOf(x)
+}
+
+func (*RdmaStat) ProtoMessage() {}
+
+func (x *RdmaStat) ProtoReflect() protoreflect.Message {
+ mi := &file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_msgTypes[11]
+ if protoimpl.UnsafeEnabled && x != nil {
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ if ms.LoadMessageInfo() == nil {
+ ms.StoreMessageInfo(mi)
+ }
+ return ms
+ }
+ return mi.MessageOf(x)
+}
+
+// Deprecated: Use RdmaStat.ProtoReflect.Descriptor instead.
+func (*RdmaStat) Descriptor() ([]byte, []int) {
+ return file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_rawDescGZIP(), []int{11}
+}
+
+func (x *RdmaStat) GetCurrent() []*RdmaEntry {
+ if x != nil {
+ return x.Current
+ }
+ return nil
+}
+
+func (x *RdmaStat) GetLimit() []*RdmaEntry {
+ if x != nil {
+ return x.Limit
+ }
+ return nil
+}
+
+type RdmaEntry struct {
+ state protoimpl.MessageState
+ sizeCache protoimpl.SizeCache
+ unknownFields protoimpl.UnknownFields
+
+ Device string `protobuf:"bytes,1,opt,name=device,proto3" json:"device,omitempty"`
+ HcaHandles uint32 `protobuf:"varint,2,opt,name=hca_handles,json=hcaHandles,proto3" json:"hca_handles,omitempty"`
+ HcaObjects uint32 `protobuf:"varint,3,opt,name=hca_objects,json=hcaObjects,proto3" json:"hca_objects,omitempty"`
+}
+
+func (x *RdmaEntry) Reset() {
+ *x = RdmaEntry{}
+ if protoimpl.UnsafeEnabled {
+ mi := &file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_msgTypes[12]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
+ }
+}
+
+func (x *RdmaEntry) String() string {
+ return protoimpl.X.MessageStringOf(x)
+}
+
+func (*RdmaEntry) ProtoMessage() {}
+
+func (x *RdmaEntry) ProtoReflect() protoreflect.Message {
+ mi := &file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_msgTypes[12]
+ if protoimpl.UnsafeEnabled && x != nil {
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ if ms.LoadMessageInfo() == nil {
+ ms.StoreMessageInfo(mi)
+ }
+ return ms
+ }
+ return mi.MessageOf(x)
+}
+
+// Deprecated: Use RdmaEntry.ProtoReflect.Descriptor instead.
+func (*RdmaEntry) Descriptor() ([]byte, []int) {
+ return file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_rawDescGZIP(), []int{12}
+}
+
+func (x *RdmaEntry) GetDevice() string {
+ if x != nil {
+ return x.Device
+ }
+ return ""
+}
+
+func (x *RdmaEntry) GetHcaHandles() uint32 {
+ if x != nil {
+ return x.HcaHandles
+ }
+ return 0
+}
+
+func (x *RdmaEntry) GetHcaObjects() uint32 {
+ if x != nil {
+ return x.HcaObjects
+ }
+ return 0
+}
+
+type NetworkStat struct {
+ state protoimpl.MessageState
+ sizeCache protoimpl.SizeCache
+ unknownFields protoimpl.UnknownFields
+
+ Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
+ RxBytes uint64 `protobuf:"varint,2,opt,name=rx_bytes,json=rxBytes,proto3" json:"rx_bytes,omitempty"`
+ RxPackets uint64 `protobuf:"varint,3,opt,name=rx_packets,json=rxPackets,proto3" json:"rx_packets,omitempty"`
+ RxErrors uint64 `protobuf:"varint,4,opt,name=rx_errors,json=rxErrors,proto3" json:"rx_errors,omitempty"`
+ RxDropped uint64 `protobuf:"varint,5,opt,name=rx_dropped,json=rxDropped,proto3" json:"rx_dropped,omitempty"`
+ TxBytes uint64 `protobuf:"varint,6,opt,name=tx_bytes,json=txBytes,proto3" json:"tx_bytes,omitempty"`
+ TxPackets uint64 `protobuf:"varint,7,opt,name=tx_packets,json=txPackets,proto3" json:"tx_packets,omitempty"`
+ TxErrors uint64 `protobuf:"varint,8,opt,name=tx_errors,json=txErrors,proto3" json:"tx_errors,omitempty"`
+ TxDropped uint64 `protobuf:"varint,9,opt,name=tx_dropped,json=txDropped,proto3" json:"tx_dropped,omitempty"`
+}
+
+func (x *NetworkStat) Reset() {
+ *x = NetworkStat{}
+ if protoimpl.UnsafeEnabled {
+ mi := &file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_msgTypes[13]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
+ }
+}
+
+func (x *NetworkStat) String() string {
+ return protoimpl.X.MessageStringOf(x)
+}
+
+func (*NetworkStat) ProtoMessage() {}
+
+func (x *NetworkStat) ProtoReflect() protoreflect.Message {
+ mi := &file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_msgTypes[13]
+ if protoimpl.UnsafeEnabled && x != nil {
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ if ms.LoadMessageInfo() == nil {
+ ms.StoreMessageInfo(mi)
+ }
+ return ms
+ }
+ return mi.MessageOf(x)
+}
+
+// Deprecated: Use NetworkStat.ProtoReflect.Descriptor instead.
+func (*NetworkStat) Descriptor() ([]byte, []int) {
+ return file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_rawDescGZIP(), []int{13}
+}
+
+func (x *NetworkStat) GetName() string {
+ if x != nil {
+ return x.Name
+ }
+ return ""
+}
+
+func (x *NetworkStat) GetRxBytes() uint64 {
+ if x != nil {
+ return x.RxBytes
+ }
+ return 0
+}
+
+func (x *NetworkStat) GetRxPackets() uint64 {
+ if x != nil {
+ return x.RxPackets
+ }
+ return 0
+}
+
+func (x *NetworkStat) GetRxErrors() uint64 {
+ if x != nil {
+ return x.RxErrors
+ }
+ return 0
+}
+
+func (x *NetworkStat) GetRxDropped() uint64 {
+ if x != nil {
+ return x.RxDropped
+ }
+ return 0
+}
+
+func (x *NetworkStat) GetTxBytes() uint64 {
+ if x != nil {
+ return x.TxBytes
+ }
+ return 0
+}
+
+func (x *NetworkStat) GetTxPackets() uint64 {
+ if x != nil {
+ return x.TxPackets
+ }
+ return 0
+}
+
+func (x *NetworkStat) GetTxErrors() uint64 {
+ if x != nil {
+ return x.TxErrors
+ }
+ return 0
+}
+
+func (x *NetworkStat) GetTxDropped() uint64 {
+ if x != nil {
+ return x.TxDropped
+ }
+ return 0
+}
+
+// CgroupStats exports per-cgroup statistics.
+type CgroupStats struct {
+ state protoimpl.MessageState
+ sizeCache protoimpl.SizeCache
+ unknownFields protoimpl.UnknownFields
+
+ // number of tasks sleeping
+ NrSleeping uint64 `protobuf:"varint,1,opt,name=nr_sleeping,json=nrSleeping,proto3" json:"nr_sleeping,omitempty"`
+ // number of tasks running
+ NrRunning uint64 `protobuf:"varint,2,opt,name=nr_running,json=nrRunning,proto3" json:"nr_running,omitempty"`
+ // number of tasks in stopped state
+ NrStopped uint64 `protobuf:"varint,3,opt,name=nr_stopped,json=nrStopped,proto3" json:"nr_stopped,omitempty"`
+ // number of tasks in uninterruptible state
+ NrUninterruptible uint64 `protobuf:"varint,4,opt,name=nr_uninterruptible,json=nrUninterruptible,proto3" json:"nr_uninterruptible,omitempty"`
+ // number of tasks waiting on IO
+ NrIoWait uint64 `protobuf:"varint,5,opt,name=nr_io_wait,json=nrIoWait,proto3" json:"nr_io_wait,omitempty"`
+}
+
+func (x *CgroupStats) Reset() {
+ *x = CgroupStats{}
+ if protoimpl.UnsafeEnabled {
+ mi := &file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_msgTypes[14]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
+ }
+}
+
+func (x *CgroupStats) String() string {
+ return protoimpl.X.MessageStringOf(x)
+}
+
+func (*CgroupStats) ProtoMessage() {}
+
+func (x *CgroupStats) ProtoReflect() protoreflect.Message {
+ mi := &file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_msgTypes[14]
+ if protoimpl.UnsafeEnabled && x != nil {
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ if ms.LoadMessageInfo() == nil {
+ ms.StoreMessageInfo(mi)
+ }
+ return ms
+ }
+ return mi.MessageOf(x)
+}
+
+// Deprecated: Use CgroupStats.ProtoReflect.Descriptor instead.
+func (*CgroupStats) Descriptor() ([]byte, []int) {
+ return file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_rawDescGZIP(), []int{14}
+}
+
+func (x *CgroupStats) GetNrSleeping() uint64 {
+ if x != nil {
+ return x.NrSleeping
+ }
+ return 0
+}
+
+func (x *CgroupStats) GetNrRunning() uint64 {
+ if x != nil {
+ return x.NrRunning
+ }
+ return 0
+}
+
+func (x *CgroupStats) GetNrStopped() uint64 {
+ if x != nil {
+ return x.NrStopped
+ }
+ return 0
+}
+
+func (x *CgroupStats) GetNrUninterruptible() uint64 {
+ if x != nil {
+ return x.NrUninterruptible
+ }
+ return 0
+}
+
+func (x *CgroupStats) GetNrIoWait() uint64 {
+ if x != nil {
+ return x.NrIoWait
+ }
+ return 0
+}
+
+var File_github_com_containerd_cgroups_cgroup1_stats_metrics_proto protoreflect.FileDescriptor
+
+var file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_rawDesc = []byte{
+ 0x0a, 0x39, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x63, 0x6f, 0x6e,
+ 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x64, 0x2f, 0x63, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x73, 0x2f,
+ 0x63, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x31, 0x2f, 0x73, 0x74, 0x61, 0x74, 0x73, 0x2f, 0x6d, 0x65,
+ 0x74, 0x72, 0x69, 0x63, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x18, 0x69, 0x6f, 0x2e,
+ 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x64, 0x2e, 0x63, 0x67, 0x72, 0x6f, 0x75,
+ 0x70, 0x73, 0x2e, 0x76, 0x31, 0x22, 0xcd, 0x04, 0x0a, 0x07, 0x4d, 0x65, 0x74, 0x72, 0x69, 0x63,
+ 0x73, 0x12, 0x3f, 0x0a, 0x07, 0x68, 0x75, 0x67, 0x65, 0x74, 0x6c, 0x62, 0x18, 0x01, 0x20, 0x03,
+ 0x28, 0x0b, 0x32, 0x25, 0x2e, 0x69, 0x6f, 0x2e, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65,
+ 0x72, 0x64, 0x2e, 0x63, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x48, 0x75,
+ 0x67, 0x65, 0x74, 0x6c, 0x62, 0x53, 0x74, 0x61, 0x74, 0x52, 0x07, 0x68, 0x75, 0x67, 0x65, 0x74,
+ 0x6c, 0x62, 0x12, 0x36, 0x0a, 0x04, 0x70, 0x69, 0x64, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b,
+ 0x32, 0x22, 0x2e, 0x69, 0x6f, 0x2e, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x64,
+ 0x2e, 0x63, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x50, 0x69, 0x64, 0x73,
+ 0x53, 0x74, 0x61, 0x74, 0x52, 0x04, 0x70, 0x69, 0x64, 0x73, 0x12, 0x33, 0x0a, 0x03, 0x63, 0x70,
+ 0x75, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x69, 0x6f, 0x2e, 0x63, 0x6f, 0x6e,
+ 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x64, 0x2e, 0x63, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x73, 0x2e,
+ 0x76, 0x31, 0x2e, 0x43, 0x50, 0x55, 0x53, 0x74, 0x61, 0x74, 0x52, 0x03, 0x63, 0x70, 0x75, 0x12,
+ 0x3c, 0x0a, 0x06, 0x6d, 0x65, 0x6d, 0x6f, 0x72, 0x79, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0b, 0x32,
+ 0x24, 0x2e, 0x69, 0x6f, 0x2e, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x64, 0x2e,
+ 0x63, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x65, 0x6d, 0x6f, 0x72,
+ 0x79, 0x53, 0x74, 0x61, 0x74, 0x52, 0x06, 0x6d, 0x65, 0x6d, 0x6f, 0x72, 0x79, 0x12, 0x39, 0x0a,
+ 0x05, 0x62, 0x6c, 0x6b, 0x69, 0x6f, 0x18, 0x05, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x23, 0x2e, 0x69,
+ 0x6f, 0x2e, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x64, 0x2e, 0x63, 0x67, 0x72,
+ 0x6f, 0x75, 0x70, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x42, 0x6c, 0x6b, 0x49, 0x4f, 0x53, 0x74, 0x61,
+ 0x74, 0x52, 0x05, 0x62, 0x6c, 0x6b, 0x69, 0x6f, 0x12, 0x36, 0x0a, 0x04, 0x72, 0x64, 0x6d, 0x61,
+ 0x18, 0x06, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x22, 0x2e, 0x69, 0x6f, 0x2e, 0x63, 0x6f, 0x6e, 0x74,
+ 0x61, 0x69, 0x6e, 0x65, 0x72, 0x64, 0x2e, 0x63, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x73, 0x2e, 0x76,
+ 0x31, 0x2e, 0x52, 0x64, 0x6d, 0x61, 0x53, 0x74, 0x61, 0x74, 0x52, 0x04, 0x72, 0x64, 0x6d, 0x61,
+ 0x12, 0x3f, 0x0a, 0x07, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x18, 0x07, 0x20, 0x03, 0x28,
+ 0x0b, 0x32, 0x25, 0x2e, 0x69, 0x6f, 0x2e, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72,
+ 0x64, 0x2e, 0x63, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x4e, 0x65, 0x74,
+ 0x77, 0x6f, 0x72, 0x6b, 0x53, 0x74, 0x61, 0x74, 0x52, 0x07, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72,
+ 0x6b, 0x12, 0x48, 0x0a, 0x0c, 0x63, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x5f, 0x73, 0x74, 0x61, 0x74,
+ 0x73, 0x18, 0x08, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x25, 0x2e, 0x69, 0x6f, 0x2e, 0x63, 0x6f, 0x6e,
+ 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x64, 0x2e, 0x63, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x73, 0x2e,
+ 0x76, 0x31, 0x2e, 0x43, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x53, 0x74, 0x61, 0x74, 0x73, 0x52, 0x0b,
+ 0x63, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x53, 0x74, 0x61, 0x74, 0x73, 0x12, 0x58, 0x0a, 0x12, 0x6d,
+ 0x65, 0x6d, 0x6f, 0x72, 0x79, 0x5f, 0x6f, 0x6f, 0x6d, 0x5f, 0x63, 0x6f, 0x6e, 0x74, 0x72, 0x6f,
+ 0x6c, 0x18, 0x09, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x2a, 0x2e, 0x69, 0x6f, 0x2e, 0x63, 0x6f, 0x6e,
+ 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x64, 0x2e, 0x63, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x73, 0x2e,
+ 0x76, 0x31, 0x2e, 0x4d, 0x65, 0x6d, 0x6f, 0x72, 0x79, 0x4f, 0x6f, 0x6d, 0x43, 0x6f, 0x6e, 0x74,
+ 0x72, 0x6f, 0x6c, 0x52, 0x10, 0x6d, 0x65, 0x6d, 0x6f, 0x72, 0x79, 0x4f, 0x6f, 0x6d, 0x43, 0x6f,
+ 0x6e, 0x74, 0x72, 0x6f, 0x6c, 0x22, 0x6b, 0x0a, 0x0b, 0x48, 0x75, 0x67, 0x65, 0x74, 0x6c, 0x62,
+ 0x53, 0x74, 0x61, 0x74, 0x12, 0x14, 0x0a, 0x05, 0x75, 0x73, 0x61, 0x67, 0x65, 0x18, 0x01, 0x20,
+ 0x01, 0x28, 0x04, 0x52, 0x05, 0x75, 0x73, 0x61, 0x67, 0x65, 0x12, 0x10, 0x0a, 0x03, 0x6d, 0x61,
+ 0x78, 0x18, 0x02, 0x20, 0x01, 0x28, 0x04, 0x52, 0x03, 0x6d, 0x61, 0x78, 0x12, 0x18, 0x0a, 0x07,
+ 0x66, 0x61, 0x69, 0x6c, 0x63, 0x6e, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x04, 0x52, 0x07, 0x66,
+ 0x61, 0x69, 0x6c, 0x63, 0x6e, 0x74, 0x12, 0x1a, 0x0a, 0x08, 0x70, 0x61, 0x67, 0x65, 0x73, 0x69,
+ 0x7a, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x67, 0x65, 0x73, 0x69,
+ 0x7a, 0x65, 0x22, 0x3a, 0x0a, 0x08, 0x50, 0x69, 0x64, 0x73, 0x53, 0x74, 0x61, 0x74, 0x12, 0x18,
+ 0x0a, 0x07, 0x63, 0x75, 0x72, 0x72, 0x65, 0x6e, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x04, 0x52,
+ 0x07, 0x63, 0x75, 0x72, 0x72, 0x65, 0x6e, 0x74, 0x12, 0x14, 0x0a, 0x05, 0x6c, 0x69, 0x6d, 0x69,
+ 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x04, 0x52, 0x05, 0x6c, 0x69, 0x6d, 0x69, 0x74, 0x22, 0x87,
+ 0x01, 0x0a, 0x07, 0x43, 0x50, 0x55, 0x53, 0x74, 0x61, 0x74, 0x12, 0x38, 0x0a, 0x05, 0x75, 0x73,
+ 0x61, 0x67, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x22, 0x2e, 0x69, 0x6f, 0x2e, 0x63,
+ 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x64, 0x2e, 0x63, 0x67, 0x72, 0x6f, 0x75, 0x70,
+ 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x50, 0x55, 0x55, 0x73, 0x61, 0x67, 0x65, 0x52, 0x05, 0x75,
+ 0x73, 0x61, 0x67, 0x65, 0x12, 0x42, 0x0a, 0x0a, 0x74, 0x68, 0x72, 0x6f, 0x74, 0x74, 0x6c, 0x69,
+ 0x6e, 0x67, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x22, 0x2e, 0x69, 0x6f, 0x2e, 0x63, 0x6f,
+ 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x64, 0x2e, 0x63, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x73,
+ 0x2e, 0x76, 0x31, 0x2e, 0x54, 0x68, 0x72, 0x6f, 0x74, 0x74, 0x6c, 0x65, 0x52, 0x0a, 0x74, 0x68,
+ 0x72, 0x6f, 0x74, 0x74, 0x6c, 0x69, 0x6e, 0x67, 0x22, 0x65, 0x0a, 0x08, 0x43, 0x50, 0x55, 0x55,
+ 0x73, 0x61, 0x67, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x74, 0x6f, 0x74, 0x61, 0x6c, 0x18, 0x01, 0x20,
+ 0x01, 0x28, 0x04, 0x52, 0x05, 0x74, 0x6f, 0x74, 0x61, 0x6c, 0x12, 0x16, 0x0a, 0x06, 0x6b, 0x65,
+ 0x72, 0x6e, 0x65, 0x6c, 0x18, 0x02, 0x20, 0x01, 0x28, 0x04, 0x52, 0x06, 0x6b, 0x65, 0x72, 0x6e,
+ 0x65, 0x6c, 0x12, 0x12, 0x0a, 0x04, 0x75, 0x73, 0x65, 0x72, 0x18, 0x03, 0x20, 0x01, 0x28, 0x04,
+ 0x52, 0x04, 0x75, 0x73, 0x65, 0x72, 0x12, 0x17, 0x0a, 0x07, 0x70, 0x65, 0x72, 0x5f, 0x63, 0x70,
+ 0x75, 0x18, 0x04, 0x20, 0x03, 0x28, 0x04, 0x52, 0x06, 0x70, 0x65, 0x72, 0x43, 0x70, 0x75, 0x22,
+ 0x78, 0x0a, 0x08, 0x54, 0x68, 0x72, 0x6f, 0x74, 0x74, 0x6c, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x70,
+ 0x65, 0x72, 0x69, 0x6f, 0x64, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x04, 0x52, 0x07, 0x70, 0x65,
+ 0x72, 0x69, 0x6f, 0x64, 0x73, 0x12, 0x2b, 0x0a, 0x11, 0x74, 0x68, 0x72, 0x6f, 0x74, 0x74, 0x6c,
+ 0x65, 0x64, 0x5f, 0x70, 0x65, 0x72, 0x69, 0x6f, 0x64, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x04,
+ 0x52, 0x10, 0x74, 0x68, 0x72, 0x6f, 0x74, 0x74, 0x6c, 0x65, 0x64, 0x50, 0x65, 0x72, 0x69, 0x6f,
+ 0x64, 0x73, 0x12, 0x25, 0x0a, 0x0e, 0x74, 0x68, 0x72, 0x6f, 0x74, 0x74, 0x6c, 0x65, 0x64, 0x5f,
+ 0x74, 0x69, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x04, 0x52, 0x0d, 0x74, 0x68, 0x72, 0x6f,
+ 0x74, 0x74, 0x6c, 0x65, 0x64, 0x54, 0x69, 0x6d, 0x65, 0x22, 0x94, 0x0b, 0x0a, 0x0a, 0x4d, 0x65,
+ 0x6d, 0x6f, 0x72, 0x79, 0x53, 0x74, 0x61, 0x74, 0x12, 0x14, 0x0a, 0x05, 0x63, 0x61, 0x63, 0x68,
+ 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x04, 0x52, 0x05, 0x63, 0x61, 0x63, 0x68, 0x65, 0x12, 0x10,
+ 0x0a, 0x03, 0x72, 0x73, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x04, 0x52, 0x03, 0x72, 0x73, 0x73,
+ 0x12, 0x19, 0x0a, 0x08, 0x72, 0x73, 0x73, 0x5f, 0x68, 0x75, 0x67, 0x65, 0x18, 0x03, 0x20, 0x01,
+ 0x28, 0x04, 0x52, 0x07, 0x72, 0x73, 0x73, 0x48, 0x75, 0x67, 0x65, 0x12, 0x1f, 0x0a, 0x0b, 0x6d,
+ 0x61, 0x70, 0x70, 0x65, 0x64, 0x5f, 0x66, 0x69, 0x6c, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x04,
+ 0x52, 0x0a, 0x6d, 0x61, 0x70, 0x70, 0x65, 0x64, 0x46, 0x69, 0x6c, 0x65, 0x12, 0x14, 0x0a, 0x05,
+ 0x64, 0x69, 0x72, 0x74, 0x79, 0x18, 0x05, 0x20, 0x01, 0x28, 0x04, 0x52, 0x05, 0x64, 0x69, 0x72,
+ 0x74, 0x79, 0x12, 0x1c, 0x0a, 0x09, 0x77, 0x72, 0x69, 0x74, 0x65, 0x62, 0x61, 0x63, 0x6b, 0x18,
+ 0x06, 0x20, 0x01, 0x28, 0x04, 0x52, 0x09, 0x77, 0x72, 0x69, 0x74, 0x65, 0x62, 0x61, 0x63, 0x6b,
+ 0x12, 0x18, 0x0a, 0x08, 0x70, 0x67, 0x5f, 0x70, 0x67, 0x5f, 0x69, 0x6e, 0x18, 0x07, 0x20, 0x01,
+ 0x28, 0x04, 0x52, 0x06, 0x70, 0x67, 0x50, 0x67, 0x49, 0x6e, 0x12, 0x1a, 0x0a, 0x09, 0x70, 0x67,
+ 0x5f, 0x70, 0x67, 0x5f, 0x6f, 0x75, 0x74, 0x18, 0x08, 0x20, 0x01, 0x28, 0x04, 0x52, 0x07, 0x70,
+ 0x67, 0x50, 0x67, 0x4f, 0x75, 0x74, 0x12, 0x19, 0x0a, 0x08, 0x70, 0x67, 0x5f, 0x66, 0x61, 0x75,
+ 0x6c, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x04, 0x52, 0x07, 0x70, 0x67, 0x46, 0x61, 0x75, 0x6c,
+ 0x74, 0x12, 0x20, 0x0a, 0x0c, 0x70, 0x67, 0x5f, 0x6d, 0x61, 0x6a, 0x5f, 0x66, 0x61, 0x75, 0x6c,
+ 0x74, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x04, 0x52, 0x0a, 0x70, 0x67, 0x4d, 0x61, 0x6a, 0x46, 0x61,
+ 0x75, 0x6c, 0x74, 0x12, 0x23, 0x0a, 0x0d, 0x69, 0x6e, 0x61, 0x63, 0x74, 0x69, 0x76, 0x65, 0x5f,
+ 0x61, 0x6e, 0x6f, 0x6e, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x04, 0x52, 0x0c, 0x69, 0x6e, 0x61, 0x63,
+ 0x74, 0x69, 0x76, 0x65, 0x41, 0x6e, 0x6f, 0x6e, 0x12, 0x1f, 0x0a, 0x0b, 0x61, 0x63, 0x74, 0x69,
+ 0x76, 0x65, 0x5f, 0x61, 0x6e, 0x6f, 0x6e, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x04, 0x52, 0x0a, 0x61,
+ 0x63, 0x74, 0x69, 0x76, 0x65, 0x41, 0x6e, 0x6f, 0x6e, 0x12, 0x23, 0x0a, 0x0d, 0x69, 0x6e, 0x61,
+ 0x63, 0x74, 0x69, 0x76, 0x65, 0x5f, 0x66, 0x69, 0x6c, 0x65, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x04,
+ 0x52, 0x0c, 0x69, 0x6e, 0x61, 0x63, 0x74, 0x69, 0x76, 0x65, 0x46, 0x69, 0x6c, 0x65, 0x12, 0x1f,
+ 0x0a, 0x0b, 0x61, 0x63, 0x74, 0x69, 0x76, 0x65, 0x5f, 0x66, 0x69, 0x6c, 0x65, 0x18, 0x0e, 0x20,
+ 0x01, 0x28, 0x04, 0x52, 0x0a, 0x61, 0x63, 0x74, 0x69, 0x76, 0x65, 0x46, 0x69, 0x6c, 0x65, 0x12,
+ 0x20, 0x0a, 0x0b, 0x75, 0x6e, 0x65, 0x76, 0x69, 0x63, 0x74, 0x61, 0x62, 0x6c, 0x65, 0x18, 0x0f,
+ 0x20, 0x01, 0x28, 0x04, 0x52, 0x0b, 0x75, 0x6e, 0x65, 0x76, 0x69, 0x63, 0x74, 0x61, 0x62, 0x6c,
+ 0x65, 0x12, 0x3a, 0x0a, 0x19, 0x68, 0x69, 0x65, 0x72, 0x61, 0x72, 0x63, 0x68, 0x69, 0x63, 0x61,
+ 0x6c, 0x5f, 0x6d, 0x65, 0x6d, 0x6f, 0x72, 0x79, 0x5f, 0x6c, 0x69, 0x6d, 0x69, 0x74, 0x18, 0x10,
+ 0x20, 0x01, 0x28, 0x04, 0x52, 0x17, 0x68, 0x69, 0x65, 0x72, 0x61, 0x72, 0x63, 0x68, 0x69, 0x63,
+ 0x61, 0x6c, 0x4d, 0x65, 0x6d, 0x6f, 0x72, 0x79, 0x4c, 0x69, 0x6d, 0x69, 0x74, 0x12, 0x36, 0x0a,
+ 0x17, 0x68, 0x69, 0x65, 0x72, 0x61, 0x72, 0x63, 0x68, 0x69, 0x63, 0x61, 0x6c, 0x5f, 0x73, 0x77,
+ 0x61, 0x70, 0x5f, 0x6c, 0x69, 0x6d, 0x69, 0x74, 0x18, 0x11, 0x20, 0x01, 0x28, 0x04, 0x52, 0x15,
+ 0x68, 0x69, 0x65, 0x72, 0x61, 0x72, 0x63, 0x68, 0x69, 0x63, 0x61, 0x6c, 0x53, 0x77, 0x61, 0x70,
+ 0x4c, 0x69, 0x6d, 0x69, 0x74, 0x12, 0x1f, 0x0a, 0x0b, 0x74, 0x6f, 0x74, 0x61, 0x6c, 0x5f, 0x63,
+ 0x61, 0x63, 0x68, 0x65, 0x18, 0x12, 0x20, 0x01, 0x28, 0x04, 0x52, 0x0a, 0x74, 0x6f, 0x74, 0x61,
+ 0x6c, 0x43, 0x61, 0x63, 0x68, 0x65, 0x12, 0x1b, 0x0a, 0x09, 0x74, 0x6f, 0x74, 0x61, 0x6c, 0x5f,
+ 0x72, 0x73, 0x73, 0x18, 0x13, 0x20, 0x01, 0x28, 0x04, 0x52, 0x08, 0x74, 0x6f, 0x74, 0x61, 0x6c,
+ 0x52, 0x73, 0x73, 0x12, 0x24, 0x0a, 0x0e, 0x74, 0x6f, 0x74, 0x61, 0x6c, 0x5f, 0x72, 0x73, 0x73,
+ 0x5f, 0x68, 0x75, 0x67, 0x65, 0x18, 0x14, 0x20, 0x01, 0x28, 0x04, 0x52, 0x0c, 0x74, 0x6f, 0x74,
+ 0x61, 0x6c, 0x52, 0x73, 0x73, 0x48, 0x75, 0x67, 0x65, 0x12, 0x2a, 0x0a, 0x11, 0x74, 0x6f, 0x74,
+ 0x61, 0x6c, 0x5f, 0x6d, 0x61, 0x70, 0x70, 0x65, 0x64, 0x5f, 0x66, 0x69, 0x6c, 0x65, 0x18, 0x15,
+ 0x20, 0x01, 0x28, 0x04, 0x52, 0x0f, 0x74, 0x6f, 0x74, 0x61, 0x6c, 0x4d, 0x61, 0x70, 0x70, 0x65,
+ 0x64, 0x46, 0x69, 0x6c, 0x65, 0x12, 0x1f, 0x0a, 0x0b, 0x74, 0x6f, 0x74, 0x61, 0x6c, 0x5f, 0x64,
+ 0x69, 0x72, 0x74, 0x79, 0x18, 0x16, 0x20, 0x01, 0x28, 0x04, 0x52, 0x0a, 0x74, 0x6f, 0x74, 0x61,
+ 0x6c, 0x44, 0x69, 0x72, 0x74, 0x79, 0x12, 0x27, 0x0a, 0x0f, 0x74, 0x6f, 0x74, 0x61, 0x6c, 0x5f,
+ 0x77, 0x72, 0x69, 0x74, 0x65, 0x62, 0x61, 0x63, 0x6b, 0x18, 0x17, 0x20, 0x01, 0x28, 0x04, 0x52,
+ 0x0e, 0x74, 0x6f, 0x74, 0x61, 0x6c, 0x57, 0x72, 0x69, 0x74, 0x65, 0x62, 0x61, 0x63, 0x6b, 0x12,
+ 0x23, 0x0a, 0x0e, 0x74, 0x6f, 0x74, 0x61, 0x6c, 0x5f, 0x70, 0x67, 0x5f, 0x70, 0x67, 0x5f, 0x69,
+ 0x6e, 0x18, 0x18, 0x20, 0x01, 0x28, 0x04, 0x52, 0x0b, 0x74, 0x6f, 0x74, 0x61, 0x6c, 0x50, 0x67,
+ 0x50, 0x67, 0x49, 0x6e, 0x12, 0x25, 0x0a, 0x0f, 0x74, 0x6f, 0x74, 0x61, 0x6c, 0x5f, 0x70, 0x67,
+ 0x5f, 0x70, 0x67, 0x5f, 0x6f, 0x75, 0x74, 0x18, 0x19, 0x20, 0x01, 0x28, 0x04, 0x52, 0x0c, 0x74,
+ 0x6f, 0x74, 0x61, 0x6c, 0x50, 0x67, 0x50, 0x67, 0x4f, 0x75, 0x74, 0x12, 0x24, 0x0a, 0x0e, 0x74,
+ 0x6f, 0x74, 0x61, 0x6c, 0x5f, 0x70, 0x67, 0x5f, 0x66, 0x61, 0x75, 0x6c, 0x74, 0x18, 0x1a, 0x20,
+ 0x01, 0x28, 0x04, 0x52, 0x0c, 0x74, 0x6f, 0x74, 0x61, 0x6c, 0x50, 0x67, 0x46, 0x61, 0x75, 0x6c,
+ 0x74, 0x12, 0x2b, 0x0a, 0x12, 0x74, 0x6f, 0x74, 0x61, 0x6c, 0x5f, 0x70, 0x67, 0x5f, 0x6d, 0x61,
+ 0x6a, 0x5f, 0x66, 0x61, 0x75, 0x6c, 0x74, 0x18, 0x1b, 0x20, 0x01, 0x28, 0x04, 0x52, 0x0f, 0x74,
+ 0x6f, 0x74, 0x61, 0x6c, 0x50, 0x67, 0x4d, 0x61, 0x6a, 0x46, 0x61, 0x75, 0x6c, 0x74, 0x12, 0x2e,
+ 0x0a, 0x13, 0x74, 0x6f, 0x74, 0x61, 0x6c, 0x5f, 0x69, 0x6e, 0x61, 0x63, 0x74, 0x69, 0x76, 0x65,
+ 0x5f, 0x61, 0x6e, 0x6f, 0x6e, 0x18, 0x1c, 0x20, 0x01, 0x28, 0x04, 0x52, 0x11, 0x74, 0x6f, 0x74,
+ 0x61, 0x6c, 0x49, 0x6e, 0x61, 0x63, 0x74, 0x69, 0x76, 0x65, 0x41, 0x6e, 0x6f, 0x6e, 0x12, 0x2a,
+ 0x0a, 0x11, 0x74, 0x6f, 0x74, 0x61, 0x6c, 0x5f, 0x61, 0x63, 0x74, 0x69, 0x76, 0x65, 0x5f, 0x61,
+ 0x6e, 0x6f, 0x6e, 0x18, 0x1d, 0x20, 0x01, 0x28, 0x04, 0x52, 0x0f, 0x74, 0x6f, 0x74, 0x61, 0x6c,
+ 0x41, 0x63, 0x74, 0x69, 0x76, 0x65, 0x41, 0x6e, 0x6f, 0x6e, 0x12, 0x2e, 0x0a, 0x13, 0x74, 0x6f,
+ 0x74, 0x61, 0x6c, 0x5f, 0x69, 0x6e, 0x61, 0x63, 0x74, 0x69, 0x76, 0x65, 0x5f, 0x66, 0x69, 0x6c,
+ 0x65, 0x18, 0x1e, 0x20, 0x01, 0x28, 0x04, 0x52, 0x11, 0x74, 0x6f, 0x74, 0x61, 0x6c, 0x49, 0x6e,
+ 0x61, 0x63, 0x74, 0x69, 0x76, 0x65, 0x46, 0x69, 0x6c, 0x65, 0x12, 0x2a, 0x0a, 0x11, 0x74, 0x6f,
+ 0x74, 0x61, 0x6c, 0x5f, 0x61, 0x63, 0x74, 0x69, 0x76, 0x65, 0x5f, 0x66, 0x69, 0x6c, 0x65, 0x18,
+ 0x1f, 0x20, 0x01, 0x28, 0x04, 0x52, 0x0f, 0x74, 0x6f, 0x74, 0x61, 0x6c, 0x41, 0x63, 0x74, 0x69,
+ 0x76, 0x65, 0x46, 0x69, 0x6c, 0x65, 0x12, 0x2b, 0x0a, 0x11, 0x74, 0x6f, 0x74, 0x61, 0x6c, 0x5f,
+ 0x75, 0x6e, 0x65, 0x76, 0x69, 0x63, 0x74, 0x61, 0x62, 0x6c, 0x65, 0x18, 0x20, 0x20, 0x01, 0x28,
+ 0x04, 0x52, 0x10, 0x74, 0x6f, 0x74, 0x61, 0x6c, 0x55, 0x6e, 0x65, 0x76, 0x69, 0x63, 0x74, 0x61,
+ 0x62, 0x6c, 0x65, 0x12, 0x3b, 0x0a, 0x05, 0x75, 0x73, 0x61, 0x67, 0x65, 0x18, 0x21, 0x20, 0x01,
+ 0x28, 0x0b, 0x32, 0x25, 0x2e, 0x69, 0x6f, 0x2e, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65,
+ 0x72, 0x64, 0x2e, 0x63, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x65,
+ 0x6d, 0x6f, 0x72, 0x79, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x05, 0x75, 0x73, 0x61, 0x67, 0x65,
+ 0x12, 0x39, 0x0a, 0x04, 0x73, 0x77, 0x61, 0x70, 0x18, 0x22, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x25,
+ 0x2e, 0x69, 0x6f, 0x2e, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x64, 0x2e, 0x63,
+ 0x67, 0x72, 0x6f, 0x75, 0x70, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x65, 0x6d, 0x6f, 0x72, 0x79,
+ 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x04, 0x73, 0x77, 0x61, 0x70, 0x12, 0x3d, 0x0a, 0x06, 0x6b,
+ 0x65, 0x72, 0x6e, 0x65, 0x6c, 0x18, 0x23, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x25, 0x2e, 0x69, 0x6f,
+ 0x2e, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x64, 0x2e, 0x63, 0x67, 0x72, 0x6f,
+ 0x75, 0x70, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x65, 0x6d, 0x6f, 0x72, 0x79, 0x45, 0x6e, 0x74,
+ 0x72, 0x79, 0x52, 0x06, 0x6b, 0x65, 0x72, 0x6e, 0x65, 0x6c, 0x12, 0x44, 0x0a, 0x0a, 0x6b, 0x65,
+ 0x72, 0x6e, 0x65, 0x6c, 0x5f, 0x74, 0x63, 0x70, 0x18, 0x24, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x25,
+ 0x2e, 0x69, 0x6f, 0x2e, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x64, 0x2e, 0x63,
+ 0x67, 0x72, 0x6f, 0x75, 0x70, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x65, 0x6d, 0x6f, 0x72, 0x79,
+ 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x09, 0x6b, 0x65, 0x72, 0x6e, 0x65, 0x6c, 0x54, 0x63, 0x70,
+ 0x22, 0x65, 0x0a, 0x0b, 0x4d, 0x65, 0x6d, 0x6f, 0x72, 0x79, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12,
+ 0x14, 0x0a, 0x05, 0x6c, 0x69, 0x6d, 0x69, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x04, 0x52, 0x05,
+ 0x6c, 0x69, 0x6d, 0x69, 0x74, 0x12, 0x14, 0x0a, 0x05, 0x75, 0x73, 0x61, 0x67, 0x65, 0x18, 0x02,
+ 0x20, 0x01, 0x28, 0x04, 0x52, 0x05, 0x75, 0x73, 0x61, 0x67, 0x65, 0x12, 0x10, 0x0a, 0x03, 0x6d,
+ 0x61, 0x78, 0x18, 0x03, 0x20, 0x01, 0x28, 0x04, 0x52, 0x03, 0x6d, 0x61, 0x78, 0x12, 0x18, 0x0a,
+ 0x07, 0x66, 0x61, 0x69, 0x6c, 0x63, 0x6e, 0x74, 0x18, 0x04, 0x20, 0x01, 0x28, 0x04, 0x52, 0x07,
+ 0x66, 0x61, 0x69, 0x6c, 0x63, 0x6e, 0x74, 0x22, 0x74, 0x0a, 0x10, 0x4d, 0x65, 0x6d, 0x6f, 0x72,
+ 0x79, 0x4f, 0x6f, 0x6d, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x6f, 0x6c, 0x12, 0x28, 0x0a, 0x10, 0x6f,
+ 0x6f, 0x6d, 0x5f, 0x6b, 0x69, 0x6c, 0x6c, 0x5f, 0x64, 0x69, 0x73, 0x61, 0x62, 0x6c, 0x65, 0x18,
+ 0x01, 0x20, 0x01, 0x28, 0x04, 0x52, 0x0e, 0x6f, 0x6f, 0x6d, 0x4b, 0x69, 0x6c, 0x6c, 0x44, 0x69,
+ 0x73, 0x61, 0x62, 0x6c, 0x65, 0x12, 0x1b, 0x0a, 0x09, 0x75, 0x6e, 0x64, 0x65, 0x72, 0x5f, 0x6f,
+ 0x6f, 0x6d, 0x18, 0x02, 0x20, 0x01, 0x28, 0x04, 0x52, 0x08, 0x75, 0x6e, 0x64, 0x65, 0x72, 0x4f,
+ 0x6f, 0x6d, 0x12, 0x19, 0x0a, 0x08, 0x6f, 0x6f, 0x6d, 0x5f, 0x6b, 0x69, 0x6c, 0x6c, 0x18, 0x03,
+ 0x20, 0x01, 0x28, 0x04, 0x52, 0x07, 0x6f, 0x6f, 0x6d, 0x4b, 0x69, 0x6c, 0x6c, 0x22, 0xd5, 0x05,
+ 0x0a, 0x09, 0x42, 0x6c, 0x6b, 0x49, 0x4f, 0x53, 0x74, 0x61, 0x74, 0x12, 0x61, 0x0a, 0x1a, 0x69,
+ 0x6f, 0x5f, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x5f, 0x62, 0x79, 0x74, 0x65, 0x73, 0x5f,
+ 0x72, 0x65, 0x63, 0x75, 0x72, 0x73, 0x69, 0x76, 0x65, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32,
+ 0x24, 0x2e, 0x69, 0x6f, 0x2e, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x64, 0x2e,
+ 0x63, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x42, 0x6c, 0x6b, 0x49, 0x4f,
+ 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x17, 0x69, 0x6f, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65,
+ 0x42, 0x79, 0x74, 0x65, 0x73, 0x52, 0x65, 0x63, 0x75, 0x72, 0x73, 0x69, 0x76, 0x65, 0x12, 0x58,
+ 0x0a, 0x15, 0x69, 0x6f, 0x5f, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x64, 0x5f, 0x72, 0x65,
+ 0x63, 0x75, 0x72, 0x73, 0x69, 0x76, 0x65, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x24, 0x2e,
+ 0x69, 0x6f, 0x2e, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x64, 0x2e, 0x63, 0x67,
+ 0x72, 0x6f, 0x75, 0x70, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x42, 0x6c, 0x6b, 0x49, 0x4f, 0x45, 0x6e,
+ 0x74, 0x72, 0x79, 0x52, 0x13, 0x69, 0x6f, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x64, 0x52,
+ 0x65, 0x63, 0x75, 0x72, 0x73, 0x69, 0x76, 0x65, 0x12, 0x54, 0x0a, 0x13, 0x69, 0x6f, 0x5f, 0x71,
+ 0x75, 0x65, 0x75, 0x65, 0x64, 0x5f, 0x72, 0x65, 0x63, 0x75, 0x72, 0x73, 0x69, 0x76, 0x65, 0x18,
+ 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x24, 0x2e, 0x69, 0x6f, 0x2e, 0x63, 0x6f, 0x6e, 0x74, 0x61,
+ 0x69, 0x6e, 0x65, 0x72, 0x64, 0x2e, 0x63, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x73, 0x2e, 0x76, 0x31,
+ 0x2e, 0x42, 0x6c, 0x6b, 0x49, 0x4f, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x11, 0x69, 0x6f, 0x51,
+ 0x75, 0x65, 0x75, 0x65, 0x64, 0x52, 0x65, 0x63, 0x75, 0x72, 0x73, 0x69, 0x76, 0x65, 0x12, 0x5f,
+ 0x0a, 0x19, 0x69, 0x6f, 0x5f, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x5f, 0x74, 0x69, 0x6d,
+ 0x65, 0x5f, 0x72, 0x65, 0x63, 0x75, 0x72, 0x73, 0x69, 0x76, 0x65, 0x18, 0x04, 0x20, 0x03, 0x28,
+ 0x0b, 0x32, 0x24, 0x2e, 0x69, 0x6f, 0x2e, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72,
+ 0x64, 0x2e, 0x63, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x42, 0x6c, 0x6b,
+ 0x49, 0x4f, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x16, 0x69, 0x6f, 0x53, 0x65, 0x72, 0x76, 0x69,
+ 0x63, 0x65, 0x54, 0x69, 0x6d, 0x65, 0x52, 0x65, 0x63, 0x75, 0x72, 0x73, 0x69, 0x76, 0x65, 0x12,
+ 0x59, 0x0a, 0x16, 0x69, 0x6f, 0x5f, 0x77, 0x61, 0x69, 0x74, 0x5f, 0x74, 0x69, 0x6d, 0x65, 0x5f,
+ 0x72, 0x65, 0x63, 0x75, 0x72, 0x73, 0x69, 0x76, 0x65, 0x18, 0x05, 0x20, 0x03, 0x28, 0x0b, 0x32,
+ 0x24, 0x2e, 0x69, 0x6f, 0x2e, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x64, 0x2e,
+ 0x63, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x42, 0x6c, 0x6b, 0x49, 0x4f,
+ 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x13, 0x69, 0x6f, 0x57, 0x61, 0x69, 0x74, 0x54, 0x69, 0x6d,
+ 0x65, 0x52, 0x65, 0x63, 0x75, 0x72, 0x73, 0x69, 0x76, 0x65, 0x12, 0x54, 0x0a, 0x13, 0x69, 0x6f,
+ 0x5f, 0x6d, 0x65, 0x72, 0x67, 0x65, 0x64, 0x5f, 0x72, 0x65, 0x63, 0x75, 0x72, 0x73, 0x69, 0x76,
+ 0x65, 0x18, 0x06, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x24, 0x2e, 0x69, 0x6f, 0x2e, 0x63, 0x6f, 0x6e,
+ 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x64, 0x2e, 0x63, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x73, 0x2e,
+ 0x76, 0x31, 0x2e, 0x42, 0x6c, 0x6b, 0x49, 0x4f, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x11, 0x69,
+ 0x6f, 0x4d, 0x65, 0x72, 0x67, 0x65, 0x64, 0x52, 0x65, 0x63, 0x75, 0x72, 0x73, 0x69, 0x76, 0x65,
+ 0x12, 0x50, 0x0a, 0x11, 0x69, 0x6f, 0x5f, 0x74, 0x69, 0x6d, 0x65, 0x5f, 0x72, 0x65, 0x63, 0x75,
+ 0x72, 0x73, 0x69, 0x76, 0x65, 0x18, 0x07, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x24, 0x2e, 0x69, 0x6f,
+ 0x2e, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x64, 0x2e, 0x63, 0x67, 0x72, 0x6f,
+ 0x75, 0x70, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x42, 0x6c, 0x6b, 0x49, 0x4f, 0x45, 0x6e, 0x74, 0x72,
+ 0x79, 0x52, 0x0f, 0x69, 0x6f, 0x54, 0x69, 0x6d, 0x65, 0x52, 0x65, 0x63, 0x75, 0x72, 0x73, 0x69,
+ 0x76, 0x65, 0x12, 0x51, 0x0a, 0x11, 0x73, 0x65, 0x63, 0x74, 0x6f, 0x72, 0x73, 0x5f, 0x72, 0x65,
+ 0x63, 0x75, 0x72, 0x73, 0x69, 0x76, 0x65, 0x18, 0x08, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x24, 0x2e,
+ 0x69, 0x6f, 0x2e, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x64, 0x2e, 0x63, 0x67,
+ 0x72, 0x6f, 0x75, 0x70, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x42, 0x6c, 0x6b, 0x49, 0x4f, 0x45, 0x6e,
+ 0x74, 0x72, 0x79, 0x52, 0x10, 0x73, 0x65, 0x63, 0x74, 0x6f, 0x72, 0x73, 0x52, 0x65, 0x63, 0x75,
+ 0x72, 0x73, 0x69, 0x76, 0x65, 0x22, 0x76, 0x0a, 0x0a, 0x42, 0x6c, 0x6b, 0x49, 0x4f, 0x45, 0x6e,
+ 0x74, 0x72, 0x79, 0x12, 0x0e, 0x0a, 0x02, 0x6f, 0x70, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52,
+ 0x02, 0x6f, 0x70, 0x12, 0x16, 0x0a, 0x06, 0x64, 0x65, 0x76, 0x69, 0x63, 0x65, 0x18, 0x02, 0x20,
+ 0x01, 0x28, 0x09, 0x52, 0x06, 0x64, 0x65, 0x76, 0x69, 0x63, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x6d,
+ 0x61, 0x6a, 0x6f, 0x72, 0x18, 0x03, 0x20, 0x01, 0x28, 0x04, 0x52, 0x05, 0x6d, 0x61, 0x6a, 0x6f,
+ 0x72, 0x12, 0x14, 0x0a, 0x05, 0x6d, 0x69, 0x6e, 0x6f, 0x72, 0x18, 0x04, 0x20, 0x01, 0x28, 0x04,
+ 0x52, 0x05, 0x6d, 0x69, 0x6e, 0x6f, 0x72, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65,
+ 0x18, 0x05, 0x20, 0x01, 0x28, 0x04, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x22, 0x84, 0x01,
+ 0x0a, 0x08, 0x52, 0x64, 0x6d, 0x61, 0x53, 0x74, 0x61, 0x74, 0x12, 0x3d, 0x0a, 0x07, 0x63, 0x75,
+ 0x72, 0x72, 0x65, 0x6e, 0x74, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x23, 0x2e, 0x69, 0x6f,
+ 0x2e, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x64, 0x2e, 0x63, 0x67, 0x72, 0x6f,
+ 0x75, 0x70, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x64, 0x6d, 0x61, 0x45, 0x6e, 0x74, 0x72, 0x79,
+ 0x52, 0x07, 0x63, 0x75, 0x72, 0x72, 0x65, 0x6e, 0x74, 0x12, 0x39, 0x0a, 0x05, 0x6c, 0x69, 0x6d,
+ 0x69, 0x74, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x23, 0x2e, 0x69, 0x6f, 0x2e, 0x63, 0x6f,
+ 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x64, 0x2e, 0x63, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x73,
+ 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x64, 0x6d, 0x61, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x05, 0x6c,
+ 0x69, 0x6d, 0x69, 0x74, 0x22, 0x65, 0x0a, 0x09, 0x52, 0x64, 0x6d, 0x61, 0x45, 0x6e, 0x74, 0x72,
+ 0x79, 0x12, 0x16, 0x0a, 0x06, 0x64, 0x65, 0x76, 0x69, 0x63, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28,
+ 0x09, 0x52, 0x06, 0x64, 0x65, 0x76, 0x69, 0x63, 0x65, 0x12, 0x1f, 0x0a, 0x0b, 0x68, 0x63, 0x61,
+ 0x5f, 0x68, 0x61, 0x6e, 0x64, 0x6c, 0x65, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x0a,
+ 0x68, 0x63, 0x61, 0x48, 0x61, 0x6e, 0x64, 0x6c, 0x65, 0x73, 0x12, 0x1f, 0x0a, 0x0b, 0x68, 0x63,
+ 0x61, 0x5f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0d, 0x52,
+ 0x0a, 0x68, 0x63, 0x61, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x73, 0x22, 0x8d, 0x02, 0x0a, 0x0b,
+ 0x4e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x53, 0x74, 0x61, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x6e,
+ 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12,
+ 0x19, 0x0a, 0x08, 0x72, 0x78, 0x5f, 0x62, 0x79, 0x74, 0x65, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28,
+ 0x04, 0x52, 0x07, 0x72, 0x78, 0x42, 0x79, 0x74, 0x65, 0x73, 0x12, 0x1d, 0x0a, 0x0a, 0x72, 0x78,
+ 0x5f, 0x70, 0x61, 0x63, 0x6b, 0x65, 0x74, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, 0x04, 0x52, 0x09,
+ 0x72, 0x78, 0x50, 0x61, 0x63, 0x6b, 0x65, 0x74, 0x73, 0x12, 0x1b, 0x0a, 0x09, 0x72, 0x78, 0x5f,
+ 0x65, 0x72, 0x72, 0x6f, 0x72, 0x73, 0x18, 0x04, 0x20, 0x01, 0x28, 0x04, 0x52, 0x08, 0x72, 0x78,
+ 0x45, 0x72, 0x72, 0x6f, 0x72, 0x73, 0x12, 0x1d, 0x0a, 0x0a, 0x72, 0x78, 0x5f, 0x64, 0x72, 0x6f,
+ 0x70, 0x70, 0x65, 0x64, 0x18, 0x05, 0x20, 0x01, 0x28, 0x04, 0x52, 0x09, 0x72, 0x78, 0x44, 0x72,
+ 0x6f, 0x70, 0x70, 0x65, 0x64, 0x12, 0x19, 0x0a, 0x08, 0x74, 0x78, 0x5f, 0x62, 0x79, 0x74, 0x65,
+ 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x04, 0x52, 0x07, 0x74, 0x78, 0x42, 0x79, 0x74, 0x65, 0x73,
+ 0x12, 0x1d, 0x0a, 0x0a, 0x74, 0x78, 0x5f, 0x70, 0x61, 0x63, 0x6b, 0x65, 0x74, 0x73, 0x18, 0x07,
+ 0x20, 0x01, 0x28, 0x04, 0x52, 0x09, 0x74, 0x78, 0x50, 0x61, 0x63, 0x6b, 0x65, 0x74, 0x73, 0x12,
+ 0x1b, 0x0a, 0x09, 0x74, 0x78, 0x5f, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x73, 0x18, 0x08, 0x20, 0x01,
+ 0x28, 0x04, 0x52, 0x08, 0x74, 0x78, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x73, 0x12, 0x1d, 0x0a, 0x0a,
+ 0x74, 0x78, 0x5f, 0x64, 0x72, 0x6f, 0x70, 0x70, 0x65, 0x64, 0x18, 0x09, 0x20, 0x01, 0x28, 0x04,
+ 0x52, 0x09, 0x74, 0x78, 0x44, 0x72, 0x6f, 0x70, 0x70, 0x65, 0x64, 0x22, 0xb9, 0x01, 0x0a, 0x0b,
+ 0x43, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x53, 0x74, 0x61, 0x74, 0x73, 0x12, 0x1f, 0x0a, 0x0b, 0x6e,
+ 0x72, 0x5f, 0x73, 0x6c, 0x65, 0x65, 0x70, 0x69, 0x6e, 0x67, 0x18, 0x01, 0x20, 0x01, 0x28, 0x04,
+ 0x52, 0x0a, 0x6e, 0x72, 0x53, 0x6c, 0x65, 0x65, 0x70, 0x69, 0x6e, 0x67, 0x12, 0x1d, 0x0a, 0x0a,
+ 0x6e, 0x72, 0x5f, 0x72, 0x75, 0x6e, 0x6e, 0x69, 0x6e, 0x67, 0x18, 0x02, 0x20, 0x01, 0x28, 0x04,
+ 0x52, 0x09, 0x6e, 0x72, 0x52, 0x75, 0x6e, 0x6e, 0x69, 0x6e, 0x67, 0x12, 0x1d, 0x0a, 0x0a, 0x6e,
+ 0x72, 0x5f, 0x73, 0x74, 0x6f, 0x70, 0x70, 0x65, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x04, 0x52,
+ 0x09, 0x6e, 0x72, 0x53, 0x74, 0x6f, 0x70, 0x70, 0x65, 0x64, 0x12, 0x2d, 0x0a, 0x12, 0x6e, 0x72,
+ 0x5f, 0x75, 0x6e, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x72, 0x75, 0x70, 0x74, 0x69, 0x62, 0x6c, 0x65,
+ 0x18, 0x04, 0x20, 0x01, 0x28, 0x04, 0x52, 0x11, 0x6e, 0x72, 0x55, 0x6e, 0x69, 0x6e, 0x74, 0x65,
+ 0x72, 0x72, 0x75, 0x70, 0x74, 0x69, 0x62, 0x6c, 0x65, 0x12, 0x1c, 0x0a, 0x0a, 0x6e, 0x72, 0x5f,
+ 0x69, 0x6f, 0x5f, 0x77, 0x61, 0x69, 0x74, 0x18, 0x05, 0x20, 0x01, 0x28, 0x04, 0x52, 0x08, 0x6e,
+ 0x72, 0x49, 0x6f, 0x57, 0x61, 0x69, 0x74, 0x42, 0x2d, 0x5a, 0x2b, 0x67, 0x69, 0x74, 0x68, 0x75,
+ 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x64,
+ 0x2f, 0x63, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x73, 0x2f, 0x63, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x31,
+ 0x2f, 0x73, 0x74, 0x61, 0x74, 0x73, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
+}
+
+var (
+ file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_rawDescOnce sync.Once
+ file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_rawDescData = file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_rawDesc
+)
+
+func file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_rawDescGZIP() []byte {
+ file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_rawDescOnce.Do(func() {
+ file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_rawDescData = protoimpl.X.CompressGZIP(file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_rawDescData)
+ })
+ return file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_rawDescData
+}
+
+var file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_msgTypes = make([]protoimpl.MessageInfo, 15)
+var file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_goTypes = []interface{}{
+ (*Metrics)(nil), // 0: io.containerd.cgroups.v1.Metrics
+ (*HugetlbStat)(nil), // 1: io.containerd.cgroups.v1.HugetlbStat
+ (*PidsStat)(nil), // 2: io.containerd.cgroups.v1.PidsStat
+ (*CPUStat)(nil), // 3: io.containerd.cgroups.v1.CPUStat
+ (*CPUUsage)(nil), // 4: io.containerd.cgroups.v1.CPUUsage
+ (*Throttle)(nil), // 5: io.containerd.cgroups.v1.Throttle
+ (*MemoryStat)(nil), // 6: io.containerd.cgroups.v1.MemoryStat
+ (*MemoryEntry)(nil), // 7: io.containerd.cgroups.v1.MemoryEntry
+ (*MemoryOomControl)(nil), // 8: io.containerd.cgroups.v1.MemoryOomControl
+ (*BlkIOStat)(nil), // 9: io.containerd.cgroups.v1.BlkIOStat
+ (*BlkIOEntry)(nil), // 10: io.containerd.cgroups.v1.BlkIOEntry
+ (*RdmaStat)(nil), // 11: io.containerd.cgroups.v1.RdmaStat
+ (*RdmaEntry)(nil), // 12: io.containerd.cgroups.v1.RdmaEntry
+ (*NetworkStat)(nil), // 13: io.containerd.cgroups.v1.NetworkStat
+ (*CgroupStats)(nil), // 14: io.containerd.cgroups.v1.CgroupStats
+}
+var file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_depIdxs = []int32{
+ 1, // 0: io.containerd.cgroups.v1.Metrics.hugetlb:type_name -> io.containerd.cgroups.v1.HugetlbStat
+ 2, // 1: io.containerd.cgroups.v1.Metrics.pids:type_name -> io.containerd.cgroups.v1.PidsStat
+ 3, // 2: io.containerd.cgroups.v1.Metrics.cpu:type_name -> io.containerd.cgroups.v1.CPUStat
+ 6, // 3: io.containerd.cgroups.v1.Metrics.memory:type_name -> io.containerd.cgroups.v1.MemoryStat
+ 9, // 4: io.containerd.cgroups.v1.Metrics.blkio:type_name -> io.containerd.cgroups.v1.BlkIOStat
+ 11, // 5: io.containerd.cgroups.v1.Metrics.rdma:type_name -> io.containerd.cgroups.v1.RdmaStat
+ 13, // 6: io.containerd.cgroups.v1.Metrics.network:type_name -> io.containerd.cgroups.v1.NetworkStat
+ 14, // 7: io.containerd.cgroups.v1.Metrics.cgroup_stats:type_name -> io.containerd.cgroups.v1.CgroupStats
+ 8, // 8: io.containerd.cgroups.v1.Metrics.memory_oom_control:type_name -> io.containerd.cgroups.v1.MemoryOomControl
+ 4, // 9: io.containerd.cgroups.v1.CPUStat.usage:type_name -> io.containerd.cgroups.v1.CPUUsage
+ 5, // 10: io.containerd.cgroups.v1.CPUStat.throttling:type_name -> io.containerd.cgroups.v1.Throttle
+ 7, // 11: io.containerd.cgroups.v1.MemoryStat.usage:type_name -> io.containerd.cgroups.v1.MemoryEntry
+ 7, // 12: io.containerd.cgroups.v1.MemoryStat.swap:type_name -> io.containerd.cgroups.v1.MemoryEntry
+ 7, // 13: io.containerd.cgroups.v1.MemoryStat.kernel:type_name -> io.containerd.cgroups.v1.MemoryEntry
+ 7, // 14: io.containerd.cgroups.v1.MemoryStat.kernel_tcp:type_name -> io.containerd.cgroups.v1.MemoryEntry
+ 10, // 15: io.containerd.cgroups.v1.BlkIOStat.io_service_bytes_recursive:type_name -> io.containerd.cgroups.v1.BlkIOEntry
+ 10, // 16: io.containerd.cgroups.v1.BlkIOStat.io_serviced_recursive:type_name -> io.containerd.cgroups.v1.BlkIOEntry
+ 10, // 17: io.containerd.cgroups.v1.BlkIOStat.io_queued_recursive:type_name -> io.containerd.cgroups.v1.BlkIOEntry
+ 10, // 18: io.containerd.cgroups.v1.BlkIOStat.io_service_time_recursive:type_name -> io.containerd.cgroups.v1.BlkIOEntry
+ 10, // 19: io.containerd.cgroups.v1.BlkIOStat.io_wait_time_recursive:type_name -> io.containerd.cgroups.v1.BlkIOEntry
+ 10, // 20: io.containerd.cgroups.v1.BlkIOStat.io_merged_recursive:type_name -> io.containerd.cgroups.v1.BlkIOEntry
+ 10, // 21: io.containerd.cgroups.v1.BlkIOStat.io_time_recursive:type_name -> io.containerd.cgroups.v1.BlkIOEntry
+ 10, // 22: io.containerd.cgroups.v1.BlkIOStat.sectors_recursive:type_name -> io.containerd.cgroups.v1.BlkIOEntry
+ 12, // 23: io.containerd.cgroups.v1.RdmaStat.current:type_name -> io.containerd.cgroups.v1.RdmaEntry
+ 12, // 24: io.containerd.cgroups.v1.RdmaStat.limit:type_name -> io.containerd.cgroups.v1.RdmaEntry
+ 25, // [25:25] is the sub-list for method output_type
+ 25, // [25:25] is the sub-list for method input_type
+ 25, // [25:25] is the sub-list for extension type_name
+ 25, // [25:25] is the sub-list for extension extendee
+ 0, // [0:25] is the sub-list for field type_name
+}
+
+func init() { file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_init() }
+func file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_init() {
+ if File_github_com_containerd_cgroups_cgroup1_stats_metrics_proto != nil {
+ return
+ }
+ if !protoimpl.UnsafeEnabled {
+ file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} {
+ switch v := v.(*Metrics); i {
+ case 0:
+ return &v.state
+ case 1:
+ return &v.sizeCache
+ case 2:
+ return &v.unknownFields
+ default:
+ return nil
+ }
+ }
+ file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} {
+ switch v := v.(*HugetlbStat); i {
+ case 0:
+ return &v.state
+ case 1:
+ return &v.sizeCache
+ case 2:
+ return &v.unknownFields
+ default:
+ return nil
+ }
+ }
+ file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} {
+ switch v := v.(*PidsStat); i {
+ case 0:
+ return &v.state
+ case 1:
+ return &v.sizeCache
+ case 2:
+ return &v.unknownFields
+ default:
+ return nil
+ }
+ }
+ file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} {
+ switch v := v.(*CPUStat); i {
+ case 0:
+ return &v.state
+ case 1:
+ return &v.sizeCache
+ case 2:
+ return &v.unknownFields
+ default:
+ return nil
+ }
+ }
+ file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} {
+ switch v := v.(*CPUUsage); i {
+ case 0:
+ return &v.state
+ case 1:
+ return &v.sizeCache
+ case 2:
+ return &v.unknownFields
+ default:
+ return nil
+ }
+ }
+ file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} {
+ switch v := v.(*Throttle); i {
+ case 0:
+ return &v.state
+ case 1:
+ return &v.sizeCache
+ case 2:
+ return &v.unknownFields
+ default:
+ return nil
+ }
+ }
+ file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} {
+ switch v := v.(*MemoryStat); i {
+ case 0:
+ return &v.state
+ case 1:
+ return &v.sizeCache
+ case 2:
+ return &v.unknownFields
+ default:
+ return nil
+ }
+ }
+ file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} {
+ switch v := v.(*MemoryEntry); i {
+ case 0:
+ return &v.state
+ case 1:
+ return &v.sizeCache
+ case 2:
+ return &v.unknownFields
+ default:
+ return nil
+ }
+ }
+ file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_msgTypes[8].Exporter = func(v interface{}, i int) interface{} {
+ switch v := v.(*MemoryOomControl); i {
+ case 0:
+ return &v.state
+ case 1:
+ return &v.sizeCache
+ case 2:
+ return &v.unknownFields
+ default:
+ return nil
+ }
+ }
+ file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_msgTypes[9].Exporter = func(v interface{}, i int) interface{} {
+ switch v := v.(*BlkIOStat); i {
+ case 0:
+ return &v.state
+ case 1:
+ return &v.sizeCache
+ case 2:
+ return &v.unknownFields
+ default:
+ return nil
+ }
+ }
+ file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_msgTypes[10].Exporter = func(v interface{}, i int) interface{} {
+ switch v := v.(*BlkIOEntry); i {
+ case 0:
+ return &v.state
+ case 1:
+ return &v.sizeCache
+ case 2:
+ return &v.unknownFields
+ default:
+ return nil
+ }
+ }
+ file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_msgTypes[11].Exporter = func(v interface{}, i int) interface{} {
+ switch v := v.(*RdmaStat); i {
+ case 0:
+ return &v.state
+ case 1:
+ return &v.sizeCache
+ case 2:
+ return &v.unknownFields
+ default:
+ return nil
+ }
+ }
+ file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_msgTypes[12].Exporter = func(v interface{}, i int) interface{} {
+ switch v := v.(*RdmaEntry); i {
+ case 0:
+ return &v.state
+ case 1:
+ return &v.sizeCache
+ case 2:
+ return &v.unknownFields
+ default:
+ return nil
+ }
+ }
+ file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_msgTypes[13].Exporter = func(v interface{}, i int) interface{} {
+ switch v := v.(*NetworkStat); i {
+ case 0:
+ return &v.state
+ case 1:
+ return &v.sizeCache
+ case 2:
+ return &v.unknownFields
+ default:
+ return nil
+ }
+ }
+ file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_msgTypes[14].Exporter = func(v interface{}, i int) interface{} {
+ switch v := v.(*CgroupStats); i {
+ case 0:
+ return &v.state
+ case 1:
+ return &v.sizeCache
+ case 2:
+ return &v.unknownFields
+ default:
+ return nil
+ }
+ }
+ }
+ type x struct{}
+ out := protoimpl.TypeBuilder{
+ File: protoimpl.DescBuilder{
+ GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
+ RawDescriptor: file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_rawDesc,
+ NumEnums: 0,
+ NumMessages: 15,
+ NumExtensions: 0,
+ NumServices: 0,
+ },
+ GoTypes: file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_goTypes,
+ DependencyIndexes: file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_depIdxs,
+ MessageInfos: file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_msgTypes,
+ }.Build()
+ File_github_com_containerd_cgroups_cgroup1_stats_metrics_proto = out.File
+ file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_rawDesc = nil
+ file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_goTypes = nil
+ file_github_com_containerd_cgroups_cgroup1_stats_metrics_proto_depIdxs = nil
+}
diff --git a/vendor/github.com/containerd/cgroups/stats/v1/metrics.pb.txt b/vendor/github.com/containerd/cgroups/v3/cgroup1/stats/metrics.pb.txt
index e476cea64..7e4313ea5 100644
--- a/vendor/github.com/containerd/cgroups/stats/v1/metrics.pb.txt
+++ b/vendor/github.com/containerd/cgroups/v3/cgroup1/stats/metrics.pb.txt
@@ -1,7 +1,6 @@
file {
- name: "github.com/containerd/cgroups/stats/v1/metrics.proto"
+ name: "github.com/containerd/cgroups/cgroup1/stats/metrics.proto"
package: "io.containerd.cgroups.v1"
- dependency: "gogoproto/gogo.proto"
message_type {
name: "Metrics"
field {
@@ -26,9 +25,6 @@ file {
label: LABEL_OPTIONAL
type: TYPE_MESSAGE
type_name: ".io.containerd.cgroups.v1.CPUStat"
- options {
- 65004: "CPU"
- }
json_name: "cpu"
}
field {
@@ -175,9 +171,6 @@ file {
number: 4
label: LABEL_REPEATED
type: TYPE_UINT64
- options {
- 65004: "PerCPU"
- }
json_name: "perCpu"
}
}
@@ -219,9 +212,6 @@ file {
number: 2
label: LABEL_OPTIONAL
type: TYPE_UINT64
- options {
- 65004: "RSS"
- }
json_name: "rss"
}
field {
@@ -229,9 +219,6 @@ file {
number: 3
label: LABEL_OPTIONAL
type: TYPE_UINT64
- options {
- 65004: "RSSHuge"
- }
json_name: "rssHuge"
}
field {
@@ -344,9 +331,6 @@ file {
number: 19
label: LABEL_OPTIONAL
type: TYPE_UINT64
- options {
- 65004: "TotalRSS"
- }
json_name: "totalRss"
}
field {
@@ -354,9 +338,6 @@ file {
number: 20
label: LABEL_OPTIONAL
type: TYPE_UINT64
- options {
- 65004: "TotalRSSHuge"
- }
json_name: "totalRssHuge"
}
field {
@@ -473,9 +454,6 @@ file {
label: LABEL_OPTIONAL
type: TYPE_MESSAGE
type_name: ".io.containerd.cgroups.v1.MemoryEntry"
- options {
- 65004: "KernelTCP"
- }
json_name: "kernelTcp"
}
}
@@ -786,5 +764,8 @@ file {
json_name: "nrIoWait"
}
}
+ options {
+ go_package: "github.com/containerd/cgroups/cgroup1/stats"
+ }
syntax: "proto3"
}
diff --git a/vendor/github.com/containerd/cgroups/stats/v1/metrics.proto b/vendor/github.com/containerd/cgroups/v3/cgroup1/stats/metrics.proto
index b3f6cc37d..e6e4444b1 100644
--- a/vendor/github.com/containerd/cgroups/stats/v1/metrics.proto
+++ b/vendor/github.com/containerd/cgroups/v3/cgroup1/stats/metrics.proto
@@ -2,12 +2,12 @@ syntax = "proto3";
package io.containerd.cgroups.v1;
-import "gogoproto/gogo.proto";
+option go_package = "github.com/containerd/cgroups/cgroup1/stats";
message Metrics {
repeated HugetlbStat hugetlb = 1;
PidsStat pids = 2;
- CPUStat cpu = 3 [(gogoproto.customname) = "CPU"];
+ CPUStat cpu = 3;
MemoryStat memory = 4;
BlkIOStat blkio = 5;
RdmaStat rdma = 6;
@@ -38,7 +38,7 @@ message CPUUsage {
uint64 total = 1;
uint64 kernel = 2;
uint64 user = 3;
- repeated uint64 per_cpu = 4 [(gogoproto.customname) = "PerCPU"];
+ repeated uint64 per_cpu = 4;
}
@@ -50,8 +50,8 @@ message Throttle {
message MemoryStat {
uint64 cache = 1;
- uint64 rss = 2 [(gogoproto.customname) = "RSS"];
- uint64 rss_huge = 3 [(gogoproto.customname) = "RSSHuge"];
+ uint64 rss = 2;
+ uint64 rss_huge = 3;
uint64 mapped_file = 4;
uint64 dirty = 5;
uint64 writeback = 6;
@@ -67,8 +67,8 @@ message MemoryStat {
uint64 hierarchical_memory_limit = 16;
uint64 hierarchical_swap_limit = 17;
uint64 total_cache = 18;
- uint64 total_rss = 19 [(gogoproto.customname) = "TotalRSS"];
- uint64 total_rss_huge = 20 [(gogoproto.customname) = "TotalRSSHuge"];
+ uint64 total_rss = 19;
+ uint64 total_rss_huge = 20;
uint64 total_mapped_file = 21;
uint64 total_dirty = 22;
uint64 total_writeback = 23;
@@ -84,7 +84,7 @@ message MemoryStat {
MemoryEntry usage = 33;
MemoryEntry swap = 34;
MemoryEntry kernel = 35;
- MemoryEntry kernel_tcp = 36 [(gogoproto.customname) = "KernelTCP"];
+ MemoryEntry kernel_tcp = 36;
}
diff --git a/vendor/github.com/containerd/cgroups/subsystem.go b/vendor/github.com/containerd/cgroups/v3/cgroup1/subsystem.go
index b2f41854d..d32ea2cae 100644
--- a/vendor/github.com/containerd/cgroups/subsystem.go
+++ b/vendor/github.com/containerd/cgroups/v3/cgroup1/subsystem.go
@@ -14,13 +14,14 @@
limitations under the License.
*/
-package cgroups
+package cgroup1
import (
"fmt"
"os"
- v1 "github.com/containerd/cgroups/stats/v1"
+ "github.com/containerd/cgroups/v3"
+ v1 "github.com/containerd/cgroups/v3/cgroup1/stats"
specs "github.com/opencontainers/runtime-spec/specs-go"
)
@@ -59,7 +60,7 @@ func Subsystems() []Name {
Blkio,
Rdma,
}
- if !RunningInUserNS() {
+ if !cgroups.RunningInUserNS() {
n = append(n, Devices)
}
if _, err := os.Stat("/sys/kernel/mm/hugepages"); err == nil {
diff --git a/vendor/github.com/containerd/cgroups/systemd.go b/vendor/github.com/containerd/cgroups/v3/cgroup1/systemd.go
index 4da57cb4b..d327effc8 100644
--- a/vendor/github.com/containerd/cgroups/systemd.go
+++ b/vendor/github.com/containerd/cgroups/v3/cgroup1/systemd.go
@@ -14,7 +14,7 @@
limitations under the License.
*/
-package cgroups
+package cgroup1
import (
"context"
diff --git a/vendor/github.com/containerd/cgroups/ticks.go b/vendor/github.com/containerd/cgroups/v3/cgroup1/ticks.go
index 84dc38d0c..2c6fbdc0d 100644
--- a/vendor/github.com/containerd/cgroups/ticks.go
+++ b/vendor/github.com/containerd/cgroups/v3/cgroup1/ticks.go
@@ -14,7 +14,7 @@
limitations under the License.
*/
-package cgroups
+package cgroup1
func getClockTicks() uint64 {
// The value comes from `C.sysconf(C._SC_CLK_TCK)`, and
diff --git a/vendor/github.com/containerd/cgroups/utils.go b/vendor/github.com/containerd/cgroups/v3/cgroup1/utils.go
index 217138975..8ae005dad 100644
--- a/vendor/github.com/containerd/cgroups/utils.go
+++ b/vendor/github.com/containerd/cgroups/v3/cgroup1/utils.go
@@ -14,107 +14,22 @@
limitations under the License.
*/
-package cgroups
+package cgroup1
import (
"bufio"
- "errors"
"fmt"
- "io"
- "io/ioutil"
"os"
"path/filepath"
"strconv"
"strings"
- "sync"
- "syscall"
"time"
+ "github.com/containerd/cgroups/v3"
units "github.com/docker/go-units"
specs "github.com/opencontainers/runtime-spec/specs-go"
- "golang.org/x/sys/unix"
)
-var (
- nsOnce sync.Once
- inUserNS bool
- checkMode sync.Once
- cgMode CGMode
-)
-
-const unifiedMountpoint = "/sys/fs/cgroup"
-
-// CGMode is the cgroups mode of the host system
-type CGMode int
-
-const (
- // Unavailable cgroup mountpoint
- Unavailable CGMode = iota
- // Legacy cgroups v1
- Legacy
- // Hybrid with cgroups v1 and v2 controllers mounted
- Hybrid
- // Unified with only cgroups v2 mounted
- Unified
-)
-
-// Mode returns the cgroups mode running on the host
-func Mode() CGMode {
- checkMode.Do(func() {
- var st unix.Statfs_t
- if err := unix.Statfs(unifiedMountpoint, &st); err != nil {
- cgMode = Unavailable
- return
- }
- switch st.Type {
- case unix.CGROUP2_SUPER_MAGIC:
- cgMode = Unified
- default:
- cgMode = Legacy
- if err := unix.Statfs(filepath.Join(unifiedMountpoint, "unified"), &st); err != nil {
- return
- }
- if st.Type == unix.CGROUP2_SUPER_MAGIC {
- cgMode = Hybrid
- }
- }
- })
- return cgMode
-}
-
-// RunningInUserNS detects whether we are currently running in a user namespace.
-// Copied from github.com/lxc/lxd/shared/util.go
-func RunningInUserNS() bool {
- nsOnce.Do(func() {
- file, err := os.Open("/proc/self/uid_map")
- if err != nil {
- // This kernel-provided file only exists if user namespaces are supported
- return
- }
- defer file.Close()
-
- buf := bufio.NewReader(file)
- l, _, err := buf.ReadLine()
- if err != nil {
- return
- }
-
- line := string(l)
- var a, b, c int64
- fmt.Sscanf(line, "%d %d %d", &a, &b, &c)
-
- /*
- * We assume we are in the initial user namespace if we have a full
- * range - 4294967295 uids starting at uid 0.
- */
- if a == 0 && b == 0 && c == 4294967295 {
- return
- }
- inUserNS = true
- })
- return inUserNS
-}
-
// defaults returns all known groups
func defaults(root string) ([]Subsystem, error) {
h, err := NewHugetlb(root)
@@ -137,7 +52,7 @@ func defaults(root string) ([]Subsystem, error) {
}
// only add the devices cgroup if we are not in a user namespace
// because modifications are not allowed
- if !RunningInUserNS() {
+ if !cgroups.RunningInUserNS() {
s = append(s, NewDevices(root))
}
// add the hugetlb cgroup if error wasn't due to missing hugetlb
@@ -200,7 +115,7 @@ func hugePageSizes() ([]string, error) {
pageSizes []string
sizeList = []string{"B", "KB", "MB", "GB", "TB", "PB"}
)
- files, err := ioutil.ReadDir("/sys/kernel/mm/hugepages")
+ files, err := os.ReadDir("/sys/kernel/mm/hugepages")
if err != nil {
return nil, err
}
@@ -216,7 +131,7 @@ func hugePageSizes() ([]string, error) {
}
func readUint(path string) (uint64, error) {
- v, err := ioutil.ReadFile(path)
+ v, err := os.ReadFile(path)
if err != nil {
return 0, err
}
@@ -257,12 +172,14 @@ func parseKV(raw string) (string, uint64, error) {
// ParseCgroupFile parses the given cgroup file, typically /proc/self/cgroup
// or /proc/<pid>/cgroup, into a map of subsystems to cgroup paths, e.g.
-// "cpu": "/user.slice/user-1000.slice"
-// "pids": "/user.slice/user-1000.slice"
+//
+// "cpu": "/user.slice/user-1000.slice"
+// "pids": "/user.slice/user-1000.slice"
+//
// etc.
//
// The resulting map does not have an element for cgroup v2 unified hierarchy.
-// Use ParseCgroupFileUnified to get the unified path.
+// Use [cgroups.ParseCgroupFileUnified] to get the unified path.
func ParseCgroupFile(path string) (map[string]string, error) {
x, _, err := ParseCgroupFileUnified(path)
return x, err
@@ -270,41 +187,10 @@ func ParseCgroupFile(path string) (map[string]string, error) {
// ParseCgroupFileUnified returns legacy subsystem paths as the first value,
// and returns the unified path as the second value.
+//
+// Deprecated: use [cgroups.ParseCgroupFileUnified] instead .
func ParseCgroupFileUnified(path string) (map[string]string, string, error) {
- f, err := os.Open(path)
- if err != nil {
- return nil, "", err
- }
- defer f.Close()
- return parseCgroupFromReaderUnified(f)
-}
-
-func parseCgroupFromReaderUnified(r io.Reader) (map[string]string, string, error) {
- var (
- cgroups = make(map[string]string)
- unified = ""
- s = bufio.NewScanner(r)
- )
- for s.Scan() {
- var (
- text = s.Text()
- parts = strings.SplitN(text, ":", 3)
- )
- if len(parts) < 3 {
- return nil, unified, fmt.Errorf("invalid cgroup entry: %q", text)
- }
- for _, subs := range strings.Split(parts[1], ",") {
- if subs == "" {
- unified = parts[2]
- } else {
- cgroups[subs] = parts[2]
- }
- }
- }
- if err := s.Err(); err != nil {
- return nil, unified, err
- }
- return cgroups, unified, nil
+ return cgroups.ParseCgroupFileUnified(path)
}
func getCgroupDestination(subsystem string) (string, error) {
@@ -377,16 +263,3 @@ func cleanPath(path string) string {
}
return path
}
-
-func retryingWriteFile(path string, data []byte, mode os.FileMode) error {
- // Retry writes on EINTR; see:
- // https://github.com/golang/go/issues/38033
- for {
- err := ioutil.WriteFile(path, data, mode)
- if err == nil {
- return nil
- } else if !errors.Is(err, syscall.EINTR) {
- return err
- }
- }
-}
diff --git a/vendor/github.com/containerd/cgroups/v1.go b/vendor/github.com/containerd/cgroups/v3/cgroup1/v1.go
index 2ec215c06..d4c7db6f2 100644
--- a/vendor/github.com/containerd/cgroups/v1.go
+++ b/vendor/github.com/containerd/cgroups/v3/cgroup1/v1.go
@@ -14,7 +14,7 @@
limitations under the License.
*/
-package cgroups
+package cgroup1
import (
"bufio"
@@ -24,8 +24,8 @@ import (
"strings"
)
-// V1 returns all the groups in the default cgroups mountpoint in a single hierarchy
-func V1() ([]Subsystem, error) {
+// Default returns all the groups in the default cgroups mountpoint in a single hierarchy
+func Default() ([]Subsystem, error) {
root, err := v1MountPoint()
if err != nil {
return nil, err
diff --git a/vendor/github.com/containerd/cgroups/v2/cpu.go b/vendor/github.com/containerd/cgroups/v3/cgroup2/cpu.go
index 65282ff08..dcb253db5 100644
--- a/vendor/github.com/containerd/cgroups/v2/cpu.go
+++ b/vendor/github.com/containerd/cgroups/v3/cgroup2/cpu.go
@@ -14,7 +14,7 @@
limitations under the License.
*/
-package v2
+package cgroup2
import (
"math"
diff --git a/vendor/github.com/containerd/cgroups/v2/devicefilter.go b/vendor/github.com/containerd/cgroups/v3/cgroup2/devicefilter.go
index 0882036c2..3a73ab105 100644
--- a/vendor/github.com/containerd/cgroups/v2/devicefilter.go
+++ b/vendor/github.com/containerd/cgroups/v3/cgroup2/devicefilter.go
@@ -24,7 +24,7 @@
// This particular Go implementation based on runc version
// https://github.com/opencontainers/runc/blob/master/libcontainer/cgroups/ebpf/devicefilter/devicefilter.go
-package v2
+package cgroup2
import (
"errors"
diff --git a/vendor/github.com/containerd/cgroups/v2/ebpf.go b/vendor/github.com/containerd/cgroups/v3/cgroup2/ebpf.go
index 45bf5f99e..503a147bb 100644
--- a/vendor/github.com/containerd/cgroups/v2/ebpf.go
+++ b/vendor/github.com/containerd/cgroups/v3/cgroup2/ebpf.go
@@ -14,7 +14,7 @@
limitations under the License.
*/
-package v2
+package cgroup2
import (
"fmt"
diff --git a/vendor/github.com/containerd/cgroups/v2/errors.go b/vendor/github.com/containerd/cgroups/v3/cgroup2/errors.go
index eeae362b2..f57e15e54 100644
--- a/vendor/github.com/containerd/cgroups/v2/errors.go
+++ b/vendor/github.com/containerd/cgroups/v3/cgroup2/errors.go
@@ -14,7 +14,7 @@
limitations under the License.
*/
-package v2
+package cgroup2
import (
"errors"
diff --git a/vendor/github.com/containerd/cgroups/v2/hugetlb.go b/vendor/github.com/containerd/cgroups/v3/cgroup2/hugetlb.go
index 16b35bd78..b476b49ff 100644
--- a/vendor/github.com/containerd/cgroups/v2/hugetlb.go
+++ b/vendor/github.com/containerd/cgroups/v3/cgroup2/hugetlb.go
@@ -14,7 +14,7 @@
limitations under the License.
*/
-package v2
+package cgroup2
import "strings"
diff --git a/vendor/github.com/containerd/cgroups/v2/io.go b/vendor/github.com/containerd/cgroups/v3/cgroup2/io.go
index 70078d576..b70dd8ef5 100644
--- a/vendor/github.com/containerd/cgroups/v2/io.go
+++ b/vendor/github.com/containerd/cgroups/v3/cgroup2/io.go
@@ -14,7 +14,7 @@
limitations under the License.
*/
-package v2
+package cgroup2
import "fmt"
diff --git a/vendor/github.com/containerd/cgroups/v2/manager.go b/vendor/github.com/containerd/cgroups/v3/cgroup2/manager.go
index 1f017509f..fc9fcf453 100644
--- a/vendor/github.com/containerd/cgroups/v2/manager.go
+++ b/vendor/github.com/containerd/cgroups/v3/cgroup2/manager.go
@@ -14,14 +14,14 @@
limitations under the License.
*/
-package v2
+package cgroup2
import (
"bufio"
"context"
"errors"
"fmt"
- "io/ioutil"
+ "io"
"math"
"os"
"path/filepath"
@@ -30,7 +30,7 @@ import (
"syscall"
"time"
- "github.com/containerd/cgroups/v2/stats"
+ "github.com/containerd/cgroups/v3/cgroup2/stats"
systemdDbus "github.com/coreos/go-systemd/v22/dbus"
"github.com/godbus/dbus/v5"
@@ -42,6 +42,7 @@ import (
const (
subtreeControl = "cgroup.subtree_control"
controllersFile = "cgroup.controllers"
+ killFile = "cgroup.kill"
defaultCgroup2Path = "/sys/fs/cgroup"
defaultSlice = "system.slice"
)
@@ -144,20 +145,11 @@ func (c *Value) write(path string, perm os.FileMode) error {
return ErrInvalidFormat
}
- // Retry writes on EINTR; see:
- // https://github.com/golang/go/issues/38033
- for {
- err := ioutil.WriteFile(
- filepath.Join(path, c.filename),
- data,
- perm,
- )
- if err == nil {
- return nil
- } else if !errors.Is(err, syscall.EINTR) {
- return err
- }
- }
+ return os.WriteFile(
+ filepath.Join(path, c.filename),
+ data,
+ perm,
+ )
}
func writeValues(path string, values []Value) error {
@@ -196,13 +188,35 @@ func NewManager(mountpoint string, group string, resources *Resources) (*Manager
return &m, nil
}
-func LoadManager(mountpoint string, group string) (*Manager, error) {
+type InitConfig struct {
+ mountpoint string
+}
+
+type InitOpts func(c *InitConfig) error
+
+// WithMountpoint sets the unified mountpoint. The default path is /sys/fs/cgroup.
+func WithMountpoint(path string) InitOpts {
+ return func(c *InitConfig) error {
+ c.mountpoint = path
+ return nil
+ }
+}
+
+// Load a cgroup.
+func Load(group string, opts ...InitOpts) (*Manager, error) {
+ c := InitConfig{mountpoint: defaultCgroup2Path}
+ for _, opt := range opts {
+ if err := opt(&c); err != nil {
+ return nil, err
+ }
+ }
+
if err := VerifyGroupPath(group); err != nil {
return nil, err
}
- path := filepath.Join(mountpoint, group)
+ path := filepath.Join(c.mountpoint, group)
return &Manager{
- unifiedMountpoint: mountpoint,
+ unifiedMountpoint: c.mountpoint,
path: path,
}, nil
}
@@ -225,7 +239,7 @@ func setResources(path string, resources *Resources) error {
}
func (c *Manager) RootControllers() ([]string, error) {
- b, err := ioutil.ReadFile(filepath.Join(c.unifiedMountpoint, controllersFile))
+ b, err := os.ReadFile(filepath.Join(c.unifiedMountpoint, controllersFile))
if err != nil {
return nil, err
}
@@ -233,7 +247,7 @@ func (c *Manager) RootControllers() ([]string, error) {
}
func (c *Manager) Controllers() ([]string, error) {
- b, err := ioutil.ReadFile(filepath.Join(c.path, controllersFile))
+ b, err := os.ReadFile(filepath.Join(c.path, controllersFile))
if err != nil {
return nil, err
}
@@ -336,7 +350,103 @@ func (c *Manager) AddProc(pid uint64) error {
return writeValues(c.path, []Value{v})
}
+func (c *Manager) AddThread(tid uint64) error {
+ v := Value{
+ filename: cgroupThreads,
+ value: tid,
+ }
+ return writeValues(c.path, []Value{v})
+}
+
+// Kill will try to forcibly exit all of the processes in the cgroup. This is
+// equivalent to sending a SIGKILL to every process. On kernels 5.14 and greater
+// this will use the cgroup.kill file, on anything that doesn't have the cgroup.kill
+// file, a manual process of freezing -> sending a SIGKILL to every process -> thawing
+// will be used.
+func (c *Manager) Kill() error {
+ v := Value{
+ filename: killFile,
+ value: "1",
+ }
+ err := writeValues(c.path, []Value{v})
+ if err == nil {
+ return nil
+ }
+ logrus.Warnf("falling back to slower kill implementation: %s", err)
+ // Fallback to slow method.
+ return c.fallbackKill()
+}
+
+// fallbackKill is a slower fallback to the more modern (kernels 5.14+)
+// approach of writing to the cgroup.kill file. This is heavily pulled
+// from runc's same approach (in signalAllProcesses), with the only differences
+// being this is just tailored to the API exposed in this library, and we don't
+// need to care about signals other than SIGKILL.
+//
+// https://github.com/opencontainers/runc/blob/8da0a0b5675764feaaaaad466f6567a9983fcd08/libcontainer/init_linux.go#L523-L529
+func (c *Manager) fallbackKill() error {
+ if err := c.Freeze(); err != nil {
+ logrus.Warn(err)
+ }
+ pids, err := c.Procs(true)
+ if err != nil {
+ if err := c.Thaw(); err != nil {
+ logrus.Warn(err)
+ }
+ return err
+ }
+ var procs []*os.Process
+ for _, pid := range pids {
+ p, err := os.FindProcess(int(pid))
+ if err != nil {
+ logrus.Warn(err)
+ continue
+ }
+ procs = append(procs, p)
+ if err := p.Signal(unix.SIGKILL); err != nil {
+ logrus.Warn(err)
+ }
+ }
+ if err := c.Thaw(); err != nil {
+ logrus.Warn(err)
+ }
+
+ subreaper, err := getSubreaper()
+ if err != nil {
+ // The error here means that PR_GET_CHILD_SUBREAPER is not
+ // supported because this code might run on a kernel older
+ // than 3.4. We don't want to throw an error in that case,
+ // and we simplify things, considering there is no subreaper
+ // set.
+ subreaper = 0
+ }
+
+ for _, p := range procs {
+ // In case a subreaper has been setup, this code must not
+ // wait for the process. Otherwise, we cannot be sure the
+ // current process will be reaped by the subreaper, while
+ // the subreaper might be waiting for this process in order
+ // to retrieve its exit code.
+ if subreaper == 0 {
+ if _, err := p.Wait(); err != nil {
+ if !errors.Is(err, unix.ECHILD) {
+ logrus.Warnf("wait on pid %d failed: %s", p.Pid, err)
+ }
+ }
+ }
+ }
+ return nil
+}
+
func (c *Manager) Delete() error {
+ // kernel prevents cgroups with running process from being removed, check the tree is empty
+ processes, err := c.Procs(true)
+ if err != nil {
+ return err
+ }
+ if len(processes) > 0 {
+ return fmt.Errorf("cgroups: unable to remove path %q: still contains running processes", c.path)
+ }
return remove(c.path)
}
@@ -366,6 +476,22 @@ func (c *Manager) Procs(recursive bool) ([]uint64, error) {
return processes, err
}
+func (c *Manager) MoveTo(destination *Manager) error {
+ processes, err := c.Procs(true)
+ if err != nil {
+ return err
+ }
+ for _, p := range processes {
+ if err := destination.AddProc(p); err != nil {
+ if strings.Contains(err.Error(), "no such process") {
+ continue
+ }
+ return err
+ }
+ }
+ return nil
+}
+
var singleValueFiles = []string{
"pids.current",
"pids.max",
@@ -506,7 +632,7 @@ func readSingleFile(path string, file string, out map[string]interface{}) error
return err
}
defer f.Close()
- data, err := ioutil.ReadAll(f)
+ data, err := io.ReadAll(f)
if err != nil {
return err
}
@@ -709,7 +835,8 @@ func setDevices(path string, devices []specs.LinuxDeviceCgroup) error {
// the reason this is necessary is because the "-" character has a special meaning in
// systemd slice. For example, when creating a slice called "my-group-112233.slice",
// systemd will create a hierarchy like this:
-// /sys/fs/cgroup/my.slice/my-group.slice/my-group-112233.slice
+//
+// /sys/fs/cgroup/my.slice/my-group.slice/my-group-112233.slice
func getSystemdFullPath(slice, group string) string {
return filepath.Join(defaultCgroup2Path, dashesToPath(slice), dashesToPath(group))
}
diff --git a/vendor/github.com/containerd/cgroups/v2/memory.go b/vendor/github.com/containerd/cgroups/v3/cgroup2/memory.go
index 6f4733be6..8cc8962bd 100644
--- a/vendor/github.com/containerd/cgroups/v2/memory.go
+++ b/vendor/github.com/containerd/cgroups/v3/cgroup2/memory.go
@@ -14,7 +14,7 @@
limitations under the License.
*/
-package v2
+package cgroup2
type Memory struct {
Swap *int64
diff --git a/vendor/github.com/containerd/cgroups/v2/paths.go b/vendor/github.com/containerd/cgroups/v3/cgroup2/paths.go
index c4778c142..074bb83bc 100644
--- a/vendor/github.com/containerd/cgroups/v2/paths.go
+++ b/vendor/github.com/containerd/cgroups/v3/cgroup2/paths.go
@@ -14,7 +14,7 @@
limitations under the License.
*/
-package v2
+package cgroup2
import (
"fmt"
diff --git a/vendor/github.com/containerd/cgroups/v2/pids.go b/vendor/github.com/containerd/cgroups/v3/cgroup2/pids.go
index 0b5aa0c3b..7de263260 100644
--- a/vendor/github.com/containerd/cgroups/v2/pids.go
+++ b/vendor/github.com/containerd/cgroups/v3/cgroup2/pids.go
@@ -14,7 +14,7 @@
limitations under the License.
*/
-package v2
+package cgroup2
import "strconv"
diff --git a/vendor/github.com/containerd/cgroups/v2/rdma.go b/vendor/github.com/containerd/cgroups/v3/cgroup2/rdma.go
index 44caa4f57..2a65117f1 100644
--- a/vendor/github.com/containerd/cgroups/v2/rdma.go
+++ b/vendor/github.com/containerd/cgroups/v3/cgroup2/rdma.go
@@ -14,7 +14,7 @@
limitations under the License.
*/
-package v2
+package cgroup2
import (
"fmt"
diff --git a/vendor/github.com/containerd/cgroups/v2/state.go b/vendor/github.com/containerd/cgroups/v3/cgroup2/state.go
index 09b75b6c3..886e94b29 100644
--- a/vendor/github.com/containerd/cgroups/v2/state.go
+++ b/vendor/github.com/containerd/cgroups/v3/cgroup2/state.go
@@ -14,10 +14,10 @@
limitations under the License.
*/
-package v2
+package cgroup2
import (
- "io/ioutil"
+ "os"
"path/filepath"
"strings"
)
@@ -50,7 +50,7 @@ func (s State) Values() []Value {
}
func fetchState(path string) (State, error) {
- current, err := ioutil.ReadFile(filepath.Join(path, cgroupFreeze))
+ current, err := os.ReadFile(filepath.Join(path, cgroupFreeze))
if err != nil {
return Unknown, err
}
diff --git a/vendor/github.com/containerd/cgroups/stats/v1/doc.go b/vendor/github.com/containerd/cgroups/v3/cgroup2/stats/doc.go
index 23f3cdd4b..e51e12f80 100644
--- a/vendor/github.com/containerd/cgroups/stats/v1/doc.go
+++ b/vendor/github.com/containerd/cgroups/v3/cgroup2/stats/doc.go
@@ -14,4 +14,4 @@
limitations under the License.
*/
-package v1
+package stats
diff --git a/vendor/github.com/containerd/cgroups/v3/cgroup2/stats/metrics.pb.go b/vendor/github.com/containerd/cgroups/v3/cgroup2/stats/metrics.pb.go
new file mode 100644
index 000000000..d4cb4ad48
--- /dev/null
+++ b/vendor/github.com/containerd/cgroups/v3/cgroup2/stats/metrics.pb.go
@@ -0,0 +1,1333 @@
+// Code generated by protoc-gen-go. DO NOT EDIT.
+// versions:
+// protoc-gen-go v1.28.1
+// protoc v3.21.5
+// source: github.com/containerd/cgroups/cgroup2/stats/metrics.proto
+
+package stats
+
+import (
+ protoreflect "google.golang.org/protobuf/reflect/protoreflect"
+ protoimpl "google.golang.org/protobuf/runtime/protoimpl"
+ reflect "reflect"
+ sync "sync"
+)
+
+const (
+ // Verify that this generated code is sufficiently up-to-date.
+ _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion)
+ // Verify that runtime/protoimpl is sufficiently up-to-date.
+ _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
+)
+
+type Metrics struct {
+ state protoimpl.MessageState
+ sizeCache protoimpl.SizeCache
+ unknownFields protoimpl.UnknownFields
+
+ Pids *PidsStat `protobuf:"bytes,1,opt,name=pids,proto3" json:"pids,omitempty"`
+ CPU *CPUStat `protobuf:"bytes,2,opt,name=cpu,proto3" json:"cpu,omitempty"`
+ Memory *MemoryStat `protobuf:"bytes,4,opt,name=memory,proto3" json:"memory,omitempty"`
+ Rdma *RdmaStat `protobuf:"bytes,5,opt,name=rdma,proto3" json:"rdma,omitempty"`
+ Io *IOStat `protobuf:"bytes,6,opt,name=io,proto3" json:"io,omitempty"`
+ Hugetlb []*HugeTlbStat `protobuf:"bytes,7,rep,name=hugetlb,proto3" json:"hugetlb,omitempty"`
+ MemoryEvents *MemoryEvents `protobuf:"bytes,8,opt,name=memory_events,json=memoryEvents,proto3" json:"memory_events,omitempty"`
+}
+
+func (x *Metrics) Reset() {
+ *x = Metrics{}
+ if protoimpl.UnsafeEnabled {
+ mi := &file_github_com_containerd_cgroups_cgroup2_stats_metrics_proto_msgTypes[0]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
+ }
+}
+
+func (x *Metrics) String() string {
+ return protoimpl.X.MessageStringOf(x)
+}
+
+func (*Metrics) ProtoMessage() {}
+
+func (x *Metrics) ProtoReflect() protoreflect.Message {
+ mi := &file_github_com_containerd_cgroups_cgroup2_stats_metrics_proto_msgTypes[0]
+ if protoimpl.UnsafeEnabled && x != nil {
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ if ms.LoadMessageInfo() == nil {
+ ms.StoreMessageInfo(mi)
+ }
+ return ms
+ }
+ return mi.MessageOf(x)
+}
+
+// Deprecated: Use Metrics.ProtoReflect.Descriptor instead.
+func (*Metrics) Descriptor() ([]byte, []int) {
+ return file_github_com_containerd_cgroups_cgroup2_stats_metrics_proto_rawDescGZIP(), []int{0}
+}
+
+func (x *Metrics) GetPids() *PidsStat {
+ if x != nil {
+ return x.Pids
+ }
+ return nil
+}
+
+func (x *Metrics) GetCPU() *CPUStat {
+ if x != nil {
+ return x.CPU
+ }
+ return nil
+}
+
+func (x *Metrics) GetMemory() *MemoryStat {
+ if x != nil {
+ return x.Memory
+ }
+ return nil
+}
+
+func (x *Metrics) GetRdma() *RdmaStat {
+ if x != nil {
+ return x.Rdma
+ }
+ return nil
+}
+
+func (x *Metrics) GetIo() *IOStat {
+ if x != nil {
+ return x.Io
+ }
+ return nil
+}
+
+func (x *Metrics) GetHugetlb() []*HugeTlbStat {
+ if x != nil {
+ return x.Hugetlb
+ }
+ return nil
+}
+
+func (x *Metrics) GetMemoryEvents() *MemoryEvents {
+ if x != nil {
+ return x.MemoryEvents
+ }
+ return nil
+}
+
+type PidsStat struct {
+ state protoimpl.MessageState
+ sizeCache protoimpl.SizeCache
+ unknownFields protoimpl.UnknownFields
+
+ Current uint64 `protobuf:"varint,1,opt,name=current,proto3" json:"current,omitempty"`
+ Limit uint64 `protobuf:"varint,2,opt,name=limit,proto3" json:"limit,omitempty"`
+}
+
+func (x *PidsStat) Reset() {
+ *x = PidsStat{}
+ if protoimpl.UnsafeEnabled {
+ mi := &file_github_com_containerd_cgroups_cgroup2_stats_metrics_proto_msgTypes[1]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
+ }
+}
+
+func (x *PidsStat) String() string {
+ return protoimpl.X.MessageStringOf(x)
+}
+
+func (*PidsStat) ProtoMessage() {}
+
+func (x *PidsStat) ProtoReflect() protoreflect.Message {
+ mi := &file_github_com_containerd_cgroups_cgroup2_stats_metrics_proto_msgTypes[1]
+ if protoimpl.UnsafeEnabled && x != nil {
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ if ms.LoadMessageInfo() == nil {
+ ms.StoreMessageInfo(mi)
+ }
+ return ms
+ }
+ return mi.MessageOf(x)
+}
+
+// Deprecated: Use PidsStat.ProtoReflect.Descriptor instead.
+func (*PidsStat) Descriptor() ([]byte, []int) {
+ return file_github_com_containerd_cgroups_cgroup2_stats_metrics_proto_rawDescGZIP(), []int{1}
+}
+
+func (x *PidsStat) GetCurrent() uint64 {
+ if x != nil {
+ return x.Current
+ }
+ return 0
+}
+
+func (x *PidsStat) GetLimit() uint64 {
+ if x != nil {
+ return x.Limit
+ }
+ return 0
+}
+
+type CPUStat struct {
+ state protoimpl.MessageState
+ sizeCache protoimpl.SizeCache
+ unknownFields protoimpl.UnknownFields
+
+ UsageUsec uint64 `protobuf:"varint,1,opt,name=usage_usec,json=usageUsec,proto3" json:"usage_usec,omitempty"`
+ UserUsec uint64 `protobuf:"varint,2,opt,name=user_usec,json=userUsec,proto3" json:"user_usec,omitempty"`
+ SystemUsec uint64 `protobuf:"varint,3,opt,name=system_usec,json=systemUsec,proto3" json:"system_usec,omitempty"`
+ NrPeriods uint64 `protobuf:"varint,4,opt,name=nr_periods,json=nrPeriods,proto3" json:"nr_periods,omitempty"`
+ NrThrottled uint64 `protobuf:"varint,5,opt,name=nr_throttled,json=nrThrottled,proto3" json:"nr_throttled,omitempty"`
+ ThrottledUsec uint64 `protobuf:"varint,6,opt,name=throttled_usec,json=throttledUsec,proto3" json:"throttled_usec,omitempty"`
+}
+
+func (x *CPUStat) Reset() {
+ *x = CPUStat{}
+ if protoimpl.UnsafeEnabled {
+ mi := &file_github_com_containerd_cgroups_cgroup2_stats_metrics_proto_msgTypes[2]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
+ }
+}
+
+func (x *CPUStat) String() string {
+ return protoimpl.X.MessageStringOf(x)
+}
+
+func (*CPUStat) ProtoMessage() {}
+
+func (x *CPUStat) ProtoReflect() protoreflect.Message {
+ mi := &file_github_com_containerd_cgroups_cgroup2_stats_metrics_proto_msgTypes[2]
+ if protoimpl.UnsafeEnabled && x != nil {
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ if ms.LoadMessageInfo() == nil {
+ ms.StoreMessageInfo(mi)
+ }
+ return ms
+ }
+ return mi.MessageOf(x)
+}
+
+// Deprecated: Use CPUStat.ProtoReflect.Descriptor instead.
+func (*CPUStat) Descriptor() ([]byte, []int) {
+ return file_github_com_containerd_cgroups_cgroup2_stats_metrics_proto_rawDescGZIP(), []int{2}
+}
+
+func (x *CPUStat) GetUsageUsec() uint64 {
+ if x != nil {
+ return x.UsageUsec
+ }
+ return 0
+}
+
+func (x *CPUStat) GetUserUsec() uint64 {
+ if x != nil {
+ return x.UserUsec
+ }
+ return 0
+}
+
+func (x *CPUStat) GetSystemUsec() uint64 {
+ if x != nil {
+ return x.SystemUsec
+ }
+ return 0
+}
+
+func (x *CPUStat) GetNrPeriods() uint64 {
+ if x != nil {
+ return x.NrPeriods
+ }
+ return 0
+}
+
+func (x *CPUStat) GetNrThrottled() uint64 {
+ if x != nil {
+ return x.NrThrottled
+ }
+ return 0
+}
+
+func (x *CPUStat) GetThrottledUsec() uint64 {
+ if x != nil {
+ return x.ThrottledUsec
+ }
+ return 0
+}
+
+type MemoryStat struct {
+ state protoimpl.MessageState
+ sizeCache protoimpl.SizeCache
+ unknownFields protoimpl.UnknownFields
+
+ Anon uint64 `protobuf:"varint,1,opt,name=anon,proto3" json:"anon,omitempty"`
+ File uint64 `protobuf:"varint,2,opt,name=file,proto3" json:"file,omitempty"`
+ KernelStack uint64 `protobuf:"varint,3,opt,name=kernel_stack,json=kernelStack,proto3" json:"kernel_stack,omitempty"`
+ Slab uint64 `protobuf:"varint,4,opt,name=slab,proto3" json:"slab,omitempty"`
+ Sock uint64 `protobuf:"varint,5,opt,name=sock,proto3" json:"sock,omitempty"`
+ Shmem uint64 `protobuf:"varint,6,opt,name=shmem,proto3" json:"shmem,omitempty"`
+ FileMapped uint64 `protobuf:"varint,7,opt,name=file_mapped,json=fileMapped,proto3" json:"file_mapped,omitempty"`
+ FileDirty uint64 `protobuf:"varint,8,opt,name=file_dirty,json=fileDirty,proto3" json:"file_dirty,omitempty"`
+ FileWriteback uint64 `protobuf:"varint,9,opt,name=file_writeback,json=fileWriteback,proto3" json:"file_writeback,omitempty"`
+ AnonThp uint64 `protobuf:"varint,10,opt,name=anon_thp,json=anonThp,proto3" json:"anon_thp,omitempty"`
+ InactiveAnon uint64 `protobuf:"varint,11,opt,name=inactive_anon,json=inactiveAnon,proto3" json:"inactive_anon,omitempty"`
+ ActiveAnon uint64 `protobuf:"varint,12,opt,name=active_anon,json=activeAnon,proto3" json:"active_anon,omitempty"`
+ InactiveFile uint64 `protobuf:"varint,13,opt,name=inactive_file,json=inactiveFile,proto3" json:"inactive_file,omitempty"`
+ ActiveFile uint64 `protobuf:"varint,14,opt,name=active_file,json=activeFile,proto3" json:"active_file,omitempty"`
+ Unevictable uint64 `protobuf:"varint,15,opt,name=unevictable,proto3" json:"unevictable,omitempty"`
+ SlabReclaimable uint64 `protobuf:"varint,16,opt,name=slab_reclaimable,json=slabReclaimable,proto3" json:"slab_reclaimable,omitempty"`
+ SlabUnreclaimable uint64 `protobuf:"varint,17,opt,name=slab_unreclaimable,json=slabUnreclaimable,proto3" json:"slab_unreclaimable,omitempty"`
+ Pgfault uint64 `protobuf:"varint,18,opt,name=pgfault,proto3" json:"pgfault,omitempty"`
+ Pgmajfault uint64 `protobuf:"varint,19,opt,name=pgmajfault,proto3" json:"pgmajfault,omitempty"`
+ WorkingsetRefault uint64 `protobuf:"varint,20,opt,name=workingset_refault,json=workingsetRefault,proto3" json:"workingset_refault,omitempty"`
+ WorkingsetActivate uint64 `protobuf:"varint,21,opt,name=workingset_activate,json=workingsetActivate,proto3" json:"workingset_activate,omitempty"`
+ WorkingsetNodereclaim uint64 `protobuf:"varint,22,opt,name=workingset_nodereclaim,json=workingsetNodereclaim,proto3" json:"workingset_nodereclaim,omitempty"`
+ Pgrefill uint64 `protobuf:"varint,23,opt,name=pgrefill,proto3" json:"pgrefill,omitempty"`
+ Pgscan uint64 `protobuf:"varint,24,opt,name=pgscan,proto3" json:"pgscan,omitempty"`
+ Pgsteal uint64 `protobuf:"varint,25,opt,name=pgsteal,proto3" json:"pgsteal,omitempty"`
+ Pgactivate uint64 `protobuf:"varint,26,opt,name=pgactivate,proto3" json:"pgactivate,omitempty"`
+ Pgdeactivate uint64 `protobuf:"varint,27,opt,name=pgdeactivate,proto3" json:"pgdeactivate,omitempty"`
+ Pglazyfree uint64 `protobuf:"varint,28,opt,name=pglazyfree,proto3" json:"pglazyfree,omitempty"`
+ Pglazyfreed uint64 `protobuf:"varint,29,opt,name=pglazyfreed,proto3" json:"pglazyfreed,omitempty"`
+ ThpFaultAlloc uint64 `protobuf:"varint,30,opt,name=thp_fault_alloc,json=thpFaultAlloc,proto3" json:"thp_fault_alloc,omitempty"`
+ ThpCollapseAlloc uint64 `protobuf:"varint,31,opt,name=thp_collapse_alloc,json=thpCollapseAlloc,proto3" json:"thp_collapse_alloc,omitempty"`
+ Usage uint64 `protobuf:"varint,32,opt,name=usage,proto3" json:"usage,omitempty"`
+ UsageLimit uint64 `protobuf:"varint,33,opt,name=usage_limit,json=usageLimit,proto3" json:"usage_limit,omitempty"`
+ SwapUsage uint64 `protobuf:"varint,34,opt,name=swap_usage,json=swapUsage,proto3" json:"swap_usage,omitempty"`
+ SwapLimit uint64 `protobuf:"varint,35,opt,name=swap_limit,json=swapLimit,proto3" json:"swap_limit,omitempty"`
+}
+
+func (x *MemoryStat) Reset() {
+ *x = MemoryStat{}
+ if protoimpl.UnsafeEnabled {
+ mi := &file_github_com_containerd_cgroups_cgroup2_stats_metrics_proto_msgTypes[3]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
+ }
+}
+
+func (x *MemoryStat) String() string {
+ return protoimpl.X.MessageStringOf(x)
+}
+
+func (*MemoryStat) ProtoMessage() {}
+
+func (x *MemoryStat) ProtoReflect() protoreflect.Message {
+ mi := &file_github_com_containerd_cgroups_cgroup2_stats_metrics_proto_msgTypes[3]
+ if protoimpl.UnsafeEnabled && x != nil {
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ if ms.LoadMessageInfo() == nil {
+ ms.StoreMessageInfo(mi)
+ }
+ return ms
+ }
+ return mi.MessageOf(x)
+}
+
+// Deprecated: Use MemoryStat.ProtoReflect.Descriptor instead.
+func (*MemoryStat) Descriptor() ([]byte, []int) {
+ return file_github_com_containerd_cgroups_cgroup2_stats_metrics_proto_rawDescGZIP(), []int{3}
+}
+
+func (x *MemoryStat) GetAnon() uint64 {
+ if x != nil {
+ return x.Anon
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetFile() uint64 {
+ if x != nil {
+ return x.File
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetKernelStack() uint64 {
+ if x != nil {
+ return x.KernelStack
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetSlab() uint64 {
+ if x != nil {
+ return x.Slab
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetSock() uint64 {
+ if x != nil {
+ return x.Sock
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetShmem() uint64 {
+ if x != nil {
+ return x.Shmem
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetFileMapped() uint64 {
+ if x != nil {
+ return x.FileMapped
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetFileDirty() uint64 {
+ if x != nil {
+ return x.FileDirty
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetFileWriteback() uint64 {
+ if x != nil {
+ return x.FileWriteback
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetAnonThp() uint64 {
+ if x != nil {
+ return x.AnonThp
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetInactiveAnon() uint64 {
+ if x != nil {
+ return x.InactiveAnon
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetActiveAnon() uint64 {
+ if x != nil {
+ return x.ActiveAnon
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetInactiveFile() uint64 {
+ if x != nil {
+ return x.InactiveFile
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetActiveFile() uint64 {
+ if x != nil {
+ return x.ActiveFile
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetUnevictable() uint64 {
+ if x != nil {
+ return x.Unevictable
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetSlabReclaimable() uint64 {
+ if x != nil {
+ return x.SlabReclaimable
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetSlabUnreclaimable() uint64 {
+ if x != nil {
+ return x.SlabUnreclaimable
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetPgfault() uint64 {
+ if x != nil {
+ return x.Pgfault
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetPgmajfault() uint64 {
+ if x != nil {
+ return x.Pgmajfault
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetWorkingsetRefault() uint64 {
+ if x != nil {
+ return x.WorkingsetRefault
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetWorkingsetActivate() uint64 {
+ if x != nil {
+ return x.WorkingsetActivate
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetWorkingsetNodereclaim() uint64 {
+ if x != nil {
+ return x.WorkingsetNodereclaim
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetPgrefill() uint64 {
+ if x != nil {
+ return x.Pgrefill
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetPgscan() uint64 {
+ if x != nil {
+ return x.Pgscan
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetPgsteal() uint64 {
+ if x != nil {
+ return x.Pgsteal
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetPgactivate() uint64 {
+ if x != nil {
+ return x.Pgactivate
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetPgdeactivate() uint64 {
+ if x != nil {
+ return x.Pgdeactivate
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetPglazyfree() uint64 {
+ if x != nil {
+ return x.Pglazyfree
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetPglazyfreed() uint64 {
+ if x != nil {
+ return x.Pglazyfreed
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetThpFaultAlloc() uint64 {
+ if x != nil {
+ return x.ThpFaultAlloc
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetThpCollapseAlloc() uint64 {
+ if x != nil {
+ return x.ThpCollapseAlloc
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetUsage() uint64 {
+ if x != nil {
+ return x.Usage
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetUsageLimit() uint64 {
+ if x != nil {
+ return x.UsageLimit
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetSwapUsage() uint64 {
+ if x != nil {
+ return x.SwapUsage
+ }
+ return 0
+}
+
+func (x *MemoryStat) GetSwapLimit() uint64 {
+ if x != nil {
+ return x.SwapLimit
+ }
+ return 0
+}
+
+type MemoryEvents struct {
+ state protoimpl.MessageState
+ sizeCache protoimpl.SizeCache
+ unknownFields protoimpl.UnknownFields
+
+ Low uint64 `protobuf:"varint,1,opt,name=low,proto3" json:"low,omitempty"`
+ High uint64 `protobuf:"varint,2,opt,name=high,proto3" json:"high,omitempty"`
+ Max uint64 `protobuf:"varint,3,opt,name=max,proto3" json:"max,omitempty"`
+ Oom uint64 `protobuf:"varint,4,opt,name=oom,proto3" json:"oom,omitempty"`
+ OomKill uint64 `protobuf:"varint,5,opt,name=oom_kill,json=oomKill,proto3" json:"oom_kill,omitempty"`
+}
+
+func (x *MemoryEvents) Reset() {
+ *x = MemoryEvents{}
+ if protoimpl.UnsafeEnabled {
+ mi := &file_github_com_containerd_cgroups_cgroup2_stats_metrics_proto_msgTypes[4]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
+ }
+}
+
+func (x *MemoryEvents) String() string {
+ return protoimpl.X.MessageStringOf(x)
+}
+
+func (*MemoryEvents) ProtoMessage() {}
+
+func (x *MemoryEvents) ProtoReflect() protoreflect.Message {
+ mi := &file_github_com_containerd_cgroups_cgroup2_stats_metrics_proto_msgTypes[4]
+ if protoimpl.UnsafeEnabled && x != nil {
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ if ms.LoadMessageInfo() == nil {
+ ms.StoreMessageInfo(mi)
+ }
+ return ms
+ }
+ return mi.MessageOf(x)
+}
+
+// Deprecated: Use MemoryEvents.ProtoReflect.Descriptor instead.
+func (*MemoryEvents) Descriptor() ([]byte, []int) {
+ return file_github_com_containerd_cgroups_cgroup2_stats_metrics_proto_rawDescGZIP(), []int{4}
+}
+
+func (x *MemoryEvents) GetLow() uint64 {
+ if x != nil {
+ return x.Low
+ }
+ return 0
+}
+
+func (x *MemoryEvents) GetHigh() uint64 {
+ if x != nil {
+ return x.High
+ }
+ return 0
+}
+
+func (x *MemoryEvents) GetMax() uint64 {
+ if x != nil {
+ return x.Max
+ }
+ return 0
+}
+
+func (x *MemoryEvents) GetOom() uint64 {
+ if x != nil {
+ return x.Oom
+ }
+ return 0
+}
+
+func (x *MemoryEvents) GetOomKill() uint64 {
+ if x != nil {
+ return x.OomKill
+ }
+ return 0
+}
+
+type RdmaStat struct {
+ state protoimpl.MessageState
+ sizeCache protoimpl.SizeCache
+ unknownFields protoimpl.UnknownFields
+
+ Current []*RdmaEntry `protobuf:"bytes,1,rep,name=current,proto3" json:"current,omitempty"`
+ Limit []*RdmaEntry `protobuf:"bytes,2,rep,name=limit,proto3" json:"limit,omitempty"`
+}
+
+func (x *RdmaStat) Reset() {
+ *x = RdmaStat{}
+ if protoimpl.UnsafeEnabled {
+ mi := &file_github_com_containerd_cgroups_cgroup2_stats_metrics_proto_msgTypes[5]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
+ }
+}
+
+func (x *RdmaStat) String() string {
+ return protoimpl.X.MessageStringOf(x)
+}
+
+func (*RdmaStat) ProtoMessage() {}
+
+func (x *RdmaStat) ProtoReflect() protoreflect.Message {
+ mi := &file_github_com_containerd_cgroups_cgroup2_stats_metrics_proto_msgTypes[5]
+ if protoimpl.UnsafeEnabled && x != nil {
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ if ms.LoadMessageInfo() == nil {
+ ms.StoreMessageInfo(mi)
+ }
+ return ms
+ }
+ return mi.MessageOf(x)
+}
+
+// Deprecated: Use RdmaStat.ProtoReflect.Descriptor instead.
+func (*RdmaStat) Descriptor() ([]byte, []int) {
+ return file_github_com_containerd_cgroups_cgroup2_stats_metrics_proto_rawDescGZIP(), []int{5}
+}
+
+func (x *RdmaStat) GetCurrent() []*RdmaEntry {
+ if x != nil {
+ return x.Current
+ }
+ return nil
+}
+
+func (x *RdmaStat) GetLimit() []*RdmaEntry {
+ if x != nil {
+ return x.Limit
+ }
+ return nil
+}
+
+type RdmaEntry struct {
+ state protoimpl.MessageState
+ sizeCache protoimpl.SizeCache
+ unknownFields protoimpl.UnknownFields
+
+ Device string `protobuf:"bytes,1,opt,name=device,proto3" json:"device,omitempty"`
+ HcaHandles uint32 `protobuf:"varint,2,opt,name=hca_handles,json=hcaHandles,proto3" json:"hca_handles,omitempty"`
+ HcaObjects uint32 `protobuf:"varint,3,opt,name=hca_objects,json=hcaObjects,proto3" json:"hca_objects,omitempty"`
+}
+
+func (x *RdmaEntry) Reset() {
+ *x = RdmaEntry{}
+ if protoimpl.UnsafeEnabled {
+ mi := &file_github_com_containerd_cgroups_cgroup2_stats_metrics_proto_msgTypes[6]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
+ }
+}
+
+func (x *RdmaEntry) String() string {
+ return protoimpl.X.MessageStringOf(x)
+}
+
+func (*RdmaEntry) ProtoMessage() {}
+
+func (x *RdmaEntry) ProtoReflect() protoreflect.Message {
+ mi := &file_github_com_containerd_cgroups_cgroup2_stats_metrics_proto_msgTypes[6]
+ if protoimpl.UnsafeEnabled && x != nil {
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ if ms.LoadMessageInfo() == nil {
+ ms.StoreMessageInfo(mi)
+ }
+ return ms
+ }
+ return mi.MessageOf(x)
+}
+
+// Deprecated: Use RdmaEntry.ProtoReflect.Descriptor instead.
+func (*RdmaEntry) Descriptor() ([]byte, []int) {
+ return file_github_com_containerd_cgroups_cgroup2_stats_metrics_proto_rawDescGZIP(), []int{6}
+}
+
+func (x *RdmaEntry) GetDevice() string {
+ if x != nil {
+ return x.Device
+ }
+ return ""
+}
+
+func (x *RdmaEntry) GetHcaHandles() uint32 {
+ if x != nil {
+ return x.HcaHandles
+ }
+ return 0
+}
+
+func (x *RdmaEntry) GetHcaObjects() uint32 {
+ if x != nil {
+ return x.HcaObjects
+ }
+ return 0
+}
+
+type IOStat struct {
+ state protoimpl.MessageState
+ sizeCache protoimpl.SizeCache
+ unknownFields protoimpl.UnknownFields
+
+ Usage []*IOEntry `protobuf:"bytes,1,rep,name=usage,proto3" json:"usage,omitempty"`
+}
+
+func (x *IOStat) Reset() {
+ *x = IOStat{}
+ if protoimpl.UnsafeEnabled {
+ mi := &file_github_com_containerd_cgroups_cgroup2_stats_metrics_proto_msgTypes[7]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
+ }
+}
+
+func (x *IOStat) String() string {
+ return protoimpl.X.MessageStringOf(x)
+}
+
+func (*IOStat) ProtoMessage() {}
+
+func (x *IOStat) ProtoReflect() protoreflect.Message {
+ mi := &file_github_com_containerd_cgroups_cgroup2_stats_metrics_proto_msgTypes[7]
+ if protoimpl.UnsafeEnabled && x != nil {
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ if ms.LoadMessageInfo() == nil {
+ ms.StoreMessageInfo(mi)
+ }
+ return ms
+ }
+ return mi.MessageOf(x)
+}
+
+// Deprecated: Use IOStat.ProtoReflect.Descriptor instead.
+func (*IOStat) Descriptor() ([]byte, []int) {
+ return file_github_com_containerd_cgroups_cgroup2_stats_metrics_proto_rawDescGZIP(), []int{7}
+}
+
+func (x *IOStat) GetUsage() []*IOEntry {
+ if x != nil {
+ return x.Usage
+ }
+ return nil
+}
+
+type IOEntry struct {
+ state protoimpl.MessageState
+ sizeCache protoimpl.SizeCache
+ unknownFields protoimpl.UnknownFields
+
+ Major uint64 `protobuf:"varint,1,opt,name=major,proto3" json:"major,omitempty"`
+ Minor uint64 `protobuf:"varint,2,opt,name=minor,proto3" json:"minor,omitempty"`
+ Rbytes uint64 `protobuf:"varint,3,opt,name=rbytes,proto3" json:"rbytes,omitempty"`
+ Wbytes uint64 `protobuf:"varint,4,opt,name=wbytes,proto3" json:"wbytes,omitempty"`
+ Rios uint64 `protobuf:"varint,5,opt,name=rios,proto3" json:"rios,omitempty"`
+ Wios uint64 `protobuf:"varint,6,opt,name=wios,proto3" json:"wios,omitempty"`
+}
+
+func (x *IOEntry) Reset() {
+ *x = IOEntry{}
+ if protoimpl.UnsafeEnabled {
+ mi := &file_github_com_containerd_cgroups_cgroup2_stats_metrics_proto_msgTypes[8]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
+ }
+}
+
+func (x *IOEntry) String() string {
+ return protoimpl.X.MessageStringOf(x)
+}
+
+func (*IOEntry) ProtoMessage() {}
+
+func (x *IOEntry) ProtoReflect() protoreflect.Message {
+ mi := &file_github_com_containerd_cgroups_cgroup2_stats_metrics_proto_msgTypes[8]
+ if protoimpl.UnsafeEnabled && x != nil {
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ if ms.LoadMessageInfo() == nil {
+ ms.StoreMessageInfo(mi)
+ }
+ return ms
+ }
+ return mi.MessageOf(x)
+}
+
+// Deprecated: Use IOEntry.ProtoReflect.Descriptor instead.
+func (*IOEntry) Descriptor() ([]byte, []int) {
+ return file_github_com_containerd_cgroups_cgroup2_stats_metrics_proto_rawDescGZIP(), []int{8}
+}
+
+func (x *IOEntry) GetMajor() uint64 {
+ if x != nil {
+ return x.Major
+ }
+ return 0
+}
+
+func (x *IOEntry) GetMinor() uint64 {
+ if x != nil {
+ return x.Minor
+ }
+ return 0
+}
+
+func (x *IOEntry) GetRbytes() uint64 {
+ if x != nil {
+ return x.Rbytes
+ }
+ return 0
+}
+
+func (x *IOEntry) GetWbytes() uint64 {
+ if x != nil {
+ return x.Wbytes
+ }
+ return 0
+}
+
+func (x *IOEntry) GetRios() uint64 {
+ if x != nil {
+ return x.Rios
+ }
+ return 0
+}
+
+func (x *IOEntry) GetWios() uint64 {
+ if x != nil {
+ return x.Wios
+ }
+ return 0
+}
+
+type HugeTlbStat struct {
+ state protoimpl.MessageState
+ sizeCache protoimpl.SizeCache
+ unknownFields protoimpl.UnknownFields
+
+ Current uint64 `protobuf:"varint,1,opt,name=current,proto3" json:"current,omitempty"`
+ Max uint64 `protobuf:"varint,2,opt,name=max,proto3" json:"max,omitempty"`
+ Pagesize string `protobuf:"bytes,3,opt,name=pagesize,proto3" json:"pagesize,omitempty"`
+}
+
+func (x *HugeTlbStat) Reset() {
+ *x = HugeTlbStat{}
+ if protoimpl.UnsafeEnabled {
+ mi := &file_github_com_containerd_cgroups_cgroup2_stats_metrics_proto_msgTypes[9]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
+ }
+}
+
+func (x *HugeTlbStat) String() string {
+ return protoimpl.X.MessageStringOf(x)
+}
+
+func (*HugeTlbStat) ProtoMessage() {}
+
+func (x *HugeTlbStat) ProtoReflect() protoreflect.Message {
+ mi := &file_github_com_containerd_cgroups_cgroup2_stats_metrics_proto_msgTypes[9]
+ if protoimpl.UnsafeEnabled && x != nil {
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ if ms.LoadMessageInfo() == nil {
+ ms.StoreMessageInfo(mi)
+ }
+ return ms
+ }
+ return mi.MessageOf(x)
+}
+
+// Deprecated: Use HugeTlbStat.ProtoReflect.Descriptor instead.
+func (*HugeTlbStat) Descriptor() ([]byte, []int) {
+ return file_github_com_containerd_cgroups_cgroup2_stats_metrics_proto_rawDescGZIP(), []int{9}
+}
+
+func (x *HugeTlbStat) GetCurrent() uint64 {
+ if x != nil {
+ return x.Current
+ }
+ return 0
+}
+
+func (x *HugeTlbStat) GetMax() uint64 {
+ if x != nil {
+ return x.Max
+ }
+ return 0
+}
+
+func (x *HugeTlbStat) GetPagesize() string {
+ if x != nil {
+ return x.Pagesize
+ }
+ return ""
+}
+
+var File_github_com_containerd_cgroups_cgroup2_stats_metrics_proto protoreflect.FileDescriptor
+
+var file_github_com_containerd_cgroups_cgroup2_stats_metrics_proto_rawDesc = []byte{
+ 0x0a, 0x39, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x63, 0x6f, 0x6e,
+ 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x64, 0x2f, 0x63, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x73, 0x2f,
+ 0x63, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x32, 0x2f, 0x73, 0x74, 0x61, 0x74, 0x73, 0x2f, 0x6d, 0x65,
+ 0x74, 0x72, 0x69, 0x63, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x18, 0x69, 0x6f, 0x2e,
+ 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x64, 0x2e, 0x63, 0x67, 0x72, 0x6f, 0x75,
+ 0x70, 0x73, 0x2e, 0x76, 0x32, 0x22, 0xac, 0x03, 0x0a, 0x07, 0x4d, 0x65, 0x74, 0x72, 0x69, 0x63,
+ 0x73, 0x12, 0x36, 0x0a, 0x04, 0x70, 0x69, 0x64, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32,
+ 0x22, 0x2e, 0x69, 0x6f, 0x2e, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x64, 0x2e,
+ 0x63, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x50, 0x69, 0x64, 0x73, 0x53,
+ 0x74, 0x61, 0x74, 0x52, 0x04, 0x70, 0x69, 0x64, 0x73, 0x12, 0x33, 0x0a, 0x03, 0x63, 0x70, 0x75,
+ 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x69, 0x6f, 0x2e, 0x63, 0x6f, 0x6e, 0x74,
+ 0x61, 0x69, 0x6e, 0x65, 0x72, 0x64, 0x2e, 0x63, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x73, 0x2e, 0x76,
+ 0x32, 0x2e, 0x43, 0x50, 0x55, 0x53, 0x74, 0x61, 0x74, 0x52, 0x03, 0x63, 0x70, 0x75, 0x12, 0x3c,
+ 0x0a, 0x06, 0x6d, 0x65, 0x6d, 0x6f, 0x72, 0x79, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x24,
+ 0x2e, 0x69, 0x6f, 0x2e, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x64, 0x2e, 0x63,
+ 0x67, 0x72, 0x6f, 0x75, 0x70, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x4d, 0x65, 0x6d, 0x6f, 0x72, 0x79,
+ 0x53, 0x74, 0x61, 0x74, 0x52, 0x06, 0x6d, 0x65, 0x6d, 0x6f, 0x72, 0x79, 0x12, 0x36, 0x0a, 0x04,
+ 0x72, 0x64, 0x6d, 0x61, 0x18, 0x05, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x22, 0x2e, 0x69, 0x6f, 0x2e,
+ 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x64, 0x2e, 0x63, 0x67, 0x72, 0x6f, 0x75,
+ 0x70, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x52, 0x64, 0x6d, 0x61, 0x53, 0x74, 0x61, 0x74, 0x52, 0x04,
+ 0x72, 0x64, 0x6d, 0x61, 0x12, 0x30, 0x0a, 0x02, 0x69, 0x6f, 0x18, 0x06, 0x20, 0x01, 0x28, 0x0b,
+ 0x32, 0x20, 0x2e, 0x69, 0x6f, 0x2e, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x64,
+ 0x2e, 0x63, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x49, 0x4f, 0x53, 0x74,
+ 0x61, 0x74, 0x52, 0x02, 0x69, 0x6f, 0x12, 0x3f, 0x0a, 0x07, 0x68, 0x75, 0x67, 0x65, 0x74, 0x6c,
+ 0x62, 0x18, 0x07, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x25, 0x2e, 0x69, 0x6f, 0x2e, 0x63, 0x6f, 0x6e,
+ 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x64, 0x2e, 0x63, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x73, 0x2e,
+ 0x76, 0x32, 0x2e, 0x48, 0x75, 0x67, 0x65, 0x54, 0x6c, 0x62, 0x53, 0x74, 0x61, 0x74, 0x52, 0x07,
+ 0x68, 0x75, 0x67, 0x65, 0x74, 0x6c, 0x62, 0x12, 0x4b, 0x0a, 0x0d, 0x6d, 0x65, 0x6d, 0x6f, 0x72,
+ 0x79, 0x5f, 0x65, 0x76, 0x65, 0x6e, 0x74, 0x73, 0x18, 0x08, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x26,
+ 0x2e, 0x69, 0x6f, 0x2e, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x64, 0x2e, 0x63,
+ 0x67, 0x72, 0x6f, 0x75, 0x70, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x4d, 0x65, 0x6d, 0x6f, 0x72, 0x79,
+ 0x45, 0x76, 0x65, 0x6e, 0x74, 0x73, 0x52, 0x0c, 0x6d, 0x65, 0x6d, 0x6f, 0x72, 0x79, 0x45, 0x76,
+ 0x65, 0x6e, 0x74, 0x73, 0x22, 0x3a, 0x0a, 0x08, 0x50, 0x69, 0x64, 0x73, 0x53, 0x74, 0x61, 0x74,
+ 0x12, 0x18, 0x0a, 0x07, 0x63, 0x75, 0x72, 0x72, 0x65, 0x6e, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28,
+ 0x04, 0x52, 0x07, 0x63, 0x75, 0x72, 0x72, 0x65, 0x6e, 0x74, 0x12, 0x14, 0x0a, 0x05, 0x6c, 0x69,
+ 0x6d, 0x69, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x04, 0x52, 0x05, 0x6c, 0x69, 0x6d, 0x69, 0x74,
+ 0x22, 0xcf, 0x01, 0x0a, 0x07, 0x43, 0x50, 0x55, 0x53, 0x74, 0x61, 0x74, 0x12, 0x1d, 0x0a, 0x0a,
+ 0x75, 0x73, 0x61, 0x67, 0x65, 0x5f, 0x75, 0x73, 0x65, 0x63, 0x18, 0x01, 0x20, 0x01, 0x28, 0x04,
+ 0x52, 0x09, 0x75, 0x73, 0x61, 0x67, 0x65, 0x55, 0x73, 0x65, 0x63, 0x12, 0x1b, 0x0a, 0x09, 0x75,
+ 0x73, 0x65, 0x72, 0x5f, 0x75, 0x73, 0x65, 0x63, 0x18, 0x02, 0x20, 0x01, 0x28, 0x04, 0x52, 0x08,
+ 0x75, 0x73, 0x65, 0x72, 0x55, 0x73, 0x65, 0x63, 0x12, 0x1f, 0x0a, 0x0b, 0x73, 0x79, 0x73, 0x74,
+ 0x65, 0x6d, 0x5f, 0x75, 0x73, 0x65, 0x63, 0x18, 0x03, 0x20, 0x01, 0x28, 0x04, 0x52, 0x0a, 0x73,
+ 0x79, 0x73, 0x74, 0x65, 0x6d, 0x55, 0x73, 0x65, 0x63, 0x12, 0x1d, 0x0a, 0x0a, 0x6e, 0x72, 0x5f,
+ 0x70, 0x65, 0x72, 0x69, 0x6f, 0x64, 0x73, 0x18, 0x04, 0x20, 0x01, 0x28, 0x04, 0x52, 0x09, 0x6e,
+ 0x72, 0x50, 0x65, 0x72, 0x69, 0x6f, 0x64, 0x73, 0x12, 0x21, 0x0a, 0x0c, 0x6e, 0x72, 0x5f, 0x74,
+ 0x68, 0x72, 0x6f, 0x74, 0x74, 0x6c, 0x65, 0x64, 0x18, 0x05, 0x20, 0x01, 0x28, 0x04, 0x52, 0x0b,
+ 0x6e, 0x72, 0x54, 0x68, 0x72, 0x6f, 0x74, 0x74, 0x6c, 0x65, 0x64, 0x12, 0x25, 0x0a, 0x0e, 0x74,
+ 0x68, 0x72, 0x6f, 0x74, 0x74, 0x6c, 0x65, 0x64, 0x5f, 0x75, 0x73, 0x65, 0x63, 0x18, 0x06, 0x20,
+ 0x01, 0x28, 0x04, 0x52, 0x0d, 0x74, 0x68, 0x72, 0x6f, 0x74, 0x74, 0x6c, 0x65, 0x64, 0x55, 0x73,
+ 0x65, 0x63, 0x22, 0x8f, 0x09, 0x0a, 0x0a, 0x4d, 0x65, 0x6d, 0x6f, 0x72, 0x79, 0x53, 0x74, 0x61,
+ 0x74, 0x12, 0x12, 0x0a, 0x04, 0x61, 0x6e, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x04, 0x52,
+ 0x04, 0x61, 0x6e, 0x6f, 0x6e, 0x12, 0x12, 0x0a, 0x04, 0x66, 0x69, 0x6c, 0x65, 0x18, 0x02, 0x20,
+ 0x01, 0x28, 0x04, 0x52, 0x04, 0x66, 0x69, 0x6c, 0x65, 0x12, 0x21, 0x0a, 0x0c, 0x6b, 0x65, 0x72,
+ 0x6e, 0x65, 0x6c, 0x5f, 0x73, 0x74, 0x61, 0x63, 0x6b, 0x18, 0x03, 0x20, 0x01, 0x28, 0x04, 0x52,
+ 0x0b, 0x6b, 0x65, 0x72, 0x6e, 0x65, 0x6c, 0x53, 0x74, 0x61, 0x63, 0x6b, 0x12, 0x12, 0x0a, 0x04,
+ 0x73, 0x6c, 0x61, 0x62, 0x18, 0x04, 0x20, 0x01, 0x28, 0x04, 0x52, 0x04, 0x73, 0x6c, 0x61, 0x62,
+ 0x12, 0x12, 0x0a, 0x04, 0x73, 0x6f, 0x63, 0x6b, 0x18, 0x05, 0x20, 0x01, 0x28, 0x04, 0x52, 0x04,
+ 0x73, 0x6f, 0x63, 0x6b, 0x12, 0x14, 0x0a, 0x05, 0x73, 0x68, 0x6d, 0x65, 0x6d, 0x18, 0x06, 0x20,
+ 0x01, 0x28, 0x04, 0x52, 0x05, 0x73, 0x68, 0x6d, 0x65, 0x6d, 0x12, 0x1f, 0x0a, 0x0b, 0x66, 0x69,
+ 0x6c, 0x65, 0x5f, 0x6d, 0x61, 0x70, 0x70, 0x65, 0x64, 0x18, 0x07, 0x20, 0x01, 0x28, 0x04, 0x52,
+ 0x0a, 0x66, 0x69, 0x6c, 0x65, 0x4d, 0x61, 0x70, 0x70, 0x65, 0x64, 0x12, 0x1d, 0x0a, 0x0a, 0x66,
+ 0x69, 0x6c, 0x65, 0x5f, 0x64, 0x69, 0x72, 0x74, 0x79, 0x18, 0x08, 0x20, 0x01, 0x28, 0x04, 0x52,
+ 0x09, 0x66, 0x69, 0x6c, 0x65, 0x44, 0x69, 0x72, 0x74, 0x79, 0x12, 0x25, 0x0a, 0x0e, 0x66, 0x69,
+ 0x6c, 0x65, 0x5f, 0x77, 0x72, 0x69, 0x74, 0x65, 0x62, 0x61, 0x63, 0x6b, 0x18, 0x09, 0x20, 0x01,
+ 0x28, 0x04, 0x52, 0x0d, 0x66, 0x69, 0x6c, 0x65, 0x57, 0x72, 0x69, 0x74, 0x65, 0x62, 0x61, 0x63,
+ 0x6b, 0x12, 0x19, 0x0a, 0x08, 0x61, 0x6e, 0x6f, 0x6e, 0x5f, 0x74, 0x68, 0x70, 0x18, 0x0a, 0x20,
+ 0x01, 0x28, 0x04, 0x52, 0x07, 0x61, 0x6e, 0x6f, 0x6e, 0x54, 0x68, 0x70, 0x12, 0x23, 0x0a, 0x0d,
+ 0x69, 0x6e, 0x61, 0x63, 0x74, 0x69, 0x76, 0x65, 0x5f, 0x61, 0x6e, 0x6f, 0x6e, 0x18, 0x0b, 0x20,
+ 0x01, 0x28, 0x04, 0x52, 0x0c, 0x69, 0x6e, 0x61, 0x63, 0x74, 0x69, 0x76, 0x65, 0x41, 0x6e, 0x6f,
+ 0x6e, 0x12, 0x1f, 0x0a, 0x0b, 0x61, 0x63, 0x74, 0x69, 0x76, 0x65, 0x5f, 0x61, 0x6e, 0x6f, 0x6e,
+ 0x18, 0x0c, 0x20, 0x01, 0x28, 0x04, 0x52, 0x0a, 0x61, 0x63, 0x74, 0x69, 0x76, 0x65, 0x41, 0x6e,
+ 0x6f, 0x6e, 0x12, 0x23, 0x0a, 0x0d, 0x69, 0x6e, 0x61, 0x63, 0x74, 0x69, 0x76, 0x65, 0x5f, 0x66,
+ 0x69, 0x6c, 0x65, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x04, 0x52, 0x0c, 0x69, 0x6e, 0x61, 0x63, 0x74,
+ 0x69, 0x76, 0x65, 0x46, 0x69, 0x6c, 0x65, 0x12, 0x1f, 0x0a, 0x0b, 0x61, 0x63, 0x74, 0x69, 0x76,
+ 0x65, 0x5f, 0x66, 0x69, 0x6c, 0x65, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x04, 0x52, 0x0a, 0x61, 0x63,
+ 0x74, 0x69, 0x76, 0x65, 0x46, 0x69, 0x6c, 0x65, 0x12, 0x20, 0x0a, 0x0b, 0x75, 0x6e, 0x65, 0x76,
+ 0x69, 0x63, 0x74, 0x61, 0x62, 0x6c, 0x65, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x04, 0x52, 0x0b, 0x75,
+ 0x6e, 0x65, 0x76, 0x69, 0x63, 0x74, 0x61, 0x62, 0x6c, 0x65, 0x12, 0x29, 0x0a, 0x10, 0x73, 0x6c,
+ 0x61, 0x62, 0x5f, 0x72, 0x65, 0x63, 0x6c, 0x61, 0x69, 0x6d, 0x61, 0x62, 0x6c, 0x65, 0x18, 0x10,
+ 0x20, 0x01, 0x28, 0x04, 0x52, 0x0f, 0x73, 0x6c, 0x61, 0x62, 0x52, 0x65, 0x63, 0x6c, 0x61, 0x69,
+ 0x6d, 0x61, 0x62, 0x6c, 0x65, 0x12, 0x2d, 0x0a, 0x12, 0x73, 0x6c, 0x61, 0x62, 0x5f, 0x75, 0x6e,
+ 0x72, 0x65, 0x63, 0x6c, 0x61, 0x69, 0x6d, 0x61, 0x62, 0x6c, 0x65, 0x18, 0x11, 0x20, 0x01, 0x28,
+ 0x04, 0x52, 0x11, 0x73, 0x6c, 0x61, 0x62, 0x55, 0x6e, 0x72, 0x65, 0x63, 0x6c, 0x61, 0x69, 0x6d,
+ 0x61, 0x62, 0x6c, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x70, 0x67, 0x66, 0x61, 0x75, 0x6c, 0x74, 0x18,
+ 0x12, 0x20, 0x01, 0x28, 0x04, 0x52, 0x07, 0x70, 0x67, 0x66, 0x61, 0x75, 0x6c, 0x74, 0x12, 0x1e,
+ 0x0a, 0x0a, 0x70, 0x67, 0x6d, 0x61, 0x6a, 0x66, 0x61, 0x75, 0x6c, 0x74, 0x18, 0x13, 0x20, 0x01,
+ 0x28, 0x04, 0x52, 0x0a, 0x70, 0x67, 0x6d, 0x61, 0x6a, 0x66, 0x61, 0x75, 0x6c, 0x74, 0x12, 0x2d,
+ 0x0a, 0x12, 0x77, 0x6f, 0x72, 0x6b, 0x69, 0x6e, 0x67, 0x73, 0x65, 0x74, 0x5f, 0x72, 0x65, 0x66,
+ 0x61, 0x75, 0x6c, 0x74, 0x18, 0x14, 0x20, 0x01, 0x28, 0x04, 0x52, 0x11, 0x77, 0x6f, 0x72, 0x6b,
+ 0x69, 0x6e, 0x67, 0x73, 0x65, 0x74, 0x52, 0x65, 0x66, 0x61, 0x75, 0x6c, 0x74, 0x12, 0x2f, 0x0a,
+ 0x13, 0x77, 0x6f, 0x72, 0x6b, 0x69, 0x6e, 0x67, 0x73, 0x65, 0x74, 0x5f, 0x61, 0x63, 0x74, 0x69,
+ 0x76, 0x61, 0x74, 0x65, 0x18, 0x15, 0x20, 0x01, 0x28, 0x04, 0x52, 0x12, 0x77, 0x6f, 0x72, 0x6b,
+ 0x69, 0x6e, 0x67, 0x73, 0x65, 0x74, 0x41, 0x63, 0x74, 0x69, 0x76, 0x61, 0x74, 0x65, 0x12, 0x35,
+ 0x0a, 0x16, 0x77, 0x6f, 0x72, 0x6b, 0x69, 0x6e, 0x67, 0x73, 0x65, 0x74, 0x5f, 0x6e, 0x6f, 0x64,
+ 0x65, 0x72, 0x65, 0x63, 0x6c, 0x61, 0x69, 0x6d, 0x18, 0x16, 0x20, 0x01, 0x28, 0x04, 0x52, 0x15,
+ 0x77, 0x6f, 0x72, 0x6b, 0x69, 0x6e, 0x67, 0x73, 0x65, 0x74, 0x4e, 0x6f, 0x64, 0x65, 0x72, 0x65,
+ 0x63, 0x6c, 0x61, 0x69, 0x6d, 0x12, 0x1a, 0x0a, 0x08, 0x70, 0x67, 0x72, 0x65, 0x66, 0x69, 0x6c,
+ 0x6c, 0x18, 0x17, 0x20, 0x01, 0x28, 0x04, 0x52, 0x08, 0x70, 0x67, 0x72, 0x65, 0x66, 0x69, 0x6c,
+ 0x6c, 0x12, 0x16, 0x0a, 0x06, 0x70, 0x67, 0x73, 0x63, 0x61, 0x6e, 0x18, 0x18, 0x20, 0x01, 0x28,
+ 0x04, 0x52, 0x06, 0x70, 0x67, 0x73, 0x63, 0x61, 0x6e, 0x12, 0x18, 0x0a, 0x07, 0x70, 0x67, 0x73,
+ 0x74, 0x65, 0x61, 0x6c, 0x18, 0x19, 0x20, 0x01, 0x28, 0x04, 0x52, 0x07, 0x70, 0x67, 0x73, 0x74,
+ 0x65, 0x61, 0x6c, 0x12, 0x1e, 0x0a, 0x0a, 0x70, 0x67, 0x61, 0x63, 0x74, 0x69, 0x76, 0x61, 0x74,
+ 0x65, 0x18, 0x1a, 0x20, 0x01, 0x28, 0x04, 0x52, 0x0a, 0x70, 0x67, 0x61, 0x63, 0x74, 0x69, 0x76,
+ 0x61, 0x74, 0x65, 0x12, 0x22, 0x0a, 0x0c, 0x70, 0x67, 0x64, 0x65, 0x61, 0x63, 0x74, 0x69, 0x76,
+ 0x61, 0x74, 0x65, 0x18, 0x1b, 0x20, 0x01, 0x28, 0x04, 0x52, 0x0c, 0x70, 0x67, 0x64, 0x65, 0x61,
+ 0x63, 0x74, 0x69, 0x76, 0x61, 0x74, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x70, 0x67, 0x6c, 0x61, 0x7a,
+ 0x79, 0x66, 0x72, 0x65, 0x65, 0x18, 0x1c, 0x20, 0x01, 0x28, 0x04, 0x52, 0x0a, 0x70, 0x67, 0x6c,
+ 0x61, 0x7a, 0x79, 0x66, 0x72, 0x65, 0x65, 0x12, 0x20, 0x0a, 0x0b, 0x70, 0x67, 0x6c, 0x61, 0x7a,
+ 0x79, 0x66, 0x72, 0x65, 0x65, 0x64, 0x18, 0x1d, 0x20, 0x01, 0x28, 0x04, 0x52, 0x0b, 0x70, 0x67,
+ 0x6c, 0x61, 0x7a, 0x79, 0x66, 0x72, 0x65, 0x65, 0x64, 0x12, 0x26, 0x0a, 0x0f, 0x74, 0x68, 0x70,
+ 0x5f, 0x66, 0x61, 0x75, 0x6c, 0x74, 0x5f, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x18, 0x1e, 0x20, 0x01,
+ 0x28, 0x04, 0x52, 0x0d, 0x74, 0x68, 0x70, 0x46, 0x61, 0x75, 0x6c, 0x74, 0x41, 0x6c, 0x6c, 0x6f,
+ 0x63, 0x12, 0x2c, 0x0a, 0x12, 0x74, 0x68, 0x70, 0x5f, 0x63, 0x6f, 0x6c, 0x6c, 0x61, 0x70, 0x73,
+ 0x65, 0x5f, 0x61, 0x6c, 0x6c, 0x6f, 0x63, 0x18, 0x1f, 0x20, 0x01, 0x28, 0x04, 0x52, 0x10, 0x74,
+ 0x68, 0x70, 0x43, 0x6f, 0x6c, 0x6c, 0x61, 0x70, 0x73, 0x65, 0x41, 0x6c, 0x6c, 0x6f, 0x63, 0x12,
+ 0x14, 0x0a, 0x05, 0x75, 0x73, 0x61, 0x67, 0x65, 0x18, 0x20, 0x20, 0x01, 0x28, 0x04, 0x52, 0x05,
+ 0x75, 0x73, 0x61, 0x67, 0x65, 0x12, 0x1f, 0x0a, 0x0b, 0x75, 0x73, 0x61, 0x67, 0x65, 0x5f, 0x6c,
+ 0x69, 0x6d, 0x69, 0x74, 0x18, 0x21, 0x20, 0x01, 0x28, 0x04, 0x52, 0x0a, 0x75, 0x73, 0x61, 0x67,
+ 0x65, 0x4c, 0x69, 0x6d, 0x69, 0x74, 0x12, 0x1d, 0x0a, 0x0a, 0x73, 0x77, 0x61, 0x70, 0x5f, 0x75,
+ 0x73, 0x61, 0x67, 0x65, 0x18, 0x22, 0x20, 0x01, 0x28, 0x04, 0x52, 0x09, 0x73, 0x77, 0x61, 0x70,
+ 0x55, 0x73, 0x61, 0x67, 0x65, 0x12, 0x1d, 0x0a, 0x0a, 0x73, 0x77, 0x61, 0x70, 0x5f, 0x6c, 0x69,
+ 0x6d, 0x69, 0x74, 0x18, 0x23, 0x20, 0x01, 0x28, 0x04, 0x52, 0x09, 0x73, 0x77, 0x61, 0x70, 0x4c,
+ 0x69, 0x6d, 0x69, 0x74, 0x22, 0x73, 0x0a, 0x0c, 0x4d, 0x65, 0x6d, 0x6f, 0x72, 0x79, 0x45, 0x76,
+ 0x65, 0x6e, 0x74, 0x73, 0x12, 0x10, 0x0a, 0x03, 0x6c, 0x6f, 0x77, 0x18, 0x01, 0x20, 0x01, 0x28,
+ 0x04, 0x52, 0x03, 0x6c, 0x6f, 0x77, 0x12, 0x12, 0x0a, 0x04, 0x68, 0x69, 0x67, 0x68, 0x18, 0x02,
+ 0x20, 0x01, 0x28, 0x04, 0x52, 0x04, 0x68, 0x69, 0x67, 0x68, 0x12, 0x10, 0x0a, 0x03, 0x6d, 0x61,
+ 0x78, 0x18, 0x03, 0x20, 0x01, 0x28, 0x04, 0x52, 0x03, 0x6d, 0x61, 0x78, 0x12, 0x10, 0x0a, 0x03,
+ 0x6f, 0x6f, 0x6d, 0x18, 0x04, 0x20, 0x01, 0x28, 0x04, 0x52, 0x03, 0x6f, 0x6f, 0x6d, 0x12, 0x19,
+ 0x0a, 0x08, 0x6f, 0x6f, 0x6d, 0x5f, 0x6b, 0x69, 0x6c, 0x6c, 0x18, 0x05, 0x20, 0x01, 0x28, 0x04,
+ 0x52, 0x07, 0x6f, 0x6f, 0x6d, 0x4b, 0x69, 0x6c, 0x6c, 0x22, 0x84, 0x01, 0x0a, 0x08, 0x52, 0x64,
+ 0x6d, 0x61, 0x53, 0x74, 0x61, 0x74, 0x12, 0x3d, 0x0a, 0x07, 0x63, 0x75, 0x72, 0x72, 0x65, 0x6e,
+ 0x74, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x23, 0x2e, 0x69, 0x6f, 0x2e, 0x63, 0x6f, 0x6e,
+ 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x64, 0x2e, 0x63, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x73, 0x2e,
+ 0x76, 0x32, 0x2e, 0x52, 0x64, 0x6d, 0x61, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x07, 0x63, 0x75,
+ 0x72, 0x72, 0x65, 0x6e, 0x74, 0x12, 0x39, 0x0a, 0x05, 0x6c, 0x69, 0x6d, 0x69, 0x74, 0x18, 0x02,
+ 0x20, 0x03, 0x28, 0x0b, 0x32, 0x23, 0x2e, 0x69, 0x6f, 0x2e, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69,
+ 0x6e, 0x65, 0x72, 0x64, 0x2e, 0x63, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x73, 0x2e, 0x76, 0x32, 0x2e,
+ 0x52, 0x64, 0x6d, 0x61, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x05, 0x6c, 0x69, 0x6d, 0x69, 0x74,
+ 0x22, 0x65, 0x0a, 0x09, 0x52, 0x64, 0x6d, 0x61, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x16, 0x0a,
+ 0x06, 0x64, 0x65, 0x76, 0x69, 0x63, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x64,
+ 0x65, 0x76, 0x69, 0x63, 0x65, 0x12, 0x1f, 0x0a, 0x0b, 0x68, 0x63, 0x61, 0x5f, 0x68, 0x61, 0x6e,
+ 0x64, 0x6c, 0x65, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x0a, 0x68, 0x63, 0x61, 0x48,
+ 0x61, 0x6e, 0x64, 0x6c, 0x65, 0x73, 0x12, 0x1f, 0x0a, 0x0b, 0x68, 0x63, 0x61, 0x5f, 0x6f, 0x62,
+ 0x6a, 0x65, 0x63, 0x74, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x0a, 0x68, 0x63, 0x61,
+ 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x73, 0x22, 0x41, 0x0a, 0x06, 0x49, 0x4f, 0x53, 0x74, 0x61,
+ 0x74, 0x12, 0x37, 0x0a, 0x05, 0x75, 0x73, 0x61, 0x67, 0x65, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b,
+ 0x32, 0x21, 0x2e, 0x69, 0x6f, 0x2e, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x64,
+ 0x2e, 0x63, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x49, 0x4f, 0x45, 0x6e,
+ 0x74, 0x72, 0x79, 0x52, 0x05, 0x75, 0x73, 0x61, 0x67, 0x65, 0x22, 0x8d, 0x01, 0x0a, 0x07, 0x49,
+ 0x4f, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x14, 0x0a, 0x05, 0x6d, 0x61, 0x6a, 0x6f, 0x72, 0x18,
+ 0x01, 0x20, 0x01, 0x28, 0x04, 0x52, 0x05, 0x6d, 0x61, 0x6a, 0x6f, 0x72, 0x12, 0x14, 0x0a, 0x05,
+ 0x6d, 0x69, 0x6e, 0x6f, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x04, 0x52, 0x05, 0x6d, 0x69, 0x6e,
+ 0x6f, 0x72, 0x12, 0x16, 0x0a, 0x06, 0x72, 0x62, 0x79, 0x74, 0x65, 0x73, 0x18, 0x03, 0x20, 0x01,
+ 0x28, 0x04, 0x52, 0x06, 0x72, 0x62, 0x79, 0x74, 0x65, 0x73, 0x12, 0x16, 0x0a, 0x06, 0x77, 0x62,
+ 0x79, 0x74, 0x65, 0x73, 0x18, 0x04, 0x20, 0x01, 0x28, 0x04, 0x52, 0x06, 0x77, 0x62, 0x79, 0x74,
+ 0x65, 0x73, 0x12, 0x12, 0x0a, 0x04, 0x72, 0x69, 0x6f, 0x73, 0x18, 0x05, 0x20, 0x01, 0x28, 0x04,
+ 0x52, 0x04, 0x72, 0x69, 0x6f, 0x73, 0x12, 0x12, 0x0a, 0x04, 0x77, 0x69, 0x6f, 0x73, 0x18, 0x06,
+ 0x20, 0x01, 0x28, 0x04, 0x52, 0x04, 0x77, 0x69, 0x6f, 0x73, 0x22, 0x55, 0x0a, 0x0b, 0x48, 0x75,
+ 0x67, 0x65, 0x54, 0x6c, 0x62, 0x53, 0x74, 0x61, 0x74, 0x12, 0x18, 0x0a, 0x07, 0x63, 0x75, 0x72,
+ 0x72, 0x65, 0x6e, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x04, 0x52, 0x07, 0x63, 0x75, 0x72, 0x72,
+ 0x65, 0x6e, 0x74, 0x12, 0x10, 0x0a, 0x03, 0x6d, 0x61, 0x78, 0x18, 0x02, 0x20, 0x01, 0x28, 0x04,
+ 0x52, 0x03, 0x6d, 0x61, 0x78, 0x12, 0x1a, 0x0a, 0x08, 0x70, 0x61, 0x67, 0x65, 0x73, 0x69, 0x7a,
+ 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x67, 0x65, 0x73, 0x69, 0x7a,
+ 0x65, 0x42, 0x2d, 0x5a, 0x2b, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f,
+ 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x64, 0x2f, 0x63, 0x67, 0x72, 0x6f, 0x75,
+ 0x70, 0x73, 0x2f, 0x63, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x32, 0x2f, 0x73, 0x74, 0x61, 0x74, 0x73,
+ 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
+}
+
+var (
+ file_github_com_containerd_cgroups_cgroup2_stats_metrics_proto_rawDescOnce sync.Once
+ file_github_com_containerd_cgroups_cgroup2_stats_metrics_proto_rawDescData = file_github_com_containerd_cgroups_cgroup2_stats_metrics_proto_rawDesc
+)
+
+func file_github_com_containerd_cgroups_cgroup2_stats_metrics_proto_rawDescGZIP() []byte {
+ file_github_com_containerd_cgroups_cgroup2_stats_metrics_proto_rawDescOnce.Do(func() {
+ file_github_com_containerd_cgroups_cgroup2_stats_metrics_proto_rawDescData = protoimpl.X.CompressGZIP(file_github_com_containerd_cgroups_cgroup2_stats_metrics_proto_rawDescData)
+ })
+ return file_github_com_containerd_cgroups_cgroup2_stats_metrics_proto_rawDescData
+}
+
+var file_github_com_containerd_cgroups_cgroup2_stats_metrics_proto_msgTypes = make([]protoimpl.MessageInfo, 10)
+var file_github_com_containerd_cgroups_cgroup2_stats_metrics_proto_goTypes = []interface{}{
+ (*Metrics)(nil), // 0: io.containerd.cgroups.v2.Metrics
+ (*PidsStat)(nil), // 1: io.containerd.cgroups.v2.PidsStat
+ (*CPUStat)(nil), // 2: io.containerd.cgroups.v2.CPUStat
+ (*MemoryStat)(nil), // 3: io.containerd.cgroups.v2.MemoryStat
+ (*MemoryEvents)(nil), // 4: io.containerd.cgroups.v2.MemoryEvents
+ (*RdmaStat)(nil), // 5: io.containerd.cgroups.v2.RdmaStat
+ (*RdmaEntry)(nil), // 6: io.containerd.cgroups.v2.RdmaEntry
+ (*IOStat)(nil), // 7: io.containerd.cgroups.v2.IOStat
+ (*IOEntry)(nil), // 8: io.containerd.cgroups.v2.IOEntry
+ (*HugeTlbStat)(nil), // 9: io.containerd.cgroups.v2.HugeTlbStat
+}
+var file_github_com_containerd_cgroups_cgroup2_stats_metrics_proto_depIdxs = []int32{
+ 1, // 0: io.containerd.cgroups.v2.Metrics.pids:type_name -> io.containerd.cgroups.v2.PidsStat
+ 2, // 1: io.containerd.cgroups.v2.Metrics.cpu:type_name -> io.containerd.cgroups.v2.CPUStat
+ 3, // 2: io.containerd.cgroups.v2.Metrics.memory:type_name -> io.containerd.cgroups.v2.MemoryStat
+ 5, // 3: io.containerd.cgroups.v2.Metrics.rdma:type_name -> io.containerd.cgroups.v2.RdmaStat
+ 7, // 4: io.containerd.cgroups.v2.Metrics.io:type_name -> io.containerd.cgroups.v2.IOStat
+ 9, // 5: io.containerd.cgroups.v2.Metrics.hugetlb:type_name -> io.containerd.cgroups.v2.HugeTlbStat
+ 4, // 6: io.containerd.cgroups.v2.Metrics.memory_events:type_name -> io.containerd.cgroups.v2.MemoryEvents
+ 6, // 7: io.containerd.cgroups.v2.RdmaStat.current:type_name -> io.containerd.cgroups.v2.RdmaEntry
+ 6, // 8: io.containerd.cgroups.v2.RdmaStat.limit:type_name -> io.containerd.cgroups.v2.RdmaEntry
+ 8, // 9: io.containerd.cgroups.v2.IOStat.usage:type_name -> io.containerd.cgroups.v2.IOEntry
+ 10, // [10:10] is the sub-list for method output_type
+ 10, // [10:10] is the sub-list for method input_type
+ 10, // [10:10] is the sub-list for extension type_name
+ 10, // [10:10] is the sub-list for extension extendee
+ 0, // [0:10] is the sub-list for field type_name
+}
+
+func init() { file_github_com_containerd_cgroups_cgroup2_stats_metrics_proto_init() }
+func file_github_com_containerd_cgroups_cgroup2_stats_metrics_proto_init() {
+ if File_github_com_containerd_cgroups_cgroup2_stats_metrics_proto != nil {
+ return
+ }
+ if !protoimpl.UnsafeEnabled {
+ file_github_com_containerd_cgroups_cgroup2_stats_metrics_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} {
+ switch v := v.(*Metrics); i {
+ case 0:
+ return &v.state
+ case 1:
+ return &v.sizeCache
+ case 2:
+ return &v.unknownFields
+ default:
+ return nil
+ }
+ }
+ file_github_com_containerd_cgroups_cgroup2_stats_metrics_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} {
+ switch v := v.(*PidsStat); i {
+ case 0:
+ return &v.state
+ case 1:
+ return &v.sizeCache
+ case 2:
+ return &v.unknownFields
+ default:
+ return nil
+ }
+ }
+ file_github_com_containerd_cgroups_cgroup2_stats_metrics_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} {
+ switch v := v.(*CPUStat); i {
+ case 0:
+ return &v.state
+ case 1:
+ return &v.sizeCache
+ case 2:
+ return &v.unknownFields
+ default:
+ return nil
+ }
+ }
+ file_github_com_containerd_cgroups_cgroup2_stats_metrics_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} {
+ switch v := v.(*MemoryStat); i {
+ case 0:
+ return &v.state
+ case 1:
+ return &v.sizeCache
+ case 2:
+ return &v.unknownFields
+ default:
+ return nil
+ }
+ }
+ file_github_com_containerd_cgroups_cgroup2_stats_metrics_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} {
+ switch v := v.(*MemoryEvents); i {
+ case 0:
+ return &v.state
+ case 1:
+ return &v.sizeCache
+ case 2:
+ return &v.unknownFields
+ default:
+ return nil
+ }
+ }
+ file_github_com_containerd_cgroups_cgroup2_stats_metrics_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} {
+ switch v := v.(*RdmaStat); i {
+ case 0:
+ return &v.state
+ case 1:
+ return &v.sizeCache
+ case 2:
+ return &v.unknownFields
+ default:
+ return nil
+ }
+ }
+ file_github_com_containerd_cgroups_cgroup2_stats_metrics_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} {
+ switch v := v.(*RdmaEntry); i {
+ case 0:
+ return &v.state
+ case 1:
+ return &v.sizeCache
+ case 2:
+ return &v.unknownFields
+ default:
+ return nil
+ }
+ }
+ file_github_com_containerd_cgroups_cgroup2_stats_metrics_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} {
+ switch v := v.(*IOStat); i {
+ case 0:
+ return &v.state
+ case 1:
+ return &v.sizeCache
+ case 2:
+ return &v.unknownFields
+ default:
+ return nil
+ }
+ }
+ file_github_com_containerd_cgroups_cgroup2_stats_metrics_proto_msgTypes[8].Exporter = func(v interface{}, i int) interface{} {
+ switch v := v.(*IOEntry); i {
+ case 0:
+ return &v.state
+ case 1:
+ return &v.sizeCache
+ case 2:
+ return &v.unknownFields
+ default:
+ return nil
+ }
+ }
+ file_github_com_containerd_cgroups_cgroup2_stats_metrics_proto_msgTypes[9].Exporter = func(v interface{}, i int) interface{} {
+ switch v := v.(*HugeTlbStat); i {
+ case 0:
+ return &v.state
+ case 1:
+ return &v.sizeCache
+ case 2:
+ return &v.unknownFields
+ default:
+ return nil
+ }
+ }
+ }
+ type x struct{}
+ out := protoimpl.TypeBuilder{
+ File: protoimpl.DescBuilder{
+ GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
+ RawDescriptor: file_github_com_containerd_cgroups_cgroup2_stats_metrics_proto_rawDesc,
+ NumEnums: 0,
+ NumMessages: 10,
+ NumExtensions: 0,
+ NumServices: 0,
+ },
+ GoTypes: file_github_com_containerd_cgroups_cgroup2_stats_metrics_proto_goTypes,
+ DependencyIndexes: file_github_com_containerd_cgroups_cgroup2_stats_metrics_proto_depIdxs,
+ MessageInfos: file_github_com_containerd_cgroups_cgroup2_stats_metrics_proto_msgTypes,
+ }.Build()
+ File_github_com_containerd_cgroups_cgroup2_stats_metrics_proto = out.File
+ file_github_com_containerd_cgroups_cgroup2_stats_metrics_proto_rawDesc = nil
+ file_github_com_containerd_cgroups_cgroup2_stats_metrics_proto_goTypes = nil
+ file_github_com_containerd_cgroups_cgroup2_stats_metrics_proto_depIdxs = nil
+}
diff --git a/vendor/github.com/containerd/cgroups/v2/stats/metrics.pb.txt b/vendor/github.com/containerd/cgroups/v3/cgroup2/stats/metrics.pb.txt
index 59fe27cbf..f9b0cd343 100644
--- a/vendor/github.com/containerd/cgroups/v2/stats/metrics.pb.txt
+++ b/vendor/github.com/containerd/cgroups/v3/cgroup2/stats/metrics.pb.txt
@@ -1,7 +1,6 @@
file {
- name: "github.com/containerd/cgroups/v2/stats/metrics.proto"
+ name: "github.com/containerd/cgroups/cgroup2/stats/metrics.proto"
package: "io.containerd.cgroups.v2"
- dependency: "gogoproto/gogo.proto"
message_type {
name: "Metrics"
field {
@@ -18,9 +17,6 @@ file {
label: LABEL_OPTIONAL
type: TYPE_MESSAGE
type_name: ".io.containerd.cgroups.v2.CPUStat"
- options {
- 65004: "CPU"
- }
json_name: "cpu"
}
field {
@@ -535,5 +531,8 @@ file {
json_name: "pagesize"
}
}
+ options {
+ go_package: "github.com/containerd/cgroups/cgroup2/stats"
+ }
syntax: "proto3"
}
diff --git a/vendor/github.com/containerd/cgroups/v2/stats/metrics.proto b/vendor/github.com/containerd/cgroups/v3/cgroup2/stats/metrics.proto
index 8ac472e46..3e9ee6d6a 100644
--- a/vendor/github.com/containerd/cgroups/v2/stats/metrics.proto
+++ b/vendor/github.com/containerd/cgroups/v3/cgroup2/stats/metrics.proto
@@ -2,11 +2,11 @@ syntax = "proto3";
package io.containerd.cgroups.v2;
- import "gogoproto/gogo.proto";
+option go_package = "github.com/containerd/cgroups/cgroup2/stats";
message Metrics {
PidsStat pids = 1;
- CPUStat cpu = 2 [(gogoproto.customname) = "CPU"];
+ CPUStat cpu = 2;
MemoryStat memory = 4;
RdmaStat rdma = 5;
IOStat io = 6;
diff --git a/vendor/github.com/containerd/cgroups/v2/utils.go b/vendor/github.com/containerd/cgroups/v3/cgroup2/utils.go
index 240c92677..776501830 100644
--- a/vendor/github.com/containerd/cgroups/v2/utils.go
+++ b/vendor/github.com/containerd/cgroups/v3/cgroup2/utils.go
@@ -14,29 +14,31 @@
limitations under the License.
*/
-package v2
+package cgroup2
import (
"bufio"
"fmt"
"io"
- "io/ioutil"
"math"
"os"
"path/filepath"
"strconv"
"strings"
"time"
+ "unsafe"
- "github.com/containerd/cgroups/v2/stats"
+ "github.com/containerd/cgroups/v3/cgroup2/stats"
"github.com/godbus/dbus/v5"
"github.com/opencontainers/runtime-spec/specs-go"
"github.com/sirupsen/logrus"
+ "golang.org/x/sys/unix"
)
const (
cgroupProcs = "cgroup.procs"
+ cgroupThreads = "cgroup.threads"
defaultDirPerm = 0755
)
@@ -242,7 +244,7 @@ func ToResources(spec *specs.LinuxResources) *Resources {
// Gets uint64 parsed content of single value cgroup stat file
func getStatFileContentUint64(filePath string) uint64 {
- contents, err := ioutil.ReadFile(filePath)
+ contents, err := os.ReadFile(filePath)
if err != nil {
return 0
}
@@ -264,7 +266,7 @@ func readIoStats(path string) []*stats.IOEntry {
// more details on the io.stat file format: https://www.kernel.org/doc/Documentation/cgroup-v2.txt
var usage []*stats.IOEntry
fpath := filepath.Join(path, "io.stat")
- currentData, err := ioutil.ReadFile(fpath)
+ currentData, err := os.ReadFile(fpath)
if err != nil {
return usage
}
@@ -318,7 +320,7 @@ func readIoStats(path string) []*stats.IOEntry {
}
func rdmaStats(filepath string) []*stats.RdmaEntry {
- currentData, err := ioutil.ReadFile(filepath)
+ currentData, err := os.ReadFile(filepath)
if err != nil {
return []*stats.RdmaEntry{}
}
@@ -406,7 +408,7 @@ func readHugeTlbStats(path string) []*stats.HugeTlbStat {
hugeTlb = &stats.HugeTlbStat{}
}
hugeTlb.Pagesize = pageSize
- out, err := ioutil.ReadFile(filepath.Join(path, file.Name()))
+ out, err := os.ReadFile(filepath.Join(path, file.Name()))
if err != nil {
continue
}
@@ -434,3 +436,11 @@ func readHugeTlbStats(path string) []*stats.HugeTlbStat {
}
return usage
}
+
+func getSubreaper() (int, error) {
+ var i uintptr
+ if err := unix.Prctl(unix.PR_GET_CHILD_SUBREAPER, uintptr(unsafe.Pointer(&i)), 0, 0, 0); err != nil {
+ return -1, err
+ }
+ return int(i), nil
+}
diff --git a/vendor/github.com/containerd/cgroups/v3/utils.go b/vendor/github.com/containerd/cgroups/v3/utils.go
new file mode 100644
index 000000000..ebff755a7
--- /dev/null
+++ b/vendor/github.com/containerd/cgroups/v3/utils.go
@@ -0,0 +1,150 @@
+/*
+ Copyright The containerd Authors.
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+*/
+
+package cgroups
+
+import (
+ "bufio"
+ "fmt"
+ "io"
+ "os"
+ "path/filepath"
+ "strings"
+ "sync"
+
+ "golang.org/x/sys/unix"
+)
+
+var (
+ nsOnce sync.Once
+ inUserNS bool
+ checkMode sync.Once
+ cgMode CGMode
+)
+
+const unifiedMountpoint = "/sys/fs/cgroup"
+
+// CGMode is the cgroups mode of the host system
+type CGMode int
+
+const (
+ // Unavailable cgroup mountpoint
+ Unavailable CGMode = iota
+ // Legacy cgroups v1
+ Legacy
+ // Hybrid with cgroups v1 and v2 controllers mounted
+ Hybrid
+ // Unified with only cgroups v2 mounted
+ Unified
+)
+
+// Mode returns the cgroups mode running on the host
+func Mode() CGMode {
+ checkMode.Do(func() {
+ var st unix.Statfs_t
+ if err := unix.Statfs(unifiedMountpoint, &st); err != nil {
+ cgMode = Unavailable
+ return
+ }
+ switch st.Type {
+ case unix.CGROUP2_SUPER_MAGIC:
+ cgMode = Unified
+ default:
+ cgMode = Legacy
+ if err := unix.Statfs(filepath.Join(unifiedMountpoint, "unified"), &st); err != nil {
+ return
+ }
+ if st.Type == unix.CGROUP2_SUPER_MAGIC {
+ cgMode = Hybrid
+ }
+ }
+ })
+ return cgMode
+}
+
+// RunningInUserNS detects whether we are currently running in a user namespace.
+// Copied from github.com/lxc/lxd/shared/util.go
+func RunningInUserNS() bool {
+ nsOnce.Do(func() {
+ file, err := os.Open("/proc/self/uid_map")
+ if err != nil {
+ // This kernel-provided file only exists if user namespaces are supported
+ return
+ }
+ defer file.Close()
+
+ buf := bufio.NewReader(file)
+ l, _, err := buf.ReadLine()
+ if err != nil {
+ return
+ }
+
+ line := string(l)
+ var a, b, c int64
+ fmt.Sscanf(line, "%d %d %d", &a, &b, &c)
+
+ /*
+ * We assume we are in the initial user namespace if we have a full
+ * range - 4294967295 uids starting at uid 0.
+ */
+ if a == 0 && b == 0 && c == 4294967295 {
+ return
+ }
+ inUserNS = true
+ })
+ return inUserNS
+}
+
+// ParseCgroupFileUnified returns legacy subsystem paths as the first value,
+// and returns the unified path as the second value.
+func ParseCgroupFileUnified(path string) (map[string]string, string, error) {
+ f, err := os.Open(path)
+ if err != nil {
+ return nil, "", err
+ }
+ defer f.Close()
+ return ParseCgroupFromReaderUnified(f)
+}
+
+// ParseCgroupFromReaderUnified returns legacy subsystem paths as the first value,
+// and returns the unified path as the second value.
+func ParseCgroupFromReaderUnified(r io.Reader) (map[string]string, string, error) {
+ var (
+ cgroups = make(map[string]string)
+ unified = ""
+ s = bufio.NewScanner(r)
+ )
+ for s.Scan() {
+ var (
+ text = s.Text()
+ parts = strings.SplitN(text, ":", 3)
+ )
+ if len(parts) < 3 {
+ return nil, unified, fmt.Errorf("invalid cgroup entry: %q", text)
+ }
+ for _, subs := range strings.Split(parts[1], ",") {
+ if subs == "" {
+ unified = parts[2]
+ } else {
+ cgroups[subs] = parts[2]
+ }
+ }
+ }
+ if err := s.Err(); err != nil {
+ return nil, unified, err
+ }
+ return cgroups, unified, nil
+}