github.com/aergoio/aergo@v1.3.1/types/metric.pb.go (about) 1 // Code generated by protoc-gen-go. DO NOT EDIT. 2 // source: metric.proto 3 4 package types 5 6 import proto "github.com/golang/protobuf/proto" 7 import fmt "fmt" 8 import math "math" 9 10 // Reference imports to suppress errors if they are not otherwise used. 11 var _ = proto.Marshal 12 var _ = fmt.Errorf 13 var _ = math.Inf 14 15 // This is a compile-time assertion to ensure that this generated file 16 // is compatible with the proto package it is being compiled against. 17 // A compilation error at this line likely means your copy of the 18 // proto package needs to be updated. 19 const _ = proto.ProtoPackageIsVersion2 // please upgrade the proto package 20 21 type MetricType int32 22 23 const ( 24 // NOTHING should not be used. 25 MetricType_NOTHING MetricType = 0 26 // Metric for p2p network transfer 27 MetricType_P2P_NETWORK MetricType = 1 28 ) 29 30 var MetricType_name = map[int32]string{ 31 0: "NOTHING", 32 1: "P2P_NETWORK", 33 } 34 35 var MetricType_value = map[string]int32{ 36 "NOTHING": 0, 37 "P2P_NETWORK": 1, 38 } 39 40 func (x MetricType) String() string { 41 return proto.EnumName(MetricType_name, int32(x)) 42 } 43 44 func (MetricType) EnumDescriptor() ([]byte, []int) { 45 return fileDescriptor_da41641f55bff5df, []int{0} 46 } 47 48 type MetricsRequest struct { 49 Types []MetricType `protobuf:"varint,1,rep,packed,name=types,proto3,enum=types.MetricType" json:"types,omitempty"` 50 XXX_NoUnkeyedLiteral struct{} `json:"-"` 51 XXX_unrecognized []byte `json:"-"` 52 XXX_sizecache int32 `json:"-"` 53 } 54 55 func (m *MetricsRequest) Reset() { *m = MetricsRequest{} } 56 func (m *MetricsRequest) String() string { return proto.CompactTextString(m) } 57 func (*MetricsRequest) ProtoMessage() {} 58 func (*MetricsRequest) Descriptor() ([]byte, []int) { 59 return fileDescriptor_da41641f55bff5df, []int{0} 60 } 61 func (m *MetricsRequest) XXX_Unmarshal(b []byte) error { 62 return xxx_messageInfo_MetricsRequest.Unmarshal(m, b) 63 } 64 func (m *MetricsRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { 65 return xxx_messageInfo_MetricsRequest.Marshal(b, m, deterministic) 66 } 67 func (m *MetricsRequest) XXX_Merge(src proto.Message) { 68 xxx_messageInfo_MetricsRequest.Merge(m, src) 69 } 70 func (m *MetricsRequest) XXX_Size() int { 71 return xxx_messageInfo_MetricsRequest.Size(m) 72 } 73 func (m *MetricsRequest) XXX_DiscardUnknown() { 74 xxx_messageInfo_MetricsRequest.DiscardUnknown(m) 75 } 76 77 var xxx_messageInfo_MetricsRequest proto.InternalMessageInfo 78 79 func (m *MetricsRequest) GetTypes() []MetricType { 80 if m != nil { 81 return m.Types 82 } 83 return nil 84 } 85 86 type Metrics struct { 87 Peers []*PeerMetric `protobuf:"bytes,1,rep,name=peers,proto3" json:"peers,omitempty"` 88 XXX_NoUnkeyedLiteral struct{} `json:"-"` 89 XXX_unrecognized []byte `json:"-"` 90 XXX_sizecache int32 `json:"-"` 91 } 92 93 func (m *Metrics) Reset() { *m = Metrics{} } 94 func (m *Metrics) String() string { return proto.CompactTextString(m) } 95 func (*Metrics) ProtoMessage() {} 96 func (*Metrics) Descriptor() ([]byte, []int) { 97 return fileDescriptor_da41641f55bff5df, []int{1} 98 } 99 func (m *Metrics) XXX_Unmarshal(b []byte) error { 100 return xxx_messageInfo_Metrics.Unmarshal(m, b) 101 } 102 func (m *Metrics) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { 103 return xxx_messageInfo_Metrics.Marshal(b, m, deterministic) 104 } 105 func (m *Metrics) XXX_Merge(src proto.Message) { 106 xxx_messageInfo_Metrics.Merge(m, src) 107 } 108 func (m *Metrics) XXX_Size() int { 109 return xxx_messageInfo_Metrics.Size(m) 110 } 111 func (m *Metrics) XXX_DiscardUnknown() { 112 xxx_messageInfo_Metrics.DiscardUnknown(m) 113 } 114 115 var xxx_messageInfo_Metrics proto.InternalMessageInfo 116 117 func (m *Metrics) GetPeers() []*PeerMetric { 118 if m != nil { 119 return m.Peers 120 } 121 return nil 122 } 123 124 type PeerMetric struct { 125 PeerID []byte `protobuf:"bytes,1,opt,name=peerID,proto3" json:"peerID,omitempty"` 126 SumIn int64 `protobuf:"varint,2,opt,name=sumIn,proto3" json:"sumIn,omitempty"` 127 AvrIn int64 `protobuf:"varint,3,opt,name=avrIn,proto3" json:"avrIn,omitempty"` 128 SumOut int64 `protobuf:"varint,4,opt,name=sumOut,proto3" json:"sumOut,omitempty"` 129 AvrOut int64 `protobuf:"varint,5,opt,name=avrOut,proto3" json:"avrOut,omitempty"` 130 XXX_NoUnkeyedLiteral struct{} `json:"-"` 131 XXX_unrecognized []byte `json:"-"` 132 XXX_sizecache int32 `json:"-"` 133 } 134 135 func (m *PeerMetric) Reset() { *m = PeerMetric{} } 136 func (m *PeerMetric) String() string { return proto.CompactTextString(m) } 137 func (*PeerMetric) ProtoMessage() {} 138 func (*PeerMetric) Descriptor() ([]byte, []int) { 139 return fileDescriptor_da41641f55bff5df, []int{2} 140 } 141 func (m *PeerMetric) XXX_Unmarshal(b []byte) error { 142 return xxx_messageInfo_PeerMetric.Unmarshal(m, b) 143 } 144 func (m *PeerMetric) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { 145 return xxx_messageInfo_PeerMetric.Marshal(b, m, deterministic) 146 } 147 func (m *PeerMetric) XXX_Merge(src proto.Message) { 148 xxx_messageInfo_PeerMetric.Merge(m, src) 149 } 150 func (m *PeerMetric) XXX_Size() int { 151 return xxx_messageInfo_PeerMetric.Size(m) 152 } 153 func (m *PeerMetric) XXX_DiscardUnknown() { 154 xxx_messageInfo_PeerMetric.DiscardUnknown(m) 155 } 156 157 var xxx_messageInfo_PeerMetric proto.InternalMessageInfo 158 159 func (m *PeerMetric) GetPeerID() []byte { 160 if m != nil { 161 return m.PeerID 162 } 163 return nil 164 } 165 166 func (m *PeerMetric) GetSumIn() int64 { 167 if m != nil { 168 return m.SumIn 169 } 170 return 0 171 } 172 173 func (m *PeerMetric) GetAvrIn() int64 { 174 if m != nil { 175 return m.AvrIn 176 } 177 return 0 178 } 179 180 func (m *PeerMetric) GetSumOut() int64 { 181 if m != nil { 182 return m.SumOut 183 } 184 return 0 185 } 186 187 func (m *PeerMetric) GetAvrOut() int64 { 188 if m != nil { 189 return m.AvrOut 190 } 191 return 0 192 } 193 194 func init() { 195 proto.RegisterType((*MetricsRequest)(nil), "types.MetricsRequest") 196 proto.RegisterType((*Metrics)(nil), "types.Metrics") 197 proto.RegisterType((*PeerMetric)(nil), "types.PeerMetric") 198 proto.RegisterEnum("types.MetricType", MetricType_name, MetricType_value) 199 } 200 201 func init() { proto.RegisterFile("metric.proto", fileDescriptor_da41641f55bff5df) } 202 203 var fileDescriptor_da41641f55bff5df = []byte{ 204 // 226 bytes of a gzipped FileDescriptorProto 205 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x44, 0x90, 0xcf, 0x4b, 0xc3, 0x30, 206 0x14, 0x80, 0x8d, 0xb5, 0x1b, 0xbc, 0x8e, 0x39, 0x83, 0x48, 0x8e, 0x65, 0x17, 0xcb, 0x0e, 0x3d, 207 0xd4, 0x93, 0x77, 0x45, 0x83, 0xd8, 0x96, 0x50, 0xf0, 0x28, 0x53, 0xde, 0xc1, 0x43, 0xb7, 0x98, 208 0x1f, 0x83, 0xde, 0xfc, 0xd3, 0x25, 0x79, 0x61, 0x3d, 0x7e, 0xdf, 0x7b, 0x5f, 0x20, 0x0f, 0x56, 209 0x23, 0x3a, 0xf3, 0xf3, 0x5d, 0x6b, 0x73, 0x74, 0x47, 0x9e, 0xbb, 0x49, 0xa3, 0xdd, 0x3e, 0xc2, 210 0xfa, 0x3d, 0x6a, 0xab, 0xf0, 0xd7, 0xa3, 0x75, 0xfc, 0x1e, 0x68, 0x24, 0x58, 0x99, 0x55, 0xeb, 211 0xe6, 0xa6, 0x8e, 0x54, 0xd3, 0xd6, 0x30, 0x69, 0x54, 0x29, 0x6d, 0x60, 0x99, 0xd2, 0xd0, 0x68, 212 0x44, 0x43, 0x4d, 0x71, 0x6e, 0x7a, 0x44, 0x43, 0x2b, 0x8a, 0xe6, 0xdb, 0x3f, 0x06, 0x30, 0x5b, 213 0x7e, 0x07, 0x8b, 0xe0, 0xe5, 0x93, 0x60, 0x25, 0xab, 0x56, 0x2a, 0x11, 0xbf, 0x85, 0xdc, 0xfa, 214 0x51, 0x1e, 0xc4, 0x65, 0xc9, 0xaa, 0x4c, 0x11, 0x04, 0xbb, 0x3f, 0x19, 0x79, 0x10, 0x19, 0xd9, 215 0x08, 0xe1, 0x0d, 0xeb, 0xc7, 0xce, 0x3b, 0x71, 0x15, 0x75, 0xa2, 0xe0, 0xf7, 0x27, 0x13, 0x7c, 216 0x4e, 0x9e, 0x68, 0xb7, 0x03, 0x98, 0xff, 0xc2, 0x0b, 0x58, 0xb6, 0xdd, 0xf0, 0x2a, 0xdb, 0x97, 217 0xcd, 0x05, 0xbf, 0x86, 0xa2, 0x6f, 0xfa, 0xcf, 0xf6, 0x79, 0xf8, 0xe8, 0xd4, 0xdb, 0x86, 0x7d, 218 0x2d, 0xe2, 0xad, 0x1e, 0xfe, 0x03, 0x00, 0x00, 0xff, 0xff, 0xf8, 0x5e, 0x48, 0xee, 0x3b, 0x01, 219 0x00, 0x00, 220 }