Debian Codegraph @

envoy/config/endpoint/v3/load_report_vtproto.pb.go

raw
1 //go:build vtprotobuf
2 // +build vtprotobuf
3
4 // Code generated by protoc-gen-go-vtproto. DO NOT EDIT.
5 // source: envoy/config/endpoint/v3/load_report.proto
6
7 package endpointv3
8
9 import (
10 binary "encoding/binary"
11 protohelpers "github.com/planetscale/vtprotobuf/protohelpers"
12 durationpb "github.com/planetscale/vtprotobuf/types/known/durationpb"
13 structpb "github.com/planetscale/vtprotobuf/types/known/structpb"
14 proto "google.golang.org/protobuf/proto"
15 protoimpl "google.golang.org/protobuf/runtime/protoimpl"
16 math "math"
17 )
18
19 const (
20 // Verify that this generated code is sufficiently up-to-date.
21 _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion)
22 // Verify that runtime/protoimpl is sufficiently up-to-date.
23 _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
24 )
25
26 func (m *UpstreamLocalityStats) MarshalVTStrict() (dAtA []byte, err error) {
27 if m == nil {
28 return nil, nil
29 }
30 size := m.SizeVT()
31 dAtA = make([]byte, size)
32 n, err := m.MarshalToSizedBufferVTStrict(dAtA[:size])
33 if err != nil {
34 return nil, err
35 }
36 return dAtA[:n], nil
37 }
38
39 func (m *UpstreamLocalityStats) MarshalToVTStrict(dAtA []byte) (int, error) {
40 size := m.SizeVT()
41 return m.MarshalToSizedBufferVTStrict(dAtA[:size])
42 }
43
44 func (m *UpstreamLocalityStats) MarshalToSizedBufferVTStrict(dAtA []byte) (int, error) {
45 if m == nil {
46 return 0, nil
47 }
48 i := len(dAtA)
49 _ = i
50 var l int
51 _ = l
52 if m.unknownFields != nil {
53 i -= len(m.unknownFields)
54 copy(dAtA[i:], m.unknownFields)
55 }
56 if m.ApplicationUtilization != nil {
57 size, err := m.ApplicationUtilization.MarshalToSizedBufferVTStrict(dAtA[:i])
58 if err != nil {
59 return 0, err
60 }
61 i -= size
62 i = protohelpers.EncodeVarint(dAtA, i, uint64(size))
63 i--
64 dAtA[i] = 0x72
65 }
66 if m.MemUtilization != nil {
67 size, err := m.MemUtilization.MarshalToSizedBufferVTStrict(dAtA[:i])
68 if err != nil {
69 return 0, err
70 }
71 i -= size
72 i = protohelpers.EncodeVarint(dAtA, i, uint64(size))
73 i--
74 dAtA[i] = 0x6a
75 }
76 if m.CpuUtilization != nil {
77 size, err := m.CpuUtilization.MarshalToSizedBufferVTStrict(dAtA[:i])
78 if err != nil {
79 return 0, err
80 }
81 i -= size
82 i = protohelpers.EncodeVarint(dAtA, i, uint64(size))
83 i--
84 dAtA[i] = 0x62
85 }
86 if m.TotalFailConnections != 0 {
87 i = protohelpers.EncodeVarint(dAtA, i, uint64(m.TotalFailConnections))
88 i--
89 dAtA[i] = 0x58
90 }
91 if m.TotalNewConnections != 0 {
92 i = protohelpers.EncodeVarint(dAtA, i, uint64(m.TotalNewConnections))
93 i--
94 dAtA[i] = 0x50
95 }
96 if m.TotalActiveConnections != 0 {
97 i = protohelpers.EncodeVarint(dAtA, i, uint64(m.TotalActiveConnections))
98 i--
99 dAtA[i] = 0x48
100 }
101 if m.TotalIssuedRequests != 0 {
102 i = protohelpers.EncodeVarint(dAtA, i, uint64(m.TotalIssuedRequests))
103 i--
104 dAtA[i] = 0x40
105 }
106 if len(m.UpstreamEndpointStats) > 0 {
107 for iNdEx := len(m.UpstreamEndpointStats) - 1; iNdEx >= 0; iNdEx-- {
108 size, err := m.UpstreamEndpointStats[iNdEx].MarshalToSizedBufferVTStrict(dAtA[:i])
109 if err != nil {
110 return 0, err
111 }
112 i -= size
113 i = protohelpers.EncodeVarint(dAtA, i, uint64(size))
114 i--
115 dAtA[i] = 0x3a
116 }
117 }
118 if m.Priority != 0 {
119 i = protohelpers.EncodeVarint(dAtA, i, uint64(m.Priority))
120 i--
121 dAtA[i] = 0x30
122 }
123 if len(m.LoadMetricStats) > 0 {
124 for iNdEx := len(m.LoadMetricStats) - 1; iNdEx >= 0; iNdEx-- {
125 size, err := m.LoadMetricStats[iNdEx].MarshalToSizedBufferVTStrict(dAtA[:i])
126 if err != nil {
127 return 0, err
128 }
129 i -= size
130 i = protohelpers.EncodeVarint(dAtA, i, uint64(size))
131 i--
132 dAtA[i] = 0x2a
133 }
134 }
135 if m.TotalErrorRequests != 0 {
136 i = protohelpers.EncodeVarint(dAtA, i, uint64(m.TotalErrorRequests))
137 i--
138 dAtA[i] = 0x20
139 }
140 if m.TotalRequestsInProgress != 0 {
141 i = protohelpers.EncodeVarint(dAtA, i, uint64(m.TotalRequestsInProgress))
142 i--
143 dAtA[i] = 0x18
144 }
145 if m.TotalSuccessfulRequests != 0 {
146 i = protohelpers.EncodeVarint(dAtA, i, uint64(m.TotalSuccessfulRequests))
147 i--
148 dAtA[i] = 0x10
149 }
150 if m.Locality != nil {
151 if vtmsg, ok := interface{}(m.Locality).(interface {
152 MarshalToSizedBufferVTStrict([]byte) (int, error)
153 }); ok {
154 size, err := vtmsg.MarshalToSizedBufferVTStrict(dAtA[:i])
155 if err != nil {
156 return 0, err
157 }
158 i -= size
159 i = protohelpers.EncodeVarint(dAtA, i, uint64(size))
160 } else {
161 encoded, err := proto.Marshal(m.Locality)
162 if err != nil {
163 return 0, err
164 }
165 i -= len(encoded)
166 copy(dAtA[i:], encoded)
167 i = protohelpers.EncodeVarint(dAtA, i, uint64(len(encoded)))
168 }
169 i--
170 dAtA[i] = 0xa
171 }
172 return len(dAtA) - i, nil
173 }
174
175 func (m *UpstreamEndpointStats) MarshalVTStrict() (dAtA []byte, err error) {
176 if m == nil {
177 return nil, nil
178 }
179 size := m.SizeVT()
180 dAtA = make([]byte, size)
181 n, err := m.MarshalToSizedBufferVTStrict(dAtA[:size])
182 if err != nil {
183 return nil, err
184 }
185 return dAtA[:n], nil
186 }
187
188 func (m *UpstreamEndpointStats) MarshalToVTStrict(dAtA []byte) (int, error) {
189 size := m.SizeVT()
190 return m.MarshalToSizedBufferVTStrict(dAtA[:size])
191 }
192
193 func (m *UpstreamEndpointStats) MarshalToSizedBufferVTStrict(dAtA []byte) (int, error) {
194 if m == nil {
195 return 0, nil
196 }
197 i := len(dAtA)
198 _ = i
199 var l int
200 _ = l
201 if m.unknownFields != nil {
202 i -= len(m.unknownFields)
203 copy(dAtA[i:], m.unknownFields)
204 }
205 if m.TotalIssuedRequests != 0 {
206 i = protohelpers.EncodeVarint(dAtA, i, uint64(m.TotalIssuedRequests))
207 i--
208 dAtA[i] = 0x38
209 }
210 if m.Metadata != nil {
211 size, err := (*structpb.Struct)(m.Metadata).MarshalToSizedBufferVTStrict(dAtA[:i])
212 if err != nil {
213 return 0, err
214 }
215 i -= size
216 i = protohelpers.EncodeVarint(dAtA, i, uint64(size))
217 i--
218 dAtA[i] = 0x32
219 }
220 if len(m.LoadMetricStats) > 0 {
221 for iNdEx := len(m.LoadMetricStats) - 1; iNdEx >= 0; iNdEx-- {
222 size, err := m.LoadMetricStats[iNdEx].MarshalToSizedBufferVTStrict(dAtA[:i])
223 if err != nil {
224 return 0, err
225 }
226 i -= size
227 i = protohelpers.EncodeVarint(dAtA, i, uint64(size))
228 i--
229 dAtA[i] = 0x2a
230 }
231 }
232 if m.TotalErrorRequests != 0 {
233 i = protohelpers.EncodeVarint(dAtA, i, uint64(m.TotalErrorRequests))
234 i--
235 dAtA[i] = 0x20
236 }
237 if m.TotalRequestsInProgress != 0 {
238 i = protohelpers.EncodeVarint(dAtA, i, uint64(m.TotalRequestsInProgress))
239 i--
240 dAtA[i] = 0x18
241 }
242 if m.TotalSuccessfulRequests != 0 {
243 i = protohelpers.EncodeVarint(dAtA, i, uint64(m.TotalSuccessfulRequests))
244 i--
245 dAtA[i] = 0x10
246 }
247 if m.Address != nil {
248 if vtmsg, ok := interface{}(m.Address).(interface {
249 MarshalToSizedBufferVTStrict([]byte) (int, error)
250 }); ok {
251 size, err := vtmsg.MarshalToSizedBufferVTStrict(dAtA[:i])
252 if err != nil {
253 return 0, err
254 }
255 i -= size
256 i = protohelpers.EncodeVarint(dAtA, i, uint64(size))
257 } else {
258 encoded, err := proto.Marshal(m.Address)
259 if err != nil {
260 return 0, err
261 }
262 i -= len(encoded)
263 copy(dAtA[i:], encoded)
264 i = protohelpers.EncodeVarint(dAtA, i, uint64(len(encoded)))
265 }
266 i--
267 dAtA[i] = 0xa
268 }
269 return len(dAtA) - i, nil
270 }
271
272 func (m *EndpointLoadMetricStats) MarshalVTStrict() (dAtA []byte, err error) {
273 if m == nil {
274 return nil, nil
275 }
276 size := m.SizeVT()
277 dAtA = make([]byte, size)
278 n, err := m.MarshalToSizedBufferVTStrict(dAtA[:size])
279 if err != nil {
280 return nil, err
281 }
282 return dAtA[:n], nil
283 }
284
285 func (m *EndpointLoadMetricStats) MarshalToVTStrict(dAtA []byte) (int, error) {
286 size := m.SizeVT()
287 return m.MarshalToSizedBufferVTStrict(dAtA[:size])
288 }
289
290 func (m *EndpointLoadMetricStats) MarshalToSizedBufferVTStrict(dAtA []byte) (int, error) {
291 if m == nil {
292 return 0, nil
293 }
294 i := len(dAtA)
295 _ = i
296 var l int
297 _ = l
298 if m.unknownFields != nil {
299 i -= len(m.unknownFields)
300 copy(dAtA[i:], m.unknownFields)
301 }
302 if m.TotalMetricValue != 0 {
303 i -= 8
304 binary.LittleEndian.PutUint64(dAtA[i:], uint64(math.Float64bits(float64(m.TotalMetricValue))))
305 i--
306 dAtA[i] = 0x19
307 }
308 if m.NumRequestsFinishedWithMetric != 0 {
309 i = protohelpers.EncodeVarint(dAtA, i, uint64(m.NumRequestsFinishedWithMetric))
310 i--
311 dAtA[i] = 0x10
312 }
313 if len(m.MetricName) > 0 {
314 i -= len(m.MetricName)
315 copy(dAtA[i:], m.MetricName)
316 i = protohelpers.EncodeVarint(dAtA, i, uint64(len(m.MetricName)))
317 i--
318 dAtA[i] = 0xa
319 }
320 return len(dAtA) - i, nil
321 }
322
323 func (m *UnnamedEndpointLoadMetricStats) MarshalVTStrict() (dAtA []byte, err error) {
324 if m == nil {
325 return nil, nil
326 }
327 size := m.SizeVT()
328 dAtA = make([]byte, size)
329 n, err := m.MarshalToSizedBufferVTStrict(dAtA[:size])
330 if err != nil {
331 return nil, err
332 }
333 return dAtA[:n], nil
334 }
335
336 func (m *UnnamedEndpointLoadMetricStats) MarshalToVTStrict(dAtA []byte) (int, error) {
337 size := m.SizeVT()
338 return m.MarshalToSizedBufferVTStrict(dAtA[:size])
339 }
340
341 func (m *UnnamedEndpointLoadMetricStats) MarshalToSizedBufferVTStrict(dAtA []byte) (int, error) {
342 if m == nil {
343 return 0, nil
344 }
345 i := len(dAtA)
346 _ = i
347 var l int
348 _ = l
349 if m.unknownFields != nil {
350 i -= len(m.unknownFields)
351 copy(dAtA[i:], m.unknownFields)
352 }
353 if m.TotalMetricValue != 0 {
354 i -= 8
355 binary.LittleEndian.PutUint64(dAtA[i:], uint64(math.Float64bits(float64(m.TotalMetricValue))))
356 i--
357 dAtA[i] = 0x11
358 }
359 if m.NumRequestsFinishedWithMetric != 0 {
360 i = protohelpers.EncodeVarint(dAtA, i, uint64(m.NumRequestsFinishedWithMetric))
361 i--
362 dAtA[i] = 0x8
363 }
364 return len(dAtA) - i, nil
365 }
366
367 func (m *ClusterStats_DroppedRequests) MarshalVTStrict() (dAtA []byte, err error) {
368 if m == nil {
369 return nil, nil
370 }
371 size := m.SizeVT()
372 dAtA = make([]byte, size)
373 n, err := m.MarshalToSizedBufferVTStrict(dAtA[:size])
374 if err != nil {
375 return nil, err
376 }
377 return dAtA[:n], nil
378 }
379
380 func (m *ClusterStats_DroppedRequests) MarshalToVTStrict(dAtA []byte) (int, error) {
381 size := m.SizeVT()
382 return m.MarshalToSizedBufferVTStrict(dAtA[:size])
383 }
384
385 func (m *ClusterStats_DroppedRequests) MarshalToSizedBufferVTStrict(dAtA []byte) (int, error) {
386 if m == nil {
387 return 0, nil
388 }
389 i := len(dAtA)
390 _ = i
391 var l int
392 _ = l
393 if m.unknownFields != nil {
394 i -= len(m.unknownFields)
395 copy(dAtA[i:], m.unknownFields)
396 }
397 if m.DroppedCount != 0 {
398 i = protohelpers.EncodeVarint(dAtA, i, uint64(m.DroppedCount))
399 i--
400 dAtA[i] = 0x10
401 }
402 if len(m.Category) > 0 {
403 i -= len(m.Category)
404 copy(dAtA[i:], m.Category)
405 i = protohelpers.EncodeVarint(dAtA, i, uint64(len(m.Category)))
406 i--
407 dAtA[i] = 0xa
408 }
409 return len(dAtA) - i, nil
410 }
411
412 func (m *ClusterStats) MarshalVTStrict() (dAtA []byte, err error) {
413 if m == nil {
414 return nil, nil
415 }
416 size := m.SizeVT()
417 dAtA = make([]byte, size)
418 n, err := m.MarshalToSizedBufferVTStrict(dAtA[:size])
419 if err != nil {
420 return nil, err
421 }
422 return dAtA[:n], nil
423 }
424
425 func (m *ClusterStats) MarshalToVTStrict(dAtA []byte) (int, error) {
426 size := m.SizeVT()
427 return m.MarshalToSizedBufferVTStrict(dAtA[:size])
428 }
429
430 func (m *ClusterStats) MarshalToSizedBufferVTStrict(dAtA []byte) (int, error) {
431 if m == nil {
432 return 0, nil
433 }
434 i := len(dAtA)
435 _ = i
436 var l int
437 _ = l
438 if m.unknownFields != nil {
439 i -= len(m.unknownFields)
440 copy(dAtA[i:], m.unknownFields)
441 }
442 if len(m.ClusterServiceName) > 0 {
443 i -= len(m.ClusterServiceName)
444 copy(dAtA[i:], m.ClusterServiceName)
445 i = protohelpers.EncodeVarint(dAtA, i, uint64(len(m.ClusterServiceName)))
446 i--
447 dAtA[i] = 0x32
448 }
449 if len(m.DroppedRequests) > 0 {
450 for iNdEx := len(m.DroppedRequests) - 1; iNdEx >= 0; iNdEx-- {
451 size, err := m.DroppedRequests[iNdEx].MarshalToSizedBufferVTStrict(dAtA[:i])
452 if err != nil {
453 return 0, err
454 }
455 i -= size
456 i = protohelpers.EncodeVarint(dAtA, i, uint64(size))
457 i--
458 dAtA[i] = 0x2a
459 }
460 }
461 if m.LoadReportInterval != nil {
462 size, err := (*durationpb.Duration)(m.LoadReportInterval).MarshalToSizedBufferVTStrict(dAtA[:i])
463 if err != nil {
464 return 0, err
465 }
466 i -= size
467 i = protohelpers.EncodeVarint(dAtA, i, uint64(size))
468 i--
469 dAtA[i] = 0x22
470 }
471 if m.TotalDroppedRequests != 0 {
472 i = protohelpers.EncodeVarint(dAtA, i, uint64(m.TotalDroppedRequests))
473 i--
474 dAtA[i] = 0x18
475 }
476 if len(m.UpstreamLocalityStats) > 0 {
477 for iNdEx := len(m.UpstreamLocalityStats) - 1; iNdEx >= 0; iNdEx-- {
478 size, err := m.UpstreamLocalityStats[iNdEx].MarshalToSizedBufferVTStrict(dAtA[:i])
479 if err != nil {
480 return 0, err
481 }
482 i -= size
483 i = protohelpers.EncodeVarint(dAtA, i, uint64(size))
484 i--
485 dAtA[i] = 0x12
486 }
487 }
488 if len(m.ClusterName) > 0 {
489 i -= len(m.ClusterName)
490 copy(dAtA[i:], m.ClusterName)
491 i = protohelpers.EncodeVarint(dAtA, i, uint64(len(m.ClusterName)))
492 i--
493 dAtA[i] = 0xa
494 }
495 return len(dAtA) - i, nil
496 }
497
498 func (m *UpstreamLocalityStats) SizeVT() (n int) {
499 if m == nil {
500 return 0
501 }
502 var l int
503 _ = l
504 if m.Locality != nil {
505 if size, ok := interface{}(m.Locality).(interface {
506 SizeVT() int
507 }); ok {
508 l = size.SizeVT()
509 } else {
510 l = proto.Size(m.Locality)
511 }
512 n += 1 + l + protohelpers.SizeOfVarint(uint64(l))
513 }
514 if m.TotalSuccessfulRequests != 0 {
515 n += 1 + protohelpers.SizeOfVarint(uint64(m.TotalSuccessfulRequests))
516 }
517 if m.TotalRequestsInProgress != 0 {
518 n += 1 + protohelpers.SizeOfVarint(uint64(m.TotalRequestsInProgress))
519 }
520 if m.TotalErrorRequests != 0 {
521 n += 1 + protohelpers.SizeOfVarint(uint64(m.TotalErrorRequests))
522 }
523 if len(m.LoadMetricStats) > 0 {
524 for _, e := range m.LoadMetricStats {
525 l = e.SizeVT()
526 n += 1 + l + protohelpers.SizeOfVarint(uint64(l))
527 }
528 }
529 if m.Priority != 0 {
530 n += 1 + protohelpers.SizeOfVarint(uint64(m.Priority))
531 }
532 if len(m.UpstreamEndpointStats) > 0 {
533 for _, e := range m.UpstreamEndpointStats {
534 l = e.SizeVT()
535 n += 1 + l + protohelpers.SizeOfVarint(uint64(l))
536 }
537 }
538 if m.TotalIssuedRequests != 0 {
539 n += 1 + protohelpers.SizeOfVarint(uint64(m.TotalIssuedRequests))
540 }
541 if m.TotalActiveConnections != 0 {
542 n += 1 + protohelpers.SizeOfVarint(uint64(m.TotalActiveConnections))
543 }
544 if m.TotalNewConnections != 0 {
545 n += 1 + protohelpers.SizeOfVarint(uint64(m.TotalNewConnections))
546 }
547 if m.TotalFailConnections != 0 {
548 n += 1 + protohelpers.SizeOfVarint(uint64(m.TotalFailConnections))
549 }
550 if m.CpuUtilization != nil {
551 l = m.CpuUtilization.SizeVT()
552 n += 1 + l + protohelpers.SizeOfVarint(uint64(l))
553 }
554 if m.MemUtilization != nil {
555 l = m.MemUtilization.SizeVT()
556 n += 1 + l + protohelpers.SizeOfVarint(uint64(l))
557 }
558 if m.ApplicationUtilization != nil {
559 l = m.ApplicationUtilization.SizeVT()
560 n += 1 + l + protohelpers.SizeOfVarint(uint64(l))
561 }
562 n += len(m.unknownFields)
563 return n
564 }
565
566 func (m *UpstreamEndpointStats) SizeVT() (n int) {
567 if m == nil {
568 return 0
569 }
570 var l int
571 _ = l
572 if m.Address != nil {
573 if size, ok := interface{}(m.Address).(interface {
574 SizeVT() int
575 }); ok {
576 l = size.SizeVT()
577 } else {
578 l = proto.Size(m.Address)
579 }
580 n += 1 + l + protohelpers.SizeOfVarint(uint64(l))
581 }
582 if m.TotalSuccessfulRequests != 0 {
583 n += 1 + protohelpers.SizeOfVarint(uint64(m.TotalSuccessfulRequests))
584 }
585 if m.TotalRequestsInProgress != 0 {
586 n += 1 + protohelpers.SizeOfVarint(uint64(m.TotalRequestsInProgress))
587 }
588 if m.TotalErrorRequests != 0 {
589 n += 1 + protohelpers.SizeOfVarint(uint64(m.TotalErrorRequests))
590 }
591 if len(m.LoadMetricStats) > 0 {
592 for _, e := range m.LoadMetricStats {
593 l = e.SizeVT()
594 n += 1 + l + protohelpers.SizeOfVarint(uint64(l))
595 }
596 }
597 if m.Metadata != nil {
598 l = (*structpb.Struct)(m.Metadata).SizeVT()
599 n += 1 + l + protohelpers.SizeOfVarint(uint64(l))
600 }
601 if m.TotalIssuedRequests != 0 {
602 n += 1 + protohelpers.SizeOfVarint(uint64(m.TotalIssuedRequests))
603 }
604 n += len(m.unknownFields)
605 return n
606 }
607
608 func (m *EndpointLoadMetricStats) SizeVT() (n int) {
609 if m == nil {
610 return 0
611 }
612 var l int
613 _ = l
614 l = len(m.MetricName)
615 if l > 0 {
616 n += 1 + l + protohelpers.SizeOfVarint(uint64(l))
617 }
618 if m.NumRequestsFinishedWithMetric != 0 {
619 n += 1 + protohelpers.SizeOfVarint(uint64(m.NumRequestsFinishedWithMetric))
620 }
621 if m.TotalMetricValue != 0 {
622 n += 9
623 }
624 n += len(m.unknownFields)
625 return n
626 }
627
628 func (m *UnnamedEndpointLoadMetricStats) SizeVT() (n int) {
629 if m == nil {
630 return 0
631 }
632 var l int
633 _ = l
634 if m.NumRequestsFinishedWithMetric != 0 {
635 n += 1 + protohelpers.SizeOfVarint(uint64(m.NumRequestsFinishedWithMetric))
636 }
637 if m.TotalMetricValue != 0 {
638 n += 9
639 }
640 n += len(m.unknownFields)
641 return n
642 }
643
644 func (m *ClusterStats_DroppedRequests) SizeVT() (n int) {
645 if m == nil {
646 return 0
647 }
648 var l int
649 _ = l
650 l = len(m.Category)
651 if l > 0 {
652 n += 1 + l + protohelpers.SizeOfVarint(uint64(l))
653 }
654 if m.DroppedCount != 0 {
655 n += 1 + protohelpers.SizeOfVarint(uint64(m.DroppedCount))
656 }
657 n += len(m.unknownFields)
658 return n
659 }
660
661 func (m *ClusterStats) SizeVT() (n int) {
662 if m == nil {
663 return 0
664 }
665 var l int
666 _ = l
667 l = len(m.ClusterName)
668 if l > 0 {
669 n += 1 + l + protohelpers.SizeOfVarint(uint64(l))
670 }
671 if len(m.UpstreamLocalityStats) > 0 {
672 for _, e := range m.UpstreamLocalityStats {
673 l = e.SizeVT()
674 n += 1 + l + protohelpers.SizeOfVarint(uint64(l))
675 }
676 }
677 if m.TotalDroppedRequests != 0 {
678 n += 1 + protohelpers.SizeOfVarint(uint64(m.TotalDroppedRequests))
679 }
680 if m.LoadReportInterval != nil {
681 l = (*durationpb.Duration)(m.LoadReportInterval).SizeVT()
682 n += 1 + l + protohelpers.SizeOfVarint(uint64(l))
683 }
684 if len(m.DroppedRequests) > 0 {
685 for _, e := range m.DroppedRequests {
686 l = e.SizeVT()
687 n += 1 + l + protohelpers.SizeOfVarint(uint64(l))
688 }
689 }
690 l = len(m.ClusterServiceName)
691 if l > 0 {
692 n += 1 + l + protohelpers.SizeOfVarint(uint64(l))
693 }
694 n += len(m.unknownFields)
695 return n
696 }