1// Code generated by protoc-gen-gogo. DO NOT EDIT. 2// source: mixer/adapter/model/v1beta1/quota.proto 3 4package v1beta1 5 6import ( 7 fmt "fmt" 8 _ "github.com/gogo/protobuf/gogoproto" 9 proto "github.com/gogo/protobuf/proto" 10 github_com_gogo_protobuf_sortkeys "github.com/gogo/protobuf/sortkeys" 11 _ "github.com/gogo/protobuf/types" 12 github_com_gogo_protobuf_types "github.com/gogo/protobuf/types" 13 io "io" 14 rpc "istio.io/gogo-genproto/googleapis/google/rpc" 15 math "math" 16 math_bits "math/bits" 17 reflect "reflect" 18 strings "strings" 19 time "time" 20) 21 22// Reference imports to suppress errors if they are not otherwise used. 23var _ = proto.Marshal 24var _ = fmt.Errorf 25var _ = math.Inf 26var _ = time.Kitchen 27 28// This is a compile-time assertion to ensure that this generated file 29// is compatible with the proto package it is being compiled against. 30// A compilation error at this line likely means your copy of the 31// proto package needs to be updated. 32const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package 33 34// Expresses the quota allocation request. 35type QuotaRequest struct { 36 // The individual quotas to allocate 37 Quotas map[string]QuotaRequest_QuotaParams `protobuf:"bytes,1,rep,name=quotas,proto3" json:"quotas" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"` 38} 39 40func (m *QuotaRequest) Reset() { *m = QuotaRequest{} } 41func (*QuotaRequest) ProtoMessage() {} 42func (*QuotaRequest) Descriptor() ([]byte, []int) { 43 return fileDescriptor_f07acf62b4429357, []int{0} 44} 45func (m *QuotaRequest) XXX_Unmarshal(b []byte) error { 46 return m.Unmarshal(b) 47} 48func (m *QuotaRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { 49 if deterministic { 50 return xxx_messageInfo_QuotaRequest.Marshal(b, m, deterministic) 51 } else { 52 b = b[:cap(b)] 53 n, err := m.MarshalToSizedBuffer(b) 54 if err != nil { 55 return nil, err 56 } 57 return b[:n], nil 58 } 59} 60func (m *QuotaRequest) XXX_Merge(src proto.Message) { 61 xxx_messageInfo_QuotaRequest.Merge(m, src) 62} 63func (m *QuotaRequest) XXX_Size() int { 64 return m.Size() 65} 66func (m *QuotaRequest) XXX_DiscardUnknown() { 67 xxx_messageInfo_QuotaRequest.DiscardUnknown(m) 68} 69 70var xxx_messageInfo_QuotaRequest proto.InternalMessageInfo 71 72// parameters for a quota allocation 73type QuotaRequest_QuotaParams struct { 74 // Amount of quota to allocate 75 Amount int64 `protobuf:"varint,1,opt,name=amount,proto3" json:"amount,omitempty"` 76 // When true, supports returning less quota than what was requested. 77 BestEffort bool `protobuf:"varint,2,opt,name=best_effort,json=bestEffort,proto3" json:"best_effort,omitempty"` 78} 79 80func (m *QuotaRequest_QuotaParams) Reset() { *m = QuotaRequest_QuotaParams{} } 81func (*QuotaRequest_QuotaParams) ProtoMessage() {} 82func (*QuotaRequest_QuotaParams) Descriptor() ([]byte, []int) { 83 return fileDescriptor_f07acf62b4429357, []int{0, 0} 84} 85func (m *QuotaRequest_QuotaParams) XXX_Unmarshal(b []byte) error { 86 return m.Unmarshal(b) 87} 88func (m *QuotaRequest_QuotaParams) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { 89 if deterministic { 90 return xxx_messageInfo_QuotaRequest_QuotaParams.Marshal(b, m, deterministic) 91 } else { 92 b = b[:cap(b)] 93 n, err := m.MarshalToSizedBuffer(b) 94 if err != nil { 95 return nil, err 96 } 97 return b[:n], nil 98 } 99} 100func (m *QuotaRequest_QuotaParams) XXX_Merge(src proto.Message) { 101 xxx_messageInfo_QuotaRequest_QuotaParams.Merge(m, src) 102} 103func (m *QuotaRequest_QuotaParams) XXX_Size() int { 104 return m.Size() 105} 106func (m *QuotaRequest_QuotaParams) XXX_DiscardUnknown() { 107 xxx_messageInfo_QuotaRequest_QuotaParams.DiscardUnknown(m) 108} 109 110var xxx_messageInfo_QuotaRequest_QuotaParams proto.InternalMessageInfo 111 112// Expresses the result of multiple quota allocations. 113type QuotaResult struct { 114 // The resulting quota, one entry per requested quota. 115 Quotas map[string]QuotaResult_Result `protobuf:"bytes,1,rep,name=quotas,proto3" json:"quotas" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"` 116} 117 118func (m *QuotaResult) Reset() { *m = QuotaResult{} } 119func (*QuotaResult) ProtoMessage() {} 120func (*QuotaResult) Descriptor() ([]byte, []int) { 121 return fileDescriptor_f07acf62b4429357, []int{1} 122} 123func (m *QuotaResult) XXX_Unmarshal(b []byte) error { 124 return m.Unmarshal(b) 125} 126func (m *QuotaResult) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { 127 if deterministic { 128 return xxx_messageInfo_QuotaResult.Marshal(b, m, deterministic) 129 } else { 130 b = b[:cap(b)] 131 n, err := m.MarshalToSizedBuffer(b) 132 if err != nil { 133 return nil, err 134 } 135 return b[:n], nil 136 } 137} 138func (m *QuotaResult) XXX_Merge(src proto.Message) { 139 xxx_messageInfo_QuotaResult.Merge(m, src) 140} 141func (m *QuotaResult) XXX_Size() int { 142 return m.Size() 143} 144func (m *QuotaResult) XXX_DiscardUnknown() { 145 xxx_messageInfo_QuotaResult.DiscardUnknown(m) 146} 147 148var xxx_messageInfo_QuotaResult proto.InternalMessageInfo 149 150// Expresses the result of a quota allocation. 151type QuotaResult_Result struct { 152 // The amount of time for which this result can be considered valid. 153 ValidDuration time.Duration `protobuf:"bytes,2,opt,name=valid_duration,json=validDuration,proto3,stdduration" json:"valid_duration"` 154 // The amount of granted quota. When `QuotaParams.best_effort` is true, this will be >= 0. 155 // If `QuotaParams.best_effort` is false, this will be either 0 or >= `QuotaParams.amount`. 156 GrantedAmount int64 `protobuf:"varint,3,opt,name=granted_amount,json=grantedAmount,proto3" json:"granted_amount,omitempty"` 157 // A status code of OK indicates quota was fetched successfully. Any other code indicates error in fetching quota. 158 Status rpc.Status `protobuf:"bytes,4,opt,name=status,proto3" json:"status"` 159} 160 161func (m *QuotaResult_Result) Reset() { *m = QuotaResult_Result{} } 162func (*QuotaResult_Result) ProtoMessage() {} 163func (*QuotaResult_Result) Descriptor() ([]byte, []int) { 164 return fileDescriptor_f07acf62b4429357, []int{1, 0} 165} 166func (m *QuotaResult_Result) XXX_Unmarshal(b []byte) error { 167 return m.Unmarshal(b) 168} 169func (m *QuotaResult_Result) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { 170 if deterministic { 171 return xxx_messageInfo_QuotaResult_Result.Marshal(b, m, deterministic) 172 } else { 173 b = b[:cap(b)] 174 n, err := m.MarshalToSizedBuffer(b) 175 if err != nil { 176 return nil, err 177 } 178 return b[:n], nil 179 } 180} 181func (m *QuotaResult_Result) XXX_Merge(src proto.Message) { 182 xxx_messageInfo_QuotaResult_Result.Merge(m, src) 183} 184func (m *QuotaResult_Result) XXX_Size() int { 185 return m.Size() 186} 187func (m *QuotaResult_Result) XXX_DiscardUnknown() { 188 xxx_messageInfo_QuotaResult_Result.DiscardUnknown(m) 189} 190 191var xxx_messageInfo_QuotaResult_Result proto.InternalMessageInfo 192 193func init() { 194 proto.RegisterType((*QuotaRequest)(nil), "istio.mixer.adapter.model.v1beta1.QuotaRequest") 195 proto.RegisterMapType((map[string]QuotaRequest_QuotaParams)(nil), "istio.mixer.adapter.model.v1beta1.QuotaRequest.QuotasEntry") 196 proto.RegisterType((*QuotaRequest_QuotaParams)(nil), "istio.mixer.adapter.model.v1beta1.QuotaRequest.QuotaParams") 197 proto.RegisterType((*QuotaResult)(nil), "istio.mixer.adapter.model.v1beta1.QuotaResult") 198 proto.RegisterMapType((map[string]QuotaResult_Result)(nil), "istio.mixer.adapter.model.v1beta1.QuotaResult.QuotasEntry") 199 proto.RegisterType((*QuotaResult_Result)(nil), "istio.mixer.adapter.model.v1beta1.QuotaResult.Result") 200} 201 202func init() { 203 proto.RegisterFile("mixer/adapter/model/v1beta1/quota.proto", fileDescriptor_f07acf62b4429357) 204} 205 206var fileDescriptor_f07acf62b4429357 = []byte{ 207 // 485 bytes of a gzipped FileDescriptorProto 208 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x9c, 0x53, 0x31, 0x6f, 0x13, 0x31, 209 0x18, 0xb5, 0x73, 0xe5, 0x54, 0x1c, 0x5a, 0x21, 0x0b, 0x41, 0xb8, 0xc1, 0x09, 0x95, 0x10, 0x99, 210 0x6c, 0x0a, 0x42, 0x42, 0x65, 0x22, 0xa2, 0x0c, 0xb0, 0xd0, 0x63, 0x01, 0x96, 0xc8, 0xd7, 0x73, 211 0x4e, 0x27, 0x2e, 0xf1, 0xd5, 0xf6, 0x45, 0x74, 0x63, 0x65, 0x63, 0xe4, 0x27, 0xc0, 0xc0, 0xff, 212 0xc8, 0x98, 0xb1, 0x13, 0x90, 0xcb, 0xc2, 0xd8, 0x9f, 0x80, 0xce, 0xf6, 0x49, 0x85, 0xa1, 0x05, 213 0xa6, 0xd8, 0xdf, 0xf7, 0xbe, 0xf7, 0x3e, 0xbf, 0x97, 0x43, 0x77, 0xa6, 0xf9, 0x3b, 0xa1, 0x18, 214 0x4f, 0x79, 0x69, 0x84, 0x62, 0x53, 0x99, 0x8a, 0x82, 0xcd, 0x77, 0x13, 0x61, 0xf8, 0x2e, 0x3b, 215 0xaa, 0xa4, 0xe1, 0xb4, 0x54, 0xd2, 0x48, 0x7c, 0x2b, 0xd7, 0x26, 0x97, 0xd4, 0xc2, 0xa9, 0x87, 216 0x53, 0x0b, 0xa7, 0x1e, 0x1e, 0x5d, 0xcb, 0x64, 0x26, 0x2d, 0x9a, 0x35, 0x27, 0x37, 0x18, 0x91, 217 0x4c, 0xca, 0xac, 0x10, 0xcc, 0xde, 0x92, 0x6a, 0xc2, 0xd2, 0x4a, 0x71, 0x93, 0xcb, 0x99, 0xef, 218 0xdf, 0xf0, 0x7d, 0x55, 0x1e, 0x32, 0x6d, 0xb8, 0xa9, 0xb4, 0x6b, 0xec, 0x7c, 0xe9, 0xa0, 0x2b, 219 0x07, 0xcd, 0x06, 0xb1, 0x38, 0xaa, 0x84, 0x36, 0xf8, 0x35, 0x0a, 0xed, 0x46, 0xba, 0x07, 0x07, 220 0xc1, 0xb0, 0x7b, 0xef, 0x11, 0xbd, 0x70, 0x27, 0x7a, 0x96, 0xc0, 0x5d, 0xf4, 0xfe, 0xcc, 0xa8, 221 0xe3, 0xd1, 0xc6, 0xe2, 0x5b, 0x1f, 0xc4, 0x9e, 0x30, 0x7a, 0x8a, 0xba, 0xb6, 0xf9, 0x82, 0x2b, 222 0x3e, 0xd5, 0xf8, 0x3a, 0x0a, 0xf9, 0x54, 0x56, 0x33, 0xd3, 0x83, 0x03, 0x38, 0x0c, 0x62, 0x7f, 223 0xc3, 0x7d, 0xd4, 0x4d, 0x84, 0x36, 0x63, 0x31, 0x99, 0x48, 0x65, 0x7a, 0x9d, 0x01, 0x1c, 0x6e, 224 0xc6, 0xa8, 0x29, 0xed, 0xdb, 0x4a, 0x34, 0xf7, 0x3c, 0x4e, 0x04, 0x5f, 0x45, 0xc1, 0x5b, 0x71, 225 0x6c, 0x49, 0x2e, 0xc7, 0xcd, 0x11, 0x1f, 0xa0, 0x4b, 0x73, 0x5e, 0x54, 0xc2, 0xce, 0xfe, 0xef, 226 0x13, 0xdc, 0x96, 0xb1, 0x63, 0xda, 0xeb, 0x3c, 0x84, 0x3b, 0x1f, 0x02, 0x2f, 0x1c, 0x0b, 0x5d, 227 0x15, 0x06, 0xbf, 0xfa, 0xc3, 0xaa, 0xbd, 0xbf, 0xd7, 0x69, 0xe6, 0xcf, 0x71, 0xea, 0x2b, 0x44, 228 0xa1, 0x17, 0x79, 0x86, 0xb6, 0xe7, 0xbc, 0xc8, 0xd3, 0x71, 0x9b, 0xa8, 0x7f, 0xd4, 0x4d, 0xea, 229 0x22, 0xa5, 0x6d, 0xe4, 0xf4, 0x89, 0x07, 0x8c, 0x36, 0x1b, 0xae, 0x4f, 0xdf, 0xfb, 0x30, 0xde, 230 0xb2, 0xa3, 0x6d, 0x03, 0xdf, 0x46, 0xdb, 0x99, 0xe2, 0x33, 0x23, 0xd2, 0xb1, 0x77, 0x3e, 0xb0, 231 0xce, 0x6f, 0xf9, 0xea, 0x63, 0x17, 0xc0, 0x5d, 0x14, 0xba, 0xff, 0x48, 0x6f, 0xc3, 0x4a, 0xe1, 232 0x56, 0x4a, 0x95, 0x87, 0xf4, 0xa5, 0xed, 0xb4, 0xfb, 0x3a, 0x5c, 0x54, 0x5e, 0x94, 0xc8, 0xf3, 233 0xdf, 0x13, 0x79, 0xf0, 0x8f, 0x4e, 0xb9, 0x9f, 0x33, 0x59, 0x8c, 0x92, 0xc5, 0x8a, 0x80, 0xe5, 234 0x8a, 0x80, 0x93, 0x15, 0x01, 0xa7, 0x2b, 0x02, 0xde, 0xd7, 0x04, 0x7e, 0xae, 0x09, 0x58, 0xd4, 235 0x04, 0x2e, 0x6b, 0x02, 0x7f, 0xd4, 0x04, 0xfe, 0xac, 0x09, 0x38, 0xad, 0x09, 0xfc, 0xb8, 0x26, 236 0x60, 0xb9, 0x26, 0xe0, 0x64, 0x4d, 0xc0, 0x9b, 0xa1, 0x93, 0xce, 0x25, 0xe3, 0x65, 0xce, 0xce, 237 0xf9, 0x32, 0x93, 0xd0, 0x5a, 0x7b, 0xff, 0x57, 0x00, 0x00, 0x00, 0xff, 0xff, 0x6c, 0xcd, 0xf9, 238 0x75, 0xbf, 0x03, 0x00, 0x00, 239} 240 241func (m *QuotaRequest) Marshal() (dAtA []byte, err error) { 242 size := m.Size() 243 dAtA = make([]byte, size) 244 n, err := m.MarshalToSizedBuffer(dAtA[:size]) 245 if err != nil { 246 return nil, err 247 } 248 return dAtA[:n], nil 249} 250 251func (m *QuotaRequest) MarshalTo(dAtA []byte) (int, error) { 252 size := m.Size() 253 return m.MarshalToSizedBuffer(dAtA[:size]) 254} 255 256func (m *QuotaRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { 257 i := len(dAtA) 258 _ = i 259 var l int 260 _ = l 261 if len(m.Quotas) > 0 { 262 for k := range m.Quotas { 263 v := m.Quotas[k] 264 baseI := i 265 { 266 size, err := (&v).MarshalToSizedBuffer(dAtA[:i]) 267 if err != nil { 268 return 0, err 269 } 270 i -= size 271 i = encodeVarintQuota(dAtA, i, uint64(size)) 272 } 273 i-- 274 dAtA[i] = 0x12 275 i -= len(k) 276 copy(dAtA[i:], k) 277 i = encodeVarintQuota(dAtA, i, uint64(len(k))) 278 i-- 279 dAtA[i] = 0xa 280 i = encodeVarintQuota(dAtA, i, uint64(baseI-i)) 281 i-- 282 dAtA[i] = 0xa 283 } 284 } 285 return len(dAtA) - i, nil 286} 287 288func (m *QuotaRequest_QuotaParams) Marshal() (dAtA []byte, err error) { 289 size := m.Size() 290 dAtA = make([]byte, size) 291 n, err := m.MarshalToSizedBuffer(dAtA[:size]) 292 if err != nil { 293 return nil, err 294 } 295 return dAtA[:n], nil 296} 297 298func (m *QuotaRequest_QuotaParams) MarshalTo(dAtA []byte) (int, error) { 299 size := m.Size() 300 return m.MarshalToSizedBuffer(dAtA[:size]) 301} 302 303func (m *QuotaRequest_QuotaParams) MarshalToSizedBuffer(dAtA []byte) (int, error) { 304 i := len(dAtA) 305 _ = i 306 var l int 307 _ = l 308 if m.BestEffort { 309 i-- 310 if m.BestEffort { 311 dAtA[i] = 1 312 } else { 313 dAtA[i] = 0 314 } 315 i-- 316 dAtA[i] = 0x10 317 } 318 if m.Amount != 0 { 319 i = encodeVarintQuota(dAtA, i, uint64(m.Amount)) 320 i-- 321 dAtA[i] = 0x8 322 } 323 return len(dAtA) - i, nil 324} 325 326func (m *QuotaResult) Marshal() (dAtA []byte, err error) { 327 size := m.Size() 328 dAtA = make([]byte, size) 329 n, err := m.MarshalToSizedBuffer(dAtA[:size]) 330 if err != nil { 331 return nil, err 332 } 333 return dAtA[:n], nil 334} 335 336func (m *QuotaResult) MarshalTo(dAtA []byte) (int, error) { 337 size := m.Size() 338 return m.MarshalToSizedBuffer(dAtA[:size]) 339} 340 341func (m *QuotaResult) MarshalToSizedBuffer(dAtA []byte) (int, error) { 342 i := len(dAtA) 343 _ = i 344 var l int 345 _ = l 346 if len(m.Quotas) > 0 { 347 for k := range m.Quotas { 348 v := m.Quotas[k] 349 baseI := i 350 { 351 size, err := (&v).MarshalToSizedBuffer(dAtA[:i]) 352 if err != nil { 353 return 0, err 354 } 355 i -= size 356 i = encodeVarintQuota(dAtA, i, uint64(size)) 357 } 358 i-- 359 dAtA[i] = 0x12 360 i -= len(k) 361 copy(dAtA[i:], k) 362 i = encodeVarintQuota(dAtA, i, uint64(len(k))) 363 i-- 364 dAtA[i] = 0xa 365 i = encodeVarintQuota(dAtA, i, uint64(baseI-i)) 366 i-- 367 dAtA[i] = 0xa 368 } 369 } 370 return len(dAtA) - i, nil 371} 372 373func (m *QuotaResult_Result) Marshal() (dAtA []byte, err error) { 374 size := m.Size() 375 dAtA = make([]byte, size) 376 n, err := m.MarshalToSizedBuffer(dAtA[:size]) 377 if err != nil { 378 return nil, err 379 } 380 return dAtA[:n], nil 381} 382 383func (m *QuotaResult_Result) MarshalTo(dAtA []byte) (int, error) { 384 size := m.Size() 385 return m.MarshalToSizedBuffer(dAtA[:size]) 386} 387 388func (m *QuotaResult_Result) MarshalToSizedBuffer(dAtA []byte) (int, error) { 389 i := len(dAtA) 390 _ = i 391 var l int 392 _ = l 393 { 394 size, err := m.Status.MarshalToSizedBuffer(dAtA[:i]) 395 if err != nil { 396 return 0, err 397 } 398 i -= size 399 i = encodeVarintQuota(dAtA, i, uint64(size)) 400 } 401 i-- 402 dAtA[i] = 0x22 403 if m.GrantedAmount != 0 { 404 i = encodeVarintQuota(dAtA, i, uint64(m.GrantedAmount)) 405 i-- 406 dAtA[i] = 0x18 407 } 408 n4, err4 := github_com_gogo_protobuf_types.StdDurationMarshalTo(m.ValidDuration, dAtA[i-github_com_gogo_protobuf_types.SizeOfStdDuration(m.ValidDuration):]) 409 if err4 != nil { 410 return 0, err4 411 } 412 i -= n4 413 i = encodeVarintQuota(dAtA, i, uint64(n4)) 414 i-- 415 dAtA[i] = 0x12 416 return len(dAtA) - i, nil 417} 418 419func encodeVarintQuota(dAtA []byte, offset int, v uint64) int { 420 offset -= sovQuota(v) 421 base := offset 422 for v >= 1<<7 { 423 dAtA[offset] = uint8(v&0x7f | 0x80) 424 v >>= 7 425 offset++ 426 } 427 dAtA[offset] = uint8(v) 428 return base 429} 430func (m *QuotaRequest) Size() (n int) { 431 if m == nil { 432 return 0 433 } 434 var l int 435 _ = l 436 if len(m.Quotas) > 0 { 437 for k, v := range m.Quotas { 438 _ = k 439 _ = v 440 l = v.Size() 441 mapEntrySize := 1 + len(k) + sovQuota(uint64(len(k))) + 1 + l + sovQuota(uint64(l)) 442 n += mapEntrySize + 1 + sovQuota(uint64(mapEntrySize)) 443 } 444 } 445 return n 446} 447 448func (m *QuotaRequest_QuotaParams) Size() (n int) { 449 if m == nil { 450 return 0 451 } 452 var l int 453 _ = l 454 if m.Amount != 0 { 455 n += 1 + sovQuota(uint64(m.Amount)) 456 } 457 if m.BestEffort { 458 n += 2 459 } 460 return n 461} 462 463func (m *QuotaResult) Size() (n int) { 464 if m == nil { 465 return 0 466 } 467 var l int 468 _ = l 469 if len(m.Quotas) > 0 { 470 for k, v := range m.Quotas { 471 _ = k 472 _ = v 473 l = v.Size() 474 mapEntrySize := 1 + len(k) + sovQuota(uint64(len(k))) + 1 + l + sovQuota(uint64(l)) 475 n += mapEntrySize + 1 + sovQuota(uint64(mapEntrySize)) 476 } 477 } 478 return n 479} 480 481func (m *QuotaResult_Result) Size() (n int) { 482 if m == nil { 483 return 0 484 } 485 var l int 486 _ = l 487 l = github_com_gogo_protobuf_types.SizeOfStdDuration(m.ValidDuration) 488 n += 1 + l + sovQuota(uint64(l)) 489 if m.GrantedAmount != 0 { 490 n += 1 + sovQuota(uint64(m.GrantedAmount)) 491 } 492 l = m.Status.Size() 493 n += 1 + l + sovQuota(uint64(l)) 494 return n 495} 496 497func sovQuota(x uint64) (n int) { 498 return (math_bits.Len64(x|1) + 6) / 7 499} 500func sozQuota(x uint64) (n int) { 501 return sovQuota(uint64((x << 1) ^ uint64((int64(x) >> 63)))) 502} 503func (this *QuotaRequest) String() string { 504 if this == nil { 505 return "nil" 506 } 507 keysForQuotas := make([]string, 0, len(this.Quotas)) 508 for k, _ := range this.Quotas { 509 keysForQuotas = append(keysForQuotas, k) 510 } 511 github_com_gogo_protobuf_sortkeys.Strings(keysForQuotas) 512 mapStringForQuotas := "map[string]QuotaRequest_QuotaParams{" 513 for _, k := range keysForQuotas { 514 mapStringForQuotas += fmt.Sprintf("%v: %v,", k, this.Quotas[k]) 515 } 516 mapStringForQuotas += "}" 517 s := strings.Join([]string{`&QuotaRequest{`, 518 `Quotas:` + mapStringForQuotas + `,`, 519 `}`, 520 }, "") 521 return s 522} 523func (this *QuotaRequest_QuotaParams) String() string { 524 if this == nil { 525 return "nil" 526 } 527 s := strings.Join([]string{`&QuotaRequest_QuotaParams{`, 528 `Amount:` + fmt.Sprintf("%v", this.Amount) + `,`, 529 `BestEffort:` + fmt.Sprintf("%v", this.BestEffort) + `,`, 530 `}`, 531 }, "") 532 return s 533} 534func (this *QuotaResult) String() string { 535 if this == nil { 536 return "nil" 537 } 538 keysForQuotas := make([]string, 0, len(this.Quotas)) 539 for k, _ := range this.Quotas { 540 keysForQuotas = append(keysForQuotas, k) 541 } 542 github_com_gogo_protobuf_sortkeys.Strings(keysForQuotas) 543 mapStringForQuotas := "map[string]QuotaResult_Result{" 544 for _, k := range keysForQuotas { 545 mapStringForQuotas += fmt.Sprintf("%v: %v,", k, this.Quotas[k]) 546 } 547 mapStringForQuotas += "}" 548 s := strings.Join([]string{`&QuotaResult{`, 549 `Quotas:` + mapStringForQuotas + `,`, 550 `}`, 551 }, "") 552 return s 553} 554func (this *QuotaResult_Result) String() string { 555 if this == nil { 556 return "nil" 557 } 558 s := strings.Join([]string{`&QuotaResult_Result{`, 559 `ValidDuration:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ValidDuration), "Duration", "types.Duration", 1), `&`, ``, 1) + `,`, 560 `GrantedAmount:` + fmt.Sprintf("%v", this.GrantedAmount) + `,`, 561 `Status:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Status), "Status", "rpc.Status", 1), `&`, ``, 1) + `,`, 562 `}`, 563 }, "") 564 return s 565} 566func valueToStringQuota(v interface{}) string { 567 rv := reflect.ValueOf(v) 568 if rv.IsNil() { 569 return "nil" 570 } 571 pv := reflect.Indirect(rv).Interface() 572 return fmt.Sprintf("*%v", pv) 573} 574func (m *QuotaRequest) Unmarshal(dAtA []byte) error { 575 l := len(dAtA) 576 iNdEx := 0 577 for iNdEx < l { 578 preIndex := iNdEx 579 var wire uint64 580 for shift := uint(0); ; shift += 7 { 581 if shift >= 64 { 582 return ErrIntOverflowQuota 583 } 584 if iNdEx >= l { 585 return io.ErrUnexpectedEOF 586 } 587 b := dAtA[iNdEx] 588 iNdEx++ 589 wire |= uint64(b&0x7F) << shift 590 if b < 0x80 { 591 break 592 } 593 } 594 fieldNum := int32(wire >> 3) 595 wireType := int(wire & 0x7) 596 if wireType == 4 { 597 return fmt.Errorf("proto: QuotaRequest: wiretype end group for non-group") 598 } 599 if fieldNum <= 0 { 600 return fmt.Errorf("proto: QuotaRequest: illegal tag %d (wire type %d)", fieldNum, wire) 601 } 602 switch fieldNum { 603 case 1: 604 if wireType != 2 { 605 return fmt.Errorf("proto: wrong wireType = %d for field Quotas", wireType) 606 } 607 var msglen int 608 for shift := uint(0); ; shift += 7 { 609 if shift >= 64 { 610 return ErrIntOverflowQuota 611 } 612 if iNdEx >= l { 613 return io.ErrUnexpectedEOF 614 } 615 b := dAtA[iNdEx] 616 iNdEx++ 617 msglen |= int(b&0x7F) << shift 618 if b < 0x80 { 619 break 620 } 621 } 622 if msglen < 0 { 623 return ErrInvalidLengthQuota 624 } 625 postIndex := iNdEx + msglen 626 if postIndex < 0 { 627 return ErrInvalidLengthQuota 628 } 629 if postIndex > l { 630 return io.ErrUnexpectedEOF 631 } 632 if m.Quotas == nil { 633 m.Quotas = make(map[string]QuotaRequest_QuotaParams) 634 } 635 var mapkey string 636 mapvalue := &QuotaRequest_QuotaParams{} 637 for iNdEx < postIndex { 638 entryPreIndex := iNdEx 639 var wire uint64 640 for shift := uint(0); ; shift += 7 { 641 if shift >= 64 { 642 return ErrIntOverflowQuota 643 } 644 if iNdEx >= l { 645 return io.ErrUnexpectedEOF 646 } 647 b := dAtA[iNdEx] 648 iNdEx++ 649 wire |= uint64(b&0x7F) << shift 650 if b < 0x80 { 651 break 652 } 653 } 654 fieldNum := int32(wire >> 3) 655 if fieldNum == 1 { 656 var stringLenmapkey uint64 657 for shift := uint(0); ; shift += 7 { 658 if shift >= 64 { 659 return ErrIntOverflowQuota 660 } 661 if iNdEx >= l { 662 return io.ErrUnexpectedEOF 663 } 664 b := dAtA[iNdEx] 665 iNdEx++ 666 stringLenmapkey |= uint64(b&0x7F) << shift 667 if b < 0x80 { 668 break 669 } 670 } 671 intStringLenmapkey := int(stringLenmapkey) 672 if intStringLenmapkey < 0 { 673 return ErrInvalidLengthQuota 674 } 675 postStringIndexmapkey := iNdEx + intStringLenmapkey 676 if postStringIndexmapkey < 0 { 677 return ErrInvalidLengthQuota 678 } 679 if postStringIndexmapkey > l { 680 return io.ErrUnexpectedEOF 681 } 682 mapkey = string(dAtA[iNdEx:postStringIndexmapkey]) 683 iNdEx = postStringIndexmapkey 684 } else if fieldNum == 2 { 685 var mapmsglen int 686 for shift := uint(0); ; shift += 7 { 687 if shift >= 64 { 688 return ErrIntOverflowQuota 689 } 690 if iNdEx >= l { 691 return io.ErrUnexpectedEOF 692 } 693 b := dAtA[iNdEx] 694 iNdEx++ 695 mapmsglen |= int(b&0x7F) << shift 696 if b < 0x80 { 697 break 698 } 699 } 700 if mapmsglen < 0 { 701 return ErrInvalidLengthQuota 702 } 703 postmsgIndex := iNdEx + mapmsglen 704 if postmsgIndex < 0 { 705 return ErrInvalidLengthQuota 706 } 707 if postmsgIndex > l { 708 return io.ErrUnexpectedEOF 709 } 710 mapvalue = &QuotaRequest_QuotaParams{} 711 if err := mapvalue.Unmarshal(dAtA[iNdEx:postmsgIndex]); err != nil { 712 return err 713 } 714 iNdEx = postmsgIndex 715 } else { 716 iNdEx = entryPreIndex 717 skippy, err := skipQuota(dAtA[iNdEx:]) 718 if err != nil { 719 return err 720 } 721 if skippy < 0 { 722 return ErrInvalidLengthQuota 723 } 724 if (iNdEx + skippy) > postIndex { 725 return io.ErrUnexpectedEOF 726 } 727 iNdEx += skippy 728 } 729 } 730 m.Quotas[mapkey] = *mapvalue 731 iNdEx = postIndex 732 default: 733 iNdEx = preIndex 734 skippy, err := skipQuota(dAtA[iNdEx:]) 735 if err != nil { 736 return err 737 } 738 if skippy < 0 { 739 return ErrInvalidLengthQuota 740 } 741 if (iNdEx + skippy) < 0 { 742 return ErrInvalidLengthQuota 743 } 744 if (iNdEx + skippy) > l { 745 return io.ErrUnexpectedEOF 746 } 747 iNdEx += skippy 748 } 749 } 750 751 if iNdEx > l { 752 return io.ErrUnexpectedEOF 753 } 754 return nil 755} 756func (m *QuotaRequest_QuotaParams) Unmarshal(dAtA []byte) error { 757 l := len(dAtA) 758 iNdEx := 0 759 for iNdEx < l { 760 preIndex := iNdEx 761 var wire uint64 762 for shift := uint(0); ; shift += 7 { 763 if shift >= 64 { 764 return ErrIntOverflowQuota 765 } 766 if iNdEx >= l { 767 return io.ErrUnexpectedEOF 768 } 769 b := dAtA[iNdEx] 770 iNdEx++ 771 wire |= uint64(b&0x7F) << shift 772 if b < 0x80 { 773 break 774 } 775 } 776 fieldNum := int32(wire >> 3) 777 wireType := int(wire & 0x7) 778 if wireType == 4 { 779 return fmt.Errorf("proto: QuotaParams: wiretype end group for non-group") 780 } 781 if fieldNum <= 0 { 782 return fmt.Errorf("proto: QuotaParams: illegal tag %d (wire type %d)", fieldNum, wire) 783 } 784 switch fieldNum { 785 case 1: 786 if wireType != 0 { 787 return fmt.Errorf("proto: wrong wireType = %d for field Amount", wireType) 788 } 789 m.Amount = 0 790 for shift := uint(0); ; shift += 7 { 791 if shift >= 64 { 792 return ErrIntOverflowQuota 793 } 794 if iNdEx >= l { 795 return io.ErrUnexpectedEOF 796 } 797 b := dAtA[iNdEx] 798 iNdEx++ 799 m.Amount |= int64(b&0x7F) << shift 800 if b < 0x80 { 801 break 802 } 803 } 804 case 2: 805 if wireType != 0 { 806 return fmt.Errorf("proto: wrong wireType = %d for field BestEffort", wireType) 807 } 808 var v int 809 for shift := uint(0); ; shift += 7 { 810 if shift >= 64 { 811 return ErrIntOverflowQuota 812 } 813 if iNdEx >= l { 814 return io.ErrUnexpectedEOF 815 } 816 b := dAtA[iNdEx] 817 iNdEx++ 818 v |= int(b&0x7F) << shift 819 if b < 0x80 { 820 break 821 } 822 } 823 m.BestEffort = bool(v != 0) 824 default: 825 iNdEx = preIndex 826 skippy, err := skipQuota(dAtA[iNdEx:]) 827 if err != nil { 828 return err 829 } 830 if skippy < 0 { 831 return ErrInvalidLengthQuota 832 } 833 if (iNdEx + skippy) < 0 { 834 return ErrInvalidLengthQuota 835 } 836 if (iNdEx + skippy) > l { 837 return io.ErrUnexpectedEOF 838 } 839 iNdEx += skippy 840 } 841 } 842 843 if iNdEx > l { 844 return io.ErrUnexpectedEOF 845 } 846 return nil 847} 848func (m *QuotaResult) Unmarshal(dAtA []byte) error { 849 l := len(dAtA) 850 iNdEx := 0 851 for iNdEx < l { 852 preIndex := iNdEx 853 var wire uint64 854 for shift := uint(0); ; shift += 7 { 855 if shift >= 64 { 856 return ErrIntOverflowQuota 857 } 858 if iNdEx >= l { 859 return io.ErrUnexpectedEOF 860 } 861 b := dAtA[iNdEx] 862 iNdEx++ 863 wire |= uint64(b&0x7F) << shift 864 if b < 0x80 { 865 break 866 } 867 } 868 fieldNum := int32(wire >> 3) 869 wireType := int(wire & 0x7) 870 if wireType == 4 { 871 return fmt.Errorf("proto: QuotaResult: wiretype end group for non-group") 872 } 873 if fieldNum <= 0 { 874 return fmt.Errorf("proto: QuotaResult: illegal tag %d (wire type %d)", fieldNum, wire) 875 } 876 switch fieldNum { 877 case 1: 878 if wireType != 2 { 879 return fmt.Errorf("proto: wrong wireType = %d for field Quotas", wireType) 880 } 881 var msglen int 882 for shift := uint(0); ; shift += 7 { 883 if shift >= 64 { 884 return ErrIntOverflowQuota 885 } 886 if iNdEx >= l { 887 return io.ErrUnexpectedEOF 888 } 889 b := dAtA[iNdEx] 890 iNdEx++ 891 msglen |= int(b&0x7F) << shift 892 if b < 0x80 { 893 break 894 } 895 } 896 if msglen < 0 { 897 return ErrInvalidLengthQuota 898 } 899 postIndex := iNdEx + msglen 900 if postIndex < 0 { 901 return ErrInvalidLengthQuota 902 } 903 if postIndex > l { 904 return io.ErrUnexpectedEOF 905 } 906 if m.Quotas == nil { 907 m.Quotas = make(map[string]QuotaResult_Result) 908 } 909 var mapkey string 910 mapvalue := &QuotaResult_Result{} 911 for iNdEx < postIndex { 912 entryPreIndex := iNdEx 913 var wire uint64 914 for shift := uint(0); ; shift += 7 { 915 if shift >= 64 { 916 return ErrIntOverflowQuota 917 } 918 if iNdEx >= l { 919 return io.ErrUnexpectedEOF 920 } 921 b := dAtA[iNdEx] 922 iNdEx++ 923 wire |= uint64(b&0x7F) << shift 924 if b < 0x80 { 925 break 926 } 927 } 928 fieldNum := int32(wire >> 3) 929 if fieldNum == 1 { 930 var stringLenmapkey uint64 931 for shift := uint(0); ; shift += 7 { 932 if shift >= 64 { 933 return ErrIntOverflowQuota 934 } 935 if iNdEx >= l { 936 return io.ErrUnexpectedEOF 937 } 938 b := dAtA[iNdEx] 939 iNdEx++ 940 stringLenmapkey |= uint64(b&0x7F) << shift 941 if b < 0x80 { 942 break 943 } 944 } 945 intStringLenmapkey := int(stringLenmapkey) 946 if intStringLenmapkey < 0 { 947 return ErrInvalidLengthQuota 948 } 949 postStringIndexmapkey := iNdEx + intStringLenmapkey 950 if postStringIndexmapkey < 0 { 951 return ErrInvalidLengthQuota 952 } 953 if postStringIndexmapkey > l { 954 return io.ErrUnexpectedEOF 955 } 956 mapkey = string(dAtA[iNdEx:postStringIndexmapkey]) 957 iNdEx = postStringIndexmapkey 958 } else if fieldNum == 2 { 959 var mapmsglen int 960 for shift := uint(0); ; shift += 7 { 961 if shift >= 64 { 962 return ErrIntOverflowQuota 963 } 964 if iNdEx >= l { 965 return io.ErrUnexpectedEOF 966 } 967 b := dAtA[iNdEx] 968 iNdEx++ 969 mapmsglen |= int(b&0x7F) << shift 970 if b < 0x80 { 971 break 972 } 973 } 974 if mapmsglen < 0 { 975 return ErrInvalidLengthQuota 976 } 977 postmsgIndex := iNdEx + mapmsglen 978 if postmsgIndex < 0 { 979 return ErrInvalidLengthQuota 980 } 981 if postmsgIndex > l { 982 return io.ErrUnexpectedEOF 983 } 984 mapvalue = &QuotaResult_Result{} 985 if err := mapvalue.Unmarshal(dAtA[iNdEx:postmsgIndex]); err != nil { 986 return err 987 } 988 iNdEx = postmsgIndex 989 } else { 990 iNdEx = entryPreIndex 991 skippy, err := skipQuota(dAtA[iNdEx:]) 992 if err != nil { 993 return err 994 } 995 if skippy < 0 { 996 return ErrInvalidLengthQuota 997 } 998 if (iNdEx + skippy) > postIndex { 999 return io.ErrUnexpectedEOF 1000 } 1001 iNdEx += skippy 1002 } 1003 } 1004 m.Quotas[mapkey] = *mapvalue 1005 iNdEx = postIndex 1006 default: 1007 iNdEx = preIndex 1008 skippy, err := skipQuota(dAtA[iNdEx:]) 1009 if err != nil { 1010 return err 1011 } 1012 if skippy < 0 { 1013 return ErrInvalidLengthQuota 1014 } 1015 if (iNdEx + skippy) < 0 { 1016 return ErrInvalidLengthQuota 1017 } 1018 if (iNdEx + skippy) > l { 1019 return io.ErrUnexpectedEOF 1020 } 1021 iNdEx += skippy 1022 } 1023 } 1024 1025 if iNdEx > l { 1026 return io.ErrUnexpectedEOF 1027 } 1028 return nil 1029} 1030func (m *QuotaResult_Result) Unmarshal(dAtA []byte) error { 1031 l := len(dAtA) 1032 iNdEx := 0 1033 for iNdEx < l { 1034 preIndex := iNdEx 1035 var wire uint64 1036 for shift := uint(0); ; shift += 7 { 1037 if shift >= 64 { 1038 return ErrIntOverflowQuota 1039 } 1040 if iNdEx >= l { 1041 return io.ErrUnexpectedEOF 1042 } 1043 b := dAtA[iNdEx] 1044 iNdEx++ 1045 wire |= uint64(b&0x7F) << shift 1046 if b < 0x80 { 1047 break 1048 } 1049 } 1050 fieldNum := int32(wire >> 3) 1051 wireType := int(wire & 0x7) 1052 if wireType == 4 { 1053 return fmt.Errorf("proto: Result: wiretype end group for non-group") 1054 } 1055 if fieldNum <= 0 { 1056 return fmt.Errorf("proto: Result: illegal tag %d (wire type %d)", fieldNum, wire) 1057 } 1058 switch fieldNum { 1059 case 2: 1060 if wireType != 2 { 1061 return fmt.Errorf("proto: wrong wireType = %d for field ValidDuration", wireType) 1062 } 1063 var msglen int 1064 for shift := uint(0); ; shift += 7 { 1065 if shift >= 64 { 1066 return ErrIntOverflowQuota 1067 } 1068 if iNdEx >= l { 1069 return io.ErrUnexpectedEOF 1070 } 1071 b := dAtA[iNdEx] 1072 iNdEx++ 1073 msglen |= int(b&0x7F) << shift 1074 if b < 0x80 { 1075 break 1076 } 1077 } 1078 if msglen < 0 { 1079 return ErrInvalidLengthQuota 1080 } 1081 postIndex := iNdEx + msglen 1082 if postIndex < 0 { 1083 return ErrInvalidLengthQuota 1084 } 1085 if postIndex > l { 1086 return io.ErrUnexpectedEOF 1087 } 1088 if err := github_com_gogo_protobuf_types.StdDurationUnmarshal(&m.ValidDuration, dAtA[iNdEx:postIndex]); err != nil { 1089 return err 1090 } 1091 iNdEx = postIndex 1092 case 3: 1093 if wireType != 0 { 1094 return fmt.Errorf("proto: wrong wireType = %d for field GrantedAmount", wireType) 1095 } 1096 m.GrantedAmount = 0 1097 for shift := uint(0); ; shift += 7 { 1098 if shift >= 64 { 1099 return ErrIntOverflowQuota 1100 } 1101 if iNdEx >= l { 1102 return io.ErrUnexpectedEOF 1103 } 1104 b := dAtA[iNdEx] 1105 iNdEx++ 1106 m.GrantedAmount |= int64(b&0x7F) << shift 1107 if b < 0x80 { 1108 break 1109 } 1110 } 1111 case 4: 1112 if wireType != 2 { 1113 return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) 1114 } 1115 var msglen int 1116 for shift := uint(0); ; shift += 7 { 1117 if shift >= 64 { 1118 return ErrIntOverflowQuota 1119 } 1120 if iNdEx >= l { 1121 return io.ErrUnexpectedEOF 1122 } 1123 b := dAtA[iNdEx] 1124 iNdEx++ 1125 msglen |= int(b&0x7F) << shift 1126 if b < 0x80 { 1127 break 1128 } 1129 } 1130 if msglen < 0 { 1131 return ErrInvalidLengthQuota 1132 } 1133 postIndex := iNdEx + msglen 1134 if postIndex < 0 { 1135 return ErrInvalidLengthQuota 1136 } 1137 if postIndex > l { 1138 return io.ErrUnexpectedEOF 1139 } 1140 if err := m.Status.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { 1141 return err 1142 } 1143 iNdEx = postIndex 1144 default: 1145 iNdEx = preIndex 1146 skippy, err := skipQuota(dAtA[iNdEx:]) 1147 if err != nil { 1148 return err 1149 } 1150 if skippy < 0 { 1151 return ErrInvalidLengthQuota 1152 } 1153 if (iNdEx + skippy) < 0 { 1154 return ErrInvalidLengthQuota 1155 } 1156 if (iNdEx + skippy) > l { 1157 return io.ErrUnexpectedEOF 1158 } 1159 iNdEx += skippy 1160 } 1161 } 1162 1163 if iNdEx > l { 1164 return io.ErrUnexpectedEOF 1165 } 1166 return nil 1167} 1168func skipQuota(dAtA []byte) (n int, err error) { 1169 l := len(dAtA) 1170 iNdEx := 0 1171 for iNdEx < l { 1172 var wire uint64 1173 for shift := uint(0); ; shift += 7 { 1174 if shift >= 64 { 1175 return 0, ErrIntOverflowQuota 1176 } 1177 if iNdEx >= l { 1178 return 0, io.ErrUnexpectedEOF 1179 } 1180 b := dAtA[iNdEx] 1181 iNdEx++ 1182 wire |= (uint64(b) & 0x7F) << shift 1183 if b < 0x80 { 1184 break 1185 } 1186 } 1187 wireType := int(wire & 0x7) 1188 switch wireType { 1189 case 0: 1190 for shift := uint(0); ; shift += 7 { 1191 if shift >= 64 { 1192 return 0, ErrIntOverflowQuota 1193 } 1194 if iNdEx >= l { 1195 return 0, io.ErrUnexpectedEOF 1196 } 1197 iNdEx++ 1198 if dAtA[iNdEx-1] < 0x80 { 1199 break 1200 } 1201 } 1202 return iNdEx, nil 1203 case 1: 1204 iNdEx += 8 1205 return iNdEx, nil 1206 case 2: 1207 var length int 1208 for shift := uint(0); ; shift += 7 { 1209 if shift >= 64 { 1210 return 0, ErrIntOverflowQuota 1211 } 1212 if iNdEx >= l { 1213 return 0, io.ErrUnexpectedEOF 1214 } 1215 b := dAtA[iNdEx] 1216 iNdEx++ 1217 length |= (int(b) & 0x7F) << shift 1218 if b < 0x80 { 1219 break 1220 } 1221 } 1222 if length < 0 { 1223 return 0, ErrInvalidLengthQuota 1224 } 1225 iNdEx += length 1226 if iNdEx < 0 { 1227 return 0, ErrInvalidLengthQuota 1228 } 1229 return iNdEx, nil 1230 case 3: 1231 for { 1232 var innerWire uint64 1233 var start int = iNdEx 1234 for shift := uint(0); ; shift += 7 { 1235 if shift >= 64 { 1236 return 0, ErrIntOverflowQuota 1237 } 1238 if iNdEx >= l { 1239 return 0, io.ErrUnexpectedEOF 1240 } 1241 b := dAtA[iNdEx] 1242 iNdEx++ 1243 innerWire |= (uint64(b) & 0x7F) << shift 1244 if b < 0x80 { 1245 break 1246 } 1247 } 1248 innerWireType := int(innerWire & 0x7) 1249 if innerWireType == 4 { 1250 break 1251 } 1252 next, err := skipQuota(dAtA[start:]) 1253 if err != nil { 1254 return 0, err 1255 } 1256 iNdEx = start + next 1257 if iNdEx < 0 { 1258 return 0, ErrInvalidLengthQuota 1259 } 1260 } 1261 return iNdEx, nil 1262 case 4: 1263 return iNdEx, nil 1264 case 5: 1265 iNdEx += 4 1266 return iNdEx, nil 1267 default: 1268 return 0, fmt.Errorf("proto: illegal wireType %d", wireType) 1269 } 1270 } 1271 panic("unreachable") 1272} 1273 1274var ( 1275 ErrInvalidLengthQuota = fmt.Errorf("proto: negative length found during unmarshaling") 1276 ErrIntOverflowQuota = fmt.Errorf("proto: integer overflow") 1277) 1278