github.com/m3db/m3@v1.5.0/src/query/generated/proto/prompb/remote.pb.go (about) 1 // Code generated by protoc-gen-gogo. DO NOT EDIT. 2 // source: github.com/m3db/m3/src/query/generated/proto/prompb/remote.proto 3 4 // Copyright (c) 2021 Uber Technologies, Inc. 5 // 6 // Permission is hereby granted, free of charge, to any person obtaining a copy 7 // of this software and associated documentation files (the "Software"), to deal 8 // in the Software without restriction, including without limitation the rights 9 // to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 10 // copies of the Software, and to permit persons to whom the Software is 11 // furnished to do so, subject to the following conditions: 12 // 13 // The above copyright notice and this permission notice shall be included in 14 // all copies or substantial portions of the Software. 15 // 16 // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 17 // IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 18 // FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 19 // AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 20 // LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 21 // OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 22 // THE SOFTWARE. 23 24 /* 25 Package prompb is a generated protocol buffer package. 26 27 It is generated from these files: 28 github.com/m3db/m3/src/query/generated/proto/prompb/remote.proto 29 github.com/m3db/m3/src/query/generated/proto/prompb/types.proto 30 31 It has these top-level messages: 32 WriteRequest 33 ReadRequest 34 ReadResponse 35 Query 36 QueryResult 37 Sample 38 TimeSeries 39 Label 40 Labels 41 LabelMatcher 42 */ 43 package prompb 44 45 import proto "github.com/gogo/protobuf/proto" 46 import fmt "fmt" 47 import math "math" 48 import _ "github.com/gogo/protobuf/gogoproto" 49 50 import io "io" 51 52 // Reference imports to suppress errors if they are not otherwise used. 53 var _ = proto.Marshal 54 var _ = fmt.Errorf 55 var _ = math.Inf 56 57 // This is a compile-time assertion to ensure that this generated file 58 // is compatible with the proto package it is being compiled against. 59 // A compilation error at this line likely means your copy of the 60 // proto package needs to be updated. 61 const _ = proto.GoGoProtoPackageIsVersion2 // please upgrade the proto package 62 63 type WriteRequest struct { 64 Timeseries []TimeSeries `protobuf:"bytes,1,rep,name=timeseries" json:"timeseries"` 65 } 66 67 func (m *WriteRequest) Reset() { *m = WriteRequest{} } 68 func (m *WriteRequest) String() string { return proto.CompactTextString(m) } 69 func (*WriteRequest) ProtoMessage() {} 70 func (*WriteRequest) Descriptor() ([]byte, []int) { return fileDescriptorRemote, []int{0} } 71 72 func (m *WriteRequest) GetTimeseries() []TimeSeries { 73 if m != nil { 74 return m.Timeseries 75 } 76 return nil 77 } 78 79 type ReadRequest struct { 80 Queries []*Query `protobuf:"bytes,1,rep,name=queries" json:"queries,omitempty"` 81 } 82 83 func (m *ReadRequest) Reset() { *m = ReadRequest{} } 84 func (m *ReadRequest) String() string { return proto.CompactTextString(m) } 85 func (*ReadRequest) ProtoMessage() {} 86 func (*ReadRequest) Descriptor() ([]byte, []int) { return fileDescriptorRemote, []int{1} } 87 88 func (m *ReadRequest) GetQueries() []*Query { 89 if m != nil { 90 return m.Queries 91 } 92 return nil 93 } 94 95 type ReadResponse struct { 96 // In same order as the request's queries. 97 Results []*QueryResult `protobuf:"bytes,1,rep,name=results" json:"results,omitempty"` 98 } 99 100 func (m *ReadResponse) Reset() { *m = ReadResponse{} } 101 func (m *ReadResponse) String() string { return proto.CompactTextString(m) } 102 func (*ReadResponse) ProtoMessage() {} 103 func (*ReadResponse) Descriptor() ([]byte, []int) { return fileDescriptorRemote, []int{2} } 104 105 func (m *ReadResponse) GetResults() []*QueryResult { 106 if m != nil { 107 return m.Results 108 } 109 return nil 110 } 111 112 type Query struct { 113 StartTimestampMs int64 `protobuf:"varint,1,opt,name=start_timestamp_ms,json=startTimestampMs,proto3" json:"start_timestamp_ms,omitempty"` 114 EndTimestampMs int64 `protobuf:"varint,2,opt,name=end_timestamp_ms,json=endTimestampMs,proto3" json:"end_timestamp_ms,omitempty"` 115 Matchers []*LabelMatcher `protobuf:"bytes,3,rep,name=matchers" json:"matchers,omitempty"` 116 } 117 118 func (m *Query) Reset() { *m = Query{} } 119 func (m *Query) String() string { return proto.CompactTextString(m) } 120 func (*Query) ProtoMessage() {} 121 func (*Query) Descriptor() ([]byte, []int) { return fileDescriptorRemote, []int{3} } 122 123 func (m *Query) GetStartTimestampMs() int64 { 124 if m != nil { 125 return m.StartTimestampMs 126 } 127 return 0 128 } 129 130 func (m *Query) GetEndTimestampMs() int64 { 131 if m != nil { 132 return m.EndTimestampMs 133 } 134 return 0 135 } 136 137 func (m *Query) GetMatchers() []*LabelMatcher { 138 if m != nil { 139 return m.Matchers 140 } 141 return nil 142 } 143 144 type QueryResult struct { 145 Timeseries []*TimeSeries `protobuf:"bytes,1,rep,name=timeseries" json:"timeseries,omitempty"` 146 } 147 148 func (m *QueryResult) Reset() { *m = QueryResult{} } 149 func (m *QueryResult) String() string { return proto.CompactTextString(m) } 150 func (*QueryResult) ProtoMessage() {} 151 func (*QueryResult) Descriptor() ([]byte, []int) { return fileDescriptorRemote, []int{4} } 152 153 func (m *QueryResult) GetTimeseries() []*TimeSeries { 154 if m != nil { 155 return m.Timeseries 156 } 157 return nil 158 } 159 160 func init() { 161 proto.RegisterType((*WriteRequest)(nil), "m3prometheus.WriteRequest") 162 proto.RegisterType((*ReadRequest)(nil), "m3prometheus.ReadRequest") 163 proto.RegisterType((*ReadResponse)(nil), "m3prometheus.ReadResponse") 164 proto.RegisterType((*Query)(nil), "m3prometheus.Query") 165 proto.RegisterType((*QueryResult)(nil), "m3prometheus.QueryResult") 166 } 167 func (m *WriteRequest) Marshal() (dAtA []byte, err error) { 168 size := m.Size() 169 dAtA = make([]byte, size) 170 n, err := m.MarshalTo(dAtA) 171 if err != nil { 172 return nil, err 173 } 174 return dAtA[:n], nil 175 } 176 177 func (m *WriteRequest) MarshalTo(dAtA []byte) (int, error) { 178 var i int 179 _ = i 180 var l int 181 _ = l 182 if len(m.Timeseries) > 0 { 183 for _, msg := range m.Timeseries { 184 dAtA[i] = 0xa 185 i++ 186 i = encodeVarintRemote(dAtA, i, uint64(msg.Size())) 187 n, err := msg.MarshalTo(dAtA[i:]) 188 if err != nil { 189 return 0, err 190 } 191 i += n 192 } 193 } 194 return i, nil 195 } 196 197 func (m *ReadRequest) Marshal() (dAtA []byte, err error) { 198 size := m.Size() 199 dAtA = make([]byte, size) 200 n, err := m.MarshalTo(dAtA) 201 if err != nil { 202 return nil, err 203 } 204 return dAtA[:n], nil 205 } 206 207 func (m *ReadRequest) MarshalTo(dAtA []byte) (int, error) { 208 var i int 209 _ = i 210 var l int 211 _ = l 212 if len(m.Queries) > 0 { 213 for _, msg := range m.Queries { 214 dAtA[i] = 0xa 215 i++ 216 i = encodeVarintRemote(dAtA, i, uint64(msg.Size())) 217 n, err := msg.MarshalTo(dAtA[i:]) 218 if err != nil { 219 return 0, err 220 } 221 i += n 222 } 223 } 224 return i, nil 225 } 226 227 func (m *ReadResponse) Marshal() (dAtA []byte, err error) { 228 size := m.Size() 229 dAtA = make([]byte, size) 230 n, err := m.MarshalTo(dAtA) 231 if err != nil { 232 return nil, err 233 } 234 return dAtA[:n], nil 235 } 236 237 func (m *ReadResponse) MarshalTo(dAtA []byte) (int, error) { 238 var i int 239 _ = i 240 var l int 241 _ = l 242 if len(m.Results) > 0 { 243 for _, msg := range m.Results { 244 dAtA[i] = 0xa 245 i++ 246 i = encodeVarintRemote(dAtA, i, uint64(msg.Size())) 247 n, err := msg.MarshalTo(dAtA[i:]) 248 if err != nil { 249 return 0, err 250 } 251 i += n 252 } 253 } 254 return i, nil 255 } 256 257 func (m *Query) Marshal() (dAtA []byte, err error) { 258 size := m.Size() 259 dAtA = make([]byte, size) 260 n, err := m.MarshalTo(dAtA) 261 if err != nil { 262 return nil, err 263 } 264 return dAtA[:n], nil 265 } 266 267 func (m *Query) MarshalTo(dAtA []byte) (int, error) { 268 var i int 269 _ = i 270 var l int 271 _ = l 272 if m.StartTimestampMs != 0 { 273 dAtA[i] = 0x8 274 i++ 275 i = encodeVarintRemote(dAtA, i, uint64(m.StartTimestampMs)) 276 } 277 if m.EndTimestampMs != 0 { 278 dAtA[i] = 0x10 279 i++ 280 i = encodeVarintRemote(dAtA, i, uint64(m.EndTimestampMs)) 281 } 282 if len(m.Matchers) > 0 { 283 for _, msg := range m.Matchers { 284 dAtA[i] = 0x1a 285 i++ 286 i = encodeVarintRemote(dAtA, i, uint64(msg.Size())) 287 n, err := msg.MarshalTo(dAtA[i:]) 288 if err != nil { 289 return 0, err 290 } 291 i += n 292 } 293 } 294 return i, nil 295 } 296 297 func (m *QueryResult) Marshal() (dAtA []byte, err error) { 298 size := m.Size() 299 dAtA = make([]byte, size) 300 n, err := m.MarshalTo(dAtA) 301 if err != nil { 302 return nil, err 303 } 304 return dAtA[:n], nil 305 } 306 307 func (m *QueryResult) MarshalTo(dAtA []byte) (int, error) { 308 var i int 309 _ = i 310 var l int 311 _ = l 312 if len(m.Timeseries) > 0 { 313 for _, msg := range m.Timeseries { 314 dAtA[i] = 0xa 315 i++ 316 i = encodeVarintRemote(dAtA, i, uint64(msg.Size())) 317 n, err := msg.MarshalTo(dAtA[i:]) 318 if err != nil { 319 return 0, err 320 } 321 i += n 322 } 323 } 324 return i, nil 325 } 326 327 func encodeVarintRemote(dAtA []byte, offset int, v uint64) int { 328 for v >= 1<<7 { 329 dAtA[offset] = uint8(v&0x7f | 0x80) 330 v >>= 7 331 offset++ 332 } 333 dAtA[offset] = uint8(v) 334 return offset + 1 335 } 336 func (m *WriteRequest) Size() (n int) { 337 var l int 338 _ = l 339 if len(m.Timeseries) > 0 { 340 for _, e := range m.Timeseries { 341 l = e.Size() 342 n += 1 + l + sovRemote(uint64(l)) 343 } 344 } 345 return n 346 } 347 348 func (m *ReadRequest) Size() (n int) { 349 var l int 350 _ = l 351 if len(m.Queries) > 0 { 352 for _, e := range m.Queries { 353 l = e.Size() 354 n += 1 + l + sovRemote(uint64(l)) 355 } 356 } 357 return n 358 } 359 360 func (m *ReadResponse) Size() (n int) { 361 var l int 362 _ = l 363 if len(m.Results) > 0 { 364 for _, e := range m.Results { 365 l = e.Size() 366 n += 1 + l + sovRemote(uint64(l)) 367 } 368 } 369 return n 370 } 371 372 func (m *Query) Size() (n int) { 373 var l int 374 _ = l 375 if m.StartTimestampMs != 0 { 376 n += 1 + sovRemote(uint64(m.StartTimestampMs)) 377 } 378 if m.EndTimestampMs != 0 { 379 n += 1 + sovRemote(uint64(m.EndTimestampMs)) 380 } 381 if len(m.Matchers) > 0 { 382 for _, e := range m.Matchers { 383 l = e.Size() 384 n += 1 + l + sovRemote(uint64(l)) 385 } 386 } 387 return n 388 } 389 390 func (m *QueryResult) Size() (n int) { 391 var l int 392 _ = l 393 if len(m.Timeseries) > 0 { 394 for _, e := range m.Timeseries { 395 l = e.Size() 396 n += 1 + l + sovRemote(uint64(l)) 397 } 398 } 399 return n 400 } 401 402 func sovRemote(x uint64) (n int) { 403 for { 404 n++ 405 x >>= 7 406 if x == 0 { 407 break 408 } 409 } 410 return n 411 } 412 func sozRemote(x uint64) (n int) { 413 return sovRemote(uint64((x << 1) ^ uint64((int64(x) >> 63)))) 414 } 415 func (m *WriteRequest) Unmarshal(dAtA []byte) error { 416 l := len(dAtA) 417 iNdEx := 0 418 for iNdEx < l { 419 preIndex := iNdEx 420 var wire uint64 421 for shift := uint(0); ; shift += 7 { 422 if shift >= 64 { 423 return ErrIntOverflowRemote 424 } 425 if iNdEx >= l { 426 return io.ErrUnexpectedEOF 427 } 428 b := dAtA[iNdEx] 429 iNdEx++ 430 wire |= (uint64(b) & 0x7F) << shift 431 if b < 0x80 { 432 break 433 } 434 } 435 fieldNum := int32(wire >> 3) 436 wireType := int(wire & 0x7) 437 if wireType == 4 { 438 return fmt.Errorf("proto: WriteRequest: wiretype end group for non-group") 439 } 440 if fieldNum <= 0 { 441 return fmt.Errorf("proto: WriteRequest: illegal tag %d (wire type %d)", fieldNum, wire) 442 } 443 switch fieldNum { 444 case 1: 445 if wireType != 2 { 446 return fmt.Errorf("proto: wrong wireType = %d for field Timeseries", wireType) 447 } 448 var msglen int 449 for shift := uint(0); ; shift += 7 { 450 if shift >= 64 { 451 return ErrIntOverflowRemote 452 } 453 if iNdEx >= l { 454 return io.ErrUnexpectedEOF 455 } 456 b := dAtA[iNdEx] 457 iNdEx++ 458 msglen |= (int(b) & 0x7F) << shift 459 if b < 0x80 { 460 break 461 } 462 } 463 if msglen < 0 { 464 return ErrInvalidLengthRemote 465 } 466 postIndex := iNdEx + msglen 467 if postIndex > l { 468 return io.ErrUnexpectedEOF 469 } 470 m.Timeseries = append(m.Timeseries, TimeSeries{}) 471 if err := m.Timeseries[len(m.Timeseries)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { 472 return err 473 } 474 iNdEx = postIndex 475 default: 476 iNdEx = preIndex 477 skippy, err := skipRemote(dAtA[iNdEx:]) 478 if err != nil { 479 return err 480 } 481 if skippy < 0 { 482 return ErrInvalidLengthRemote 483 } 484 if (iNdEx + skippy) > l { 485 return io.ErrUnexpectedEOF 486 } 487 iNdEx += skippy 488 } 489 } 490 491 if iNdEx > l { 492 return io.ErrUnexpectedEOF 493 } 494 return nil 495 } 496 func (m *ReadRequest) Unmarshal(dAtA []byte) error { 497 l := len(dAtA) 498 iNdEx := 0 499 for iNdEx < l { 500 preIndex := iNdEx 501 var wire uint64 502 for shift := uint(0); ; shift += 7 { 503 if shift >= 64 { 504 return ErrIntOverflowRemote 505 } 506 if iNdEx >= l { 507 return io.ErrUnexpectedEOF 508 } 509 b := dAtA[iNdEx] 510 iNdEx++ 511 wire |= (uint64(b) & 0x7F) << shift 512 if b < 0x80 { 513 break 514 } 515 } 516 fieldNum := int32(wire >> 3) 517 wireType := int(wire & 0x7) 518 if wireType == 4 { 519 return fmt.Errorf("proto: ReadRequest: wiretype end group for non-group") 520 } 521 if fieldNum <= 0 { 522 return fmt.Errorf("proto: ReadRequest: illegal tag %d (wire type %d)", fieldNum, wire) 523 } 524 switch fieldNum { 525 case 1: 526 if wireType != 2 { 527 return fmt.Errorf("proto: wrong wireType = %d for field Queries", wireType) 528 } 529 var msglen int 530 for shift := uint(0); ; shift += 7 { 531 if shift >= 64 { 532 return ErrIntOverflowRemote 533 } 534 if iNdEx >= l { 535 return io.ErrUnexpectedEOF 536 } 537 b := dAtA[iNdEx] 538 iNdEx++ 539 msglen |= (int(b) & 0x7F) << shift 540 if b < 0x80 { 541 break 542 } 543 } 544 if msglen < 0 { 545 return ErrInvalidLengthRemote 546 } 547 postIndex := iNdEx + msglen 548 if postIndex > l { 549 return io.ErrUnexpectedEOF 550 } 551 m.Queries = append(m.Queries, &Query{}) 552 if err := m.Queries[len(m.Queries)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { 553 return err 554 } 555 iNdEx = postIndex 556 default: 557 iNdEx = preIndex 558 skippy, err := skipRemote(dAtA[iNdEx:]) 559 if err != nil { 560 return err 561 } 562 if skippy < 0 { 563 return ErrInvalidLengthRemote 564 } 565 if (iNdEx + skippy) > l { 566 return io.ErrUnexpectedEOF 567 } 568 iNdEx += skippy 569 } 570 } 571 572 if iNdEx > l { 573 return io.ErrUnexpectedEOF 574 } 575 return nil 576 } 577 func (m *ReadResponse) Unmarshal(dAtA []byte) error { 578 l := len(dAtA) 579 iNdEx := 0 580 for iNdEx < l { 581 preIndex := iNdEx 582 var wire uint64 583 for shift := uint(0); ; shift += 7 { 584 if shift >= 64 { 585 return ErrIntOverflowRemote 586 } 587 if iNdEx >= l { 588 return io.ErrUnexpectedEOF 589 } 590 b := dAtA[iNdEx] 591 iNdEx++ 592 wire |= (uint64(b) & 0x7F) << shift 593 if b < 0x80 { 594 break 595 } 596 } 597 fieldNum := int32(wire >> 3) 598 wireType := int(wire & 0x7) 599 if wireType == 4 { 600 return fmt.Errorf("proto: ReadResponse: wiretype end group for non-group") 601 } 602 if fieldNum <= 0 { 603 return fmt.Errorf("proto: ReadResponse: illegal tag %d (wire type %d)", fieldNum, wire) 604 } 605 switch fieldNum { 606 case 1: 607 if wireType != 2 { 608 return fmt.Errorf("proto: wrong wireType = %d for field Results", wireType) 609 } 610 var msglen int 611 for shift := uint(0); ; shift += 7 { 612 if shift >= 64 { 613 return ErrIntOverflowRemote 614 } 615 if iNdEx >= l { 616 return io.ErrUnexpectedEOF 617 } 618 b := dAtA[iNdEx] 619 iNdEx++ 620 msglen |= (int(b) & 0x7F) << shift 621 if b < 0x80 { 622 break 623 } 624 } 625 if msglen < 0 { 626 return ErrInvalidLengthRemote 627 } 628 postIndex := iNdEx + msglen 629 if postIndex > l { 630 return io.ErrUnexpectedEOF 631 } 632 m.Results = append(m.Results, &QueryResult{}) 633 if err := m.Results[len(m.Results)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { 634 return err 635 } 636 iNdEx = postIndex 637 default: 638 iNdEx = preIndex 639 skippy, err := skipRemote(dAtA[iNdEx:]) 640 if err != nil { 641 return err 642 } 643 if skippy < 0 { 644 return ErrInvalidLengthRemote 645 } 646 if (iNdEx + skippy) > l { 647 return io.ErrUnexpectedEOF 648 } 649 iNdEx += skippy 650 } 651 } 652 653 if iNdEx > l { 654 return io.ErrUnexpectedEOF 655 } 656 return nil 657 } 658 func (m *Query) Unmarshal(dAtA []byte) error { 659 l := len(dAtA) 660 iNdEx := 0 661 for iNdEx < l { 662 preIndex := iNdEx 663 var wire uint64 664 for shift := uint(0); ; shift += 7 { 665 if shift >= 64 { 666 return ErrIntOverflowRemote 667 } 668 if iNdEx >= l { 669 return io.ErrUnexpectedEOF 670 } 671 b := dAtA[iNdEx] 672 iNdEx++ 673 wire |= (uint64(b) & 0x7F) << shift 674 if b < 0x80 { 675 break 676 } 677 } 678 fieldNum := int32(wire >> 3) 679 wireType := int(wire & 0x7) 680 if wireType == 4 { 681 return fmt.Errorf("proto: Query: wiretype end group for non-group") 682 } 683 if fieldNum <= 0 { 684 return fmt.Errorf("proto: Query: illegal tag %d (wire type %d)", fieldNum, wire) 685 } 686 switch fieldNum { 687 case 1: 688 if wireType != 0 { 689 return fmt.Errorf("proto: wrong wireType = %d for field StartTimestampMs", wireType) 690 } 691 m.StartTimestampMs = 0 692 for shift := uint(0); ; shift += 7 { 693 if shift >= 64 { 694 return ErrIntOverflowRemote 695 } 696 if iNdEx >= l { 697 return io.ErrUnexpectedEOF 698 } 699 b := dAtA[iNdEx] 700 iNdEx++ 701 m.StartTimestampMs |= (int64(b) & 0x7F) << shift 702 if b < 0x80 { 703 break 704 } 705 } 706 case 2: 707 if wireType != 0 { 708 return fmt.Errorf("proto: wrong wireType = %d for field EndTimestampMs", wireType) 709 } 710 m.EndTimestampMs = 0 711 for shift := uint(0); ; shift += 7 { 712 if shift >= 64 { 713 return ErrIntOverflowRemote 714 } 715 if iNdEx >= l { 716 return io.ErrUnexpectedEOF 717 } 718 b := dAtA[iNdEx] 719 iNdEx++ 720 m.EndTimestampMs |= (int64(b) & 0x7F) << shift 721 if b < 0x80 { 722 break 723 } 724 } 725 case 3: 726 if wireType != 2 { 727 return fmt.Errorf("proto: wrong wireType = %d for field Matchers", wireType) 728 } 729 var msglen int 730 for shift := uint(0); ; shift += 7 { 731 if shift >= 64 { 732 return ErrIntOverflowRemote 733 } 734 if iNdEx >= l { 735 return io.ErrUnexpectedEOF 736 } 737 b := dAtA[iNdEx] 738 iNdEx++ 739 msglen |= (int(b) & 0x7F) << shift 740 if b < 0x80 { 741 break 742 } 743 } 744 if msglen < 0 { 745 return ErrInvalidLengthRemote 746 } 747 postIndex := iNdEx + msglen 748 if postIndex > l { 749 return io.ErrUnexpectedEOF 750 } 751 m.Matchers = append(m.Matchers, &LabelMatcher{}) 752 if err := m.Matchers[len(m.Matchers)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { 753 return err 754 } 755 iNdEx = postIndex 756 default: 757 iNdEx = preIndex 758 skippy, err := skipRemote(dAtA[iNdEx:]) 759 if err != nil { 760 return err 761 } 762 if skippy < 0 { 763 return ErrInvalidLengthRemote 764 } 765 if (iNdEx + skippy) > l { 766 return io.ErrUnexpectedEOF 767 } 768 iNdEx += skippy 769 } 770 } 771 772 if iNdEx > l { 773 return io.ErrUnexpectedEOF 774 } 775 return nil 776 } 777 func (m *QueryResult) Unmarshal(dAtA []byte) error { 778 l := len(dAtA) 779 iNdEx := 0 780 for iNdEx < l { 781 preIndex := iNdEx 782 var wire uint64 783 for shift := uint(0); ; shift += 7 { 784 if shift >= 64 { 785 return ErrIntOverflowRemote 786 } 787 if iNdEx >= l { 788 return io.ErrUnexpectedEOF 789 } 790 b := dAtA[iNdEx] 791 iNdEx++ 792 wire |= (uint64(b) & 0x7F) << shift 793 if b < 0x80 { 794 break 795 } 796 } 797 fieldNum := int32(wire >> 3) 798 wireType := int(wire & 0x7) 799 if wireType == 4 { 800 return fmt.Errorf("proto: QueryResult: wiretype end group for non-group") 801 } 802 if fieldNum <= 0 { 803 return fmt.Errorf("proto: QueryResult: illegal tag %d (wire type %d)", fieldNum, wire) 804 } 805 switch fieldNum { 806 case 1: 807 if wireType != 2 { 808 return fmt.Errorf("proto: wrong wireType = %d for field Timeseries", wireType) 809 } 810 var msglen int 811 for shift := uint(0); ; shift += 7 { 812 if shift >= 64 { 813 return ErrIntOverflowRemote 814 } 815 if iNdEx >= l { 816 return io.ErrUnexpectedEOF 817 } 818 b := dAtA[iNdEx] 819 iNdEx++ 820 msglen |= (int(b) & 0x7F) << shift 821 if b < 0x80 { 822 break 823 } 824 } 825 if msglen < 0 { 826 return ErrInvalidLengthRemote 827 } 828 postIndex := iNdEx + msglen 829 if postIndex > l { 830 return io.ErrUnexpectedEOF 831 } 832 m.Timeseries = append(m.Timeseries, &TimeSeries{}) 833 if err := m.Timeseries[len(m.Timeseries)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { 834 return err 835 } 836 iNdEx = postIndex 837 default: 838 iNdEx = preIndex 839 skippy, err := skipRemote(dAtA[iNdEx:]) 840 if err != nil { 841 return err 842 } 843 if skippy < 0 { 844 return ErrInvalidLengthRemote 845 } 846 if (iNdEx + skippy) > l { 847 return io.ErrUnexpectedEOF 848 } 849 iNdEx += skippy 850 } 851 } 852 853 if iNdEx > l { 854 return io.ErrUnexpectedEOF 855 } 856 return nil 857 } 858 func skipRemote(dAtA []byte) (n int, err error) { 859 l := len(dAtA) 860 iNdEx := 0 861 for iNdEx < l { 862 var wire uint64 863 for shift := uint(0); ; shift += 7 { 864 if shift >= 64 { 865 return 0, ErrIntOverflowRemote 866 } 867 if iNdEx >= l { 868 return 0, io.ErrUnexpectedEOF 869 } 870 b := dAtA[iNdEx] 871 iNdEx++ 872 wire |= (uint64(b) & 0x7F) << shift 873 if b < 0x80 { 874 break 875 } 876 } 877 wireType := int(wire & 0x7) 878 switch wireType { 879 case 0: 880 for shift := uint(0); ; shift += 7 { 881 if shift >= 64 { 882 return 0, ErrIntOverflowRemote 883 } 884 if iNdEx >= l { 885 return 0, io.ErrUnexpectedEOF 886 } 887 iNdEx++ 888 if dAtA[iNdEx-1] < 0x80 { 889 break 890 } 891 } 892 return iNdEx, nil 893 case 1: 894 iNdEx += 8 895 return iNdEx, nil 896 case 2: 897 var length int 898 for shift := uint(0); ; shift += 7 { 899 if shift >= 64 { 900 return 0, ErrIntOverflowRemote 901 } 902 if iNdEx >= l { 903 return 0, io.ErrUnexpectedEOF 904 } 905 b := dAtA[iNdEx] 906 iNdEx++ 907 length |= (int(b) & 0x7F) << shift 908 if b < 0x80 { 909 break 910 } 911 } 912 iNdEx += length 913 if length < 0 { 914 return 0, ErrInvalidLengthRemote 915 } 916 return iNdEx, nil 917 case 3: 918 for { 919 var innerWire uint64 920 var start int = iNdEx 921 for shift := uint(0); ; shift += 7 { 922 if shift >= 64 { 923 return 0, ErrIntOverflowRemote 924 } 925 if iNdEx >= l { 926 return 0, io.ErrUnexpectedEOF 927 } 928 b := dAtA[iNdEx] 929 iNdEx++ 930 innerWire |= (uint64(b) & 0x7F) << shift 931 if b < 0x80 { 932 break 933 } 934 } 935 innerWireType := int(innerWire & 0x7) 936 if innerWireType == 4 { 937 break 938 } 939 next, err := skipRemote(dAtA[start:]) 940 if err != nil { 941 return 0, err 942 } 943 iNdEx = start + next 944 } 945 return iNdEx, nil 946 case 4: 947 return iNdEx, nil 948 case 5: 949 iNdEx += 4 950 return iNdEx, nil 951 default: 952 return 0, fmt.Errorf("proto: illegal wireType %d", wireType) 953 } 954 } 955 panic("unreachable") 956 } 957 958 var ( 959 ErrInvalidLengthRemote = fmt.Errorf("proto: negative length found during unmarshaling") 960 ErrIntOverflowRemote = fmt.Errorf("proto: integer overflow") 961 ) 962 963 func init() { 964 proto.RegisterFile("github.com/m3db/m3/src/query/generated/proto/prompb/remote.proto", fileDescriptorRemote) 965 } 966 967 var fileDescriptorRemote = []byte{ 968 // 363 bytes of a gzipped FileDescriptorProto 969 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x9c, 0x92, 0xc1, 0x4a, 0xeb, 0x40, 970 0x14, 0x86, 0x9b, 0xdb, 0x7b, 0xdb, 0xcb, 0xb4, 0x48, 0x89, 0x9b, 0xd8, 0x45, 0x94, 0xac, 0xba, 971 0xb0, 0x19, 0x30, 0x20, 0x2e, 0x44, 0xa5, 0x2e, 0xdc, 0x58, 0xc1, 0xb1, 0x20, 0xb8, 0x29, 0x49, 972 0x73, 0x4c, 0x03, 0x9d, 0x4c, 0x3a, 0x73, 0xb2, 0xe8, 0x5b, 0xb8, 0xf3, 0x95, 0xba, 0xf4, 0x09, 973 0x44, 0xea, 0x8b, 0x48, 0x66, 0x88, 0xa6, 0xe0, 0x46, 0x37, 0x21, 0x39, 0xff, 0xf7, 0xff, 0xfc, 974 0x39, 0x33, 0xe4, 0x22, 0x49, 0x71, 0x5e, 0x44, 0xfe, 0x4c, 0x70, 0xca, 0x83, 0x38, 0xa2, 0x3c, 975 0xa0, 0x4a, 0xce, 0xe8, 0xb2, 0x00, 0xb9, 0xa2, 0x09, 0x64, 0x20, 0x43, 0x84, 0x98, 0xe6, 0x52, 976 0xa0, 0x28, 0x9f, 0x3c, 0x8f, 0xa8, 0x04, 0x2e, 0x10, 0x7c, 0x3d, 0xb3, 0xbb, 0x3c, 0x28, 0xc7, 977 0x80, 0x73, 0x28, 0x54, 0xff, 0xfc, 0x37, 0x79, 0xb8, 0xca, 0x41, 0x99, 0xb8, 0xfe, 0xb0, 0x16, 978 0x90, 0x88, 0x44, 0x18, 0x32, 0x2a, 0x1e, 0xf5, 0x97, 0xb1, 0x95, 0x6f, 0x06, 0xf7, 0x6e, 0x48, 979 0xf7, 0x5e, 0xa6, 0x08, 0x0c, 0x96, 0x05, 0x28, 0xb4, 0xcf, 0x08, 0xc1, 0x94, 0x83, 0x02, 0x99, 980 0x82, 0x72, 0xac, 0x83, 0xe6, 0xa0, 0x73, 0xe4, 0xf8, 0xf5, 0x8a, 0xfe, 0x24, 0xe5, 0x70, 0xa7, 981 0xf5, 0xd1, 0xdf, 0xf5, 0xeb, 0x7e, 0x83, 0xd5, 0x1c, 0xde, 0x29, 0xe9, 0x30, 0x08, 0xe3, 0x2a, 982 0x6e, 0x48, 0xda, 0x65, 0xf3, 0xaf, 0xac, 0xdd, 0xed, 0xac, 0xdb, 0xf2, 0xb7, 0x58, 0xc5, 0x78, 983 0x97, 0xa4, 0x6b, 0xdc, 0x2a, 0x17, 0x99, 0x02, 0x3b, 0x20, 0x6d, 0x09, 0xaa, 0x58, 0x60, 0x65, 984 0xdf, 0xfb, 0xce, 0xae, 0x09, 0x56, 0x91, 0xde, 0xb3, 0x45, 0xfe, 0x69, 0xc1, 0x3e, 0x24, 0xb6, 985 0xc2, 0x50, 0xe2, 0x54, 0x17, 0xc4, 0x90, 0xe7, 0x53, 0x5e, 0x26, 0x59, 0x83, 0x26, 0xeb, 0x69, 986 0x65, 0x52, 0x09, 0x63, 0x65, 0x0f, 0x48, 0x0f, 0xb2, 0x78, 0x9b, 0xfd, 0xa3, 0xd9, 0x1d, 0xc8, 987 0xe2, 0x3a, 0x79, 0x4c, 0xfe, 0xf3, 0x10, 0x67, 0x73, 0x90, 0xca, 0x69, 0xea, 0x5e, 0xfd, 0xed, 988 0x5e, 0xd7, 0x61, 0x04, 0x8b, 0xb1, 0x41, 0xd8, 0x27, 0xeb, 0x5d, 0x91, 0x4e, 0xad, 0xb1, 0x7d, 989 0xf2, 0x93, 0x5d, 0xd7, 0xb7, 0x3c, 0x72, 0xd6, 0x1b, 0xd7, 0x7a, 0xd9, 0xb8, 0xd6, 0xdb, 0xc6, 990 0xb5, 0x9e, 0xde, 0xdd, 0xc6, 0x43, 0xcb, 0x5c, 0x85, 0xa8, 0xa5, 0x8f, 0x35, 0xf8, 0x08, 0x00, 991 0x00, 0xff, 0xff, 0x24, 0xf8, 0x63, 0xea, 0x98, 0x02, 0x00, 0x00, 992 }