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