forked from grpc/grpc-go
-
Notifications
You must be signed in to change notification settings - Fork 0
/
control.pb.go
1194 lines (1060 loc) · 39.7 KB
/
control.pb.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
// Code generated by protoc-gen-go. DO NOT EDIT.
// source: control.proto
/*
Package grpc_testing is a generated protocol buffer package.
It is generated from these files:
control.proto
messages.proto
payloads.proto
services.proto
stats.proto
It has these top-level messages:
PoissonParams
UniformParams
DeterministicParams
ParetoParams
ClosedLoopParams
LoadParams
SecurityParams
ClientConfig
ClientStatus
Mark
ClientArgs
ServerConfig
ServerArgs
ServerStatus
CoreRequest
CoreResponse
Void
Scenario
Scenarios
Payload
EchoStatus
SimpleRequest
SimpleResponse
StreamingInputCallRequest
StreamingInputCallResponse
ResponseParameters
StreamingOutputCallRequest
StreamingOutputCallResponse
ReconnectParams
ReconnectInfo
ByteBufferParams
SimpleProtoParams
ComplexProtoParams
PayloadConfig
ServerStats
HistogramParams
HistogramData
ClientStats
*/
package grpc_testing
import proto "github.com/golang/protobuf/proto"
import fmt "fmt"
import math "math"
// Reference imports to suppress errors if they are not otherwise used.
var _ = proto.Marshal
var _ = fmt.Errorf
var _ = math.Inf
// This is a compile-time assertion to ensure that this generated file
// is compatible with the proto package it is being compiled against.
// A compilation error at this line likely means your copy of the
// proto package needs to be updated.
const _ = proto.ProtoPackageIsVersion2 // please upgrade the proto package
type ClientType int32
const (
ClientType_SYNC_CLIENT ClientType = 0
ClientType_ASYNC_CLIENT ClientType = 1
)
var ClientType_name = map[int32]string{
0: "SYNC_CLIENT",
1: "ASYNC_CLIENT",
}
var ClientType_value = map[string]int32{
"SYNC_CLIENT": 0,
"ASYNC_CLIENT": 1,
}
func (x ClientType) String() string {
return proto.EnumName(ClientType_name, int32(x))
}
func (ClientType) EnumDescriptor() ([]byte, []int) { return fileDescriptor0, []int{0} }
type ServerType int32
const (
ServerType_SYNC_SERVER ServerType = 0
ServerType_ASYNC_SERVER ServerType = 1
ServerType_ASYNC_GENERIC_SERVER ServerType = 2
)
var ServerType_name = map[int32]string{
0: "SYNC_SERVER",
1: "ASYNC_SERVER",
2: "ASYNC_GENERIC_SERVER",
}
var ServerType_value = map[string]int32{
"SYNC_SERVER": 0,
"ASYNC_SERVER": 1,
"ASYNC_GENERIC_SERVER": 2,
}
func (x ServerType) String() string {
return proto.EnumName(ServerType_name, int32(x))
}
func (ServerType) EnumDescriptor() ([]byte, []int) { return fileDescriptor0, []int{1} }
type RpcType int32
const (
RpcType_UNARY RpcType = 0
RpcType_STREAMING RpcType = 1
)
var RpcType_name = map[int32]string{
0: "UNARY",
1: "STREAMING",
}
var RpcType_value = map[string]int32{
"UNARY": 0,
"STREAMING": 1,
}
func (x RpcType) String() string {
return proto.EnumName(RpcType_name, int32(x))
}
func (RpcType) EnumDescriptor() ([]byte, []int) { return fileDescriptor0, []int{2} }
// Parameters of poisson process distribution, which is a good representation
// of activity coming in from independent identical stationary sources.
type PoissonParams struct {
// The rate of arrivals (a.k.a. lambda parameter of the exp distribution).
OfferedLoad float64 `protobuf:"fixed64,1,opt,name=offered_load,json=offeredLoad" json:"offered_load,omitempty"`
}
func (m *PoissonParams) Reset() { *m = PoissonParams{} }
func (m *PoissonParams) String() string { return proto.CompactTextString(m) }
func (*PoissonParams) ProtoMessage() {}
func (*PoissonParams) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{0} }
func (m *PoissonParams) GetOfferedLoad() float64 {
if m != nil {
return m.OfferedLoad
}
return 0
}
type UniformParams struct {
InterarrivalLo float64 `protobuf:"fixed64,1,opt,name=interarrival_lo,json=interarrivalLo" json:"interarrival_lo,omitempty"`
InterarrivalHi float64 `protobuf:"fixed64,2,opt,name=interarrival_hi,json=interarrivalHi" json:"interarrival_hi,omitempty"`
}
func (m *UniformParams) Reset() { *m = UniformParams{} }
func (m *UniformParams) String() string { return proto.CompactTextString(m) }
func (*UniformParams) ProtoMessage() {}
func (*UniformParams) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{1} }
func (m *UniformParams) GetInterarrivalLo() float64 {
if m != nil {
return m.InterarrivalLo
}
return 0
}
func (m *UniformParams) GetInterarrivalHi() float64 {
if m != nil {
return m.InterarrivalHi
}
return 0
}
type DeterministicParams struct {
OfferedLoad float64 `protobuf:"fixed64,1,opt,name=offered_load,json=offeredLoad" json:"offered_load,omitempty"`
}
func (m *DeterministicParams) Reset() { *m = DeterministicParams{} }
func (m *DeterministicParams) String() string { return proto.CompactTextString(m) }
func (*DeterministicParams) ProtoMessage() {}
func (*DeterministicParams) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{2} }
func (m *DeterministicParams) GetOfferedLoad() float64 {
if m != nil {
return m.OfferedLoad
}
return 0
}
type ParetoParams struct {
InterarrivalBase float64 `protobuf:"fixed64,1,opt,name=interarrival_base,json=interarrivalBase" json:"interarrival_base,omitempty"`
Alpha float64 `protobuf:"fixed64,2,opt,name=alpha" json:"alpha,omitempty"`
}
func (m *ParetoParams) Reset() { *m = ParetoParams{} }
func (m *ParetoParams) String() string { return proto.CompactTextString(m) }
func (*ParetoParams) ProtoMessage() {}
func (*ParetoParams) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{3} }
func (m *ParetoParams) GetInterarrivalBase() float64 {
if m != nil {
return m.InterarrivalBase
}
return 0
}
func (m *ParetoParams) GetAlpha() float64 {
if m != nil {
return m.Alpha
}
return 0
}
// Once an RPC finishes, immediately start a new one.
// No configuration parameters needed.
type ClosedLoopParams struct {
}
func (m *ClosedLoopParams) Reset() { *m = ClosedLoopParams{} }
func (m *ClosedLoopParams) String() string { return proto.CompactTextString(m) }
func (*ClosedLoopParams) ProtoMessage() {}
func (*ClosedLoopParams) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{4} }
type LoadParams struct {
// Types that are valid to be assigned to Load:
// *LoadParams_ClosedLoop
// *LoadParams_Poisson
// *LoadParams_Uniform
// *LoadParams_Determ
// *LoadParams_Pareto
Load isLoadParams_Load `protobuf_oneof:"load"`
}
func (m *LoadParams) Reset() { *m = LoadParams{} }
func (m *LoadParams) String() string { return proto.CompactTextString(m) }
func (*LoadParams) ProtoMessage() {}
func (*LoadParams) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{5} }
type isLoadParams_Load interface {
isLoadParams_Load()
}
type LoadParams_ClosedLoop struct {
ClosedLoop *ClosedLoopParams `protobuf:"bytes,1,opt,name=closed_loop,json=closedLoop,oneof"`
}
type LoadParams_Poisson struct {
Poisson *PoissonParams `protobuf:"bytes,2,opt,name=poisson,oneof"`
}
type LoadParams_Uniform struct {
Uniform *UniformParams `protobuf:"bytes,3,opt,name=uniform,oneof"`
}
type LoadParams_Determ struct {
Determ *DeterministicParams `protobuf:"bytes,4,opt,name=determ,oneof"`
}
type LoadParams_Pareto struct {
Pareto *ParetoParams `protobuf:"bytes,5,opt,name=pareto,oneof"`
}
func (*LoadParams_ClosedLoop) isLoadParams_Load() {}
func (*LoadParams_Poisson) isLoadParams_Load() {}
func (*LoadParams_Uniform) isLoadParams_Load() {}
func (*LoadParams_Determ) isLoadParams_Load() {}
func (*LoadParams_Pareto) isLoadParams_Load() {}
func (m *LoadParams) GetLoad() isLoadParams_Load {
if m != nil {
return m.Load
}
return nil
}
func (m *LoadParams) GetClosedLoop() *ClosedLoopParams {
if x, ok := m.GetLoad().(*LoadParams_ClosedLoop); ok {
return x.ClosedLoop
}
return nil
}
func (m *LoadParams) GetPoisson() *PoissonParams {
if x, ok := m.GetLoad().(*LoadParams_Poisson); ok {
return x.Poisson
}
return nil
}
func (m *LoadParams) GetUniform() *UniformParams {
if x, ok := m.GetLoad().(*LoadParams_Uniform); ok {
return x.Uniform
}
return nil
}
func (m *LoadParams) GetDeterm() *DeterministicParams {
if x, ok := m.GetLoad().(*LoadParams_Determ); ok {
return x.Determ
}
return nil
}
func (m *LoadParams) GetPareto() *ParetoParams {
if x, ok := m.GetLoad().(*LoadParams_Pareto); ok {
return x.Pareto
}
return nil
}
// XXX_OneofFuncs is for the internal use of the proto package.
func (*LoadParams) XXX_OneofFuncs() (func(msg proto.Message, b *proto.Buffer) error, func(msg proto.Message, tag, wire int, b *proto.Buffer) (bool, error), func(msg proto.Message) (n int), []interface{}) {
return _LoadParams_OneofMarshaler, _LoadParams_OneofUnmarshaler, _LoadParams_OneofSizer, []interface{}{
(*LoadParams_ClosedLoop)(nil),
(*LoadParams_Poisson)(nil),
(*LoadParams_Uniform)(nil),
(*LoadParams_Determ)(nil),
(*LoadParams_Pareto)(nil),
}
}
func _LoadParams_OneofMarshaler(msg proto.Message, b *proto.Buffer) error {
m := msg.(*LoadParams)
// load
switch x := m.Load.(type) {
case *LoadParams_ClosedLoop:
b.EncodeVarint(1<<3 | proto.WireBytes)
if err := b.EncodeMessage(x.ClosedLoop); err != nil {
return err
}
case *LoadParams_Poisson:
b.EncodeVarint(2<<3 | proto.WireBytes)
if err := b.EncodeMessage(x.Poisson); err != nil {
return err
}
case *LoadParams_Uniform:
b.EncodeVarint(3<<3 | proto.WireBytes)
if err := b.EncodeMessage(x.Uniform); err != nil {
return err
}
case *LoadParams_Determ:
b.EncodeVarint(4<<3 | proto.WireBytes)
if err := b.EncodeMessage(x.Determ); err != nil {
return err
}
case *LoadParams_Pareto:
b.EncodeVarint(5<<3 | proto.WireBytes)
if err := b.EncodeMessage(x.Pareto); err != nil {
return err
}
case nil:
default:
return fmt.Errorf("LoadParams.Load has unexpected type %T", x)
}
return nil
}
func _LoadParams_OneofUnmarshaler(msg proto.Message, tag, wire int, b *proto.Buffer) (bool, error) {
m := msg.(*LoadParams)
switch tag {
case 1: // load.closed_loop
if wire != proto.WireBytes {
return true, proto.ErrInternalBadWireType
}
msg := new(ClosedLoopParams)
err := b.DecodeMessage(msg)
m.Load = &LoadParams_ClosedLoop{msg}
return true, err
case 2: // load.poisson
if wire != proto.WireBytes {
return true, proto.ErrInternalBadWireType
}
msg := new(PoissonParams)
err := b.DecodeMessage(msg)
m.Load = &LoadParams_Poisson{msg}
return true, err
case 3: // load.uniform
if wire != proto.WireBytes {
return true, proto.ErrInternalBadWireType
}
msg := new(UniformParams)
err := b.DecodeMessage(msg)
m.Load = &LoadParams_Uniform{msg}
return true, err
case 4: // load.determ
if wire != proto.WireBytes {
return true, proto.ErrInternalBadWireType
}
msg := new(DeterministicParams)
err := b.DecodeMessage(msg)
m.Load = &LoadParams_Determ{msg}
return true, err
case 5: // load.pareto
if wire != proto.WireBytes {
return true, proto.ErrInternalBadWireType
}
msg := new(ParetoParams)
err := b.DecodeMessage(msg)
m.Load = &LoadParams_Pareto{msg}
return true, err
default:
return false, nil
}
}
func _LoadParams_OneofSizer(msg proto.Message) (n int) {
m := msg.(*LoadParams)
// load
switch x := m.Load.(type) {
case *LoadParams_ClosedLoop:
s := proto.Size(x.ClosedLoop)
n += proto.SizeVarint(1<<3 | proto.WireBytes)
n += proto.SizeVarint(uint64(s))
n += s
case *LoadParams_Poisson:
s := proto.Size(x.Poisson)
n += proto.SizeVarint(2<<3 | proto.WireBytes)
n += proto.SizeVarint(uint64(s))
n += s
case *LoadParams_Uniform:
s := proto.Size(x.Uniform)
n += proto.SizeVarint(3<<3 | proto.WireBytes)
n += proto.SizeVarint(uint64(s))
n += s
case *LoadParams_Determ:
s := proto.Size(x.Determ)
n += proto.SizeVarint(4<<3 | proto.WireBytes)
n += proto.SizeVarint(uint64(s))
n += s
case *LoadParams_Pareto:
s := proto.Size(x.Pareto)
n += proto.SizeVarint(5<<3 | proto.WireBytes)
n += proto.SizeVarint(uint64(s))
n += s
case nil:
default:
panic(fmt.Sprintf("proto: unexpected type %T in oneof", x))
}
return n
}
// presence of SecurityParams implies use of TLS
type SecurityParams struct {
UseTestCa bool `protobuf:"varint,1,opt,name=use_test_ca,json=useTestCa" json:"use_test_ca,omitempty"`
ServerHostOverride string `protobuf:"bytes,2,opt,name=server_host_override,json=serverHostOverride" json:"server_host_override,omitempty"`
}
func (m *SecurityParams) Reset() { *m = SecurityParams{} }
func (m *SecurityParams) String() string { return proto.CompactTextString(m) }
func (*SecurityParams) ProtoMessage() {}
func (*SecurityParams) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{6} }
func (m *SecurityParams) GetUseTestCa() bool {
if m != nil {
return m.UseTestCa
}
return false
}
func (m *SecurityParams) GetServerHostOverride() string {
if m != nil {
return m.ServerHostOverride
}
return ""
}
type ClientConfig struct {
// List of targets to connect to. At least one target needs to be specified.
ServerTargets []string `protobuf:"bytes,1,rep,name=server_targets,json=serverTargets" json:"server_targets,omitempty"`
ClientType ClientType `protobuf:"varint,2,opt,name=client_type,json=clientType,enum=grpc.testing.ClientType" json:"client_type,omitempty"`
SecurityParams *SecurityParams `protobuf:"bytes,3,opt,name=security_params,json=securityParams" json:"security_params,omitempty"`
// How many concurrent RPCs to start for each channel.
// For synchronous client, use a separate thread for each outstanding RPC.
OutstandingRpcsPerChannel int32 `protobuf:"varint,4,opt,name=outstanding_rpcs_per_channel,json=outstandingRpcsPerChannel" json:"outstanding_rpcs_per_channel,omitempty"`
// Number of independent client channels to create.
// i-th channel will connect to server_target[i % server_targets.size()]
ClientChannels int32 `protobuf:"varint,5,opt,name=client_channels,json=clientChannels" json:"client_channels,omitempty"`
// Only for async client. Number of threads to use to start/manage RPCs.
AsyncClientThreads int32 `protobuf:"varint,7,opt,name=async_client_threads,json=asyncClientThreads" json:"async_client_threads,omitempty"`
RpcType RpcType `protobuf:"varint,8,opt,name=rpc_type,json=rpcType,enum=grpc.testing.RpcType" json:"rpc_type,omitempty"`
// The requested load for the entire client (aggregated over all the threads).
LoadParams *LoadParams `protobuf:"bytes,10,opt,name=load_params,json=loadParams" json:"load_params,omitempty"`
PayloadConfig *PayloadConfig `protobuf:"bytes,11,opt,name=payload_config,json=payloadConfig" json:"payload_config,omitempty"`
HistogramParams *HistogramParams `protobuf:"bytes,12,opt,name=histogram_params,json=histogramParams" json:"histogram_params,omitempty"`
// Specify the cores we should run the client on, if desired
CoreList []int32 `protobuf:"varint,13,rep,packed,name=core_list,json=coreList" json:"core_list,omitempty"`
CoreLimit int32 `protobuf:"varint,14,opt,name=core_limit,json=coreLimit" json:"core_limit,omitempty"`
}
func (m *ClientConfig) Reset() { *m = ClientConfig{} }
func (m *ClientConfig) String() string { return proto.CompactTextString(m) }
func (*ClientConfig) ProtoMessage() {}
func (*ClientConfig) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{7} }
func (m *ClientConfig) GetServerTargets() []string {
if m != nil {
return m.ServerTargets
}
return nil
}
func (m *ClientConfig) GetClientType() ClientType {
if m != nil {
return m.ClientType
}
return ClientType_SYNC_CLIENT
}
func (m *ClientConfig) GetSecurityParams() *SecurityParams {
if m != nil {
return m.SecurityParams
}
return nil
}
func (m *ClientConfig) GetOutstandingRpcsPerChannel() int32 {
if m != nil {
return m.OutstandingRpcsPerChannel
}
return 0
}
func (m *ClientConfig) GetClientChannels() int32 {
if m != nil {
return m.ClientChannels
}
return 0
}
func (m *ClientConfig) GetAsyncClientThreads() int32 {
if m != nil {
return m.AsyncClientThreads
}
return 0
}
func (m *ClientConfig) GetRpcType() RpcType {
if m != nil {
return m.RpcType
}
return RpcType_UNARY
}
func (m *ClientConfig) GetLoadParams() *LoadParams {
if m != nil {
return m.LoadParams
}
return nil
}
func (m *ClientConfig) GetPayloadConfig() *PayloadConfig {
if m != nil {
return m.PayloadConfig
}
return nil
}
func (m *ClientConfig) GetHistogramParams() *HistogramParams {
if m != nil {
return m.HistogramParams
}
return nil
}
func (m *ClientConfig) GetCoreList() []int32 {
if m != nil {
return m.CoreList
}
return nil
}
func (m *ClientConfig) GetCoreLimit() int32 {
if m != nil {
return m.CoreLimit
}
return 0
}
type ClientStatus struct {
Stats *ClientStats `protobuf:"bytes,1,opt,name=stats" json:"stats,omitempty"`
}
func (m *ClientStatus) Reset() { *m = ClientStatus{} }
func (m *ClientStatus) String() string { return proto.CompactTextString(m) }
func (*ClientStatus) ProtoMessage() {}
func (*ClientStatus) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{8} }
func (m *ClientStatus) GetStats() *ClientStats {
if m != nil {
return m.Stats
}
return nil
}
// Request current stats
type Mark struct {
// if true, the stats will be reset after taking their snapshot.
Reset_ bool `protobuf:"varint,1,opt,name=reset" json:"reset,omitempty"`
}
func (m *Mark) Reset() { *m = Mark{} }
func (m *Mark) String() string { return proto.CompactTextString(m) }
func (*Mark) ProtoMessage() {}
func (*Mark) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{9} }
func (m *Mark) GetReset_() bool {
if m != nil {
return m.Reset_
}
return false
}
type ClientArgs struct {
// Types that are valid to be assigned to Argtype:
// *ClientArgs_Setup
// *ClientArgs_Mark
Argtype isClientArgs_Argtype `protobuf_oneof:"argtype"`
}
func (m *ClientArgs) Reset() { *m = ClientArgs{} }
func (m *ClientArgs) String() string { return proto.CompactTextString(m) }
func (*ClientArgs) ProtoMessage() {}
func (*ClientArgs) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{10} }
type isClientArgs_Argtype interface {
isClientArgs_Argtype()
}
type ClientArgs_Setup struct {
Setup *ClientConfig `protobuf:"bytes,1,opt,name=setup,oneof"`
}
type ClientArgs_Mark struct {
Mark *Mark `protobuf:"bytes,2,opt,name=mark,oneof"`
}
func (*ClientArgs_Setup) isClientArgs_Argtype() {}
func (*ClientArgs_Mark) isClientArgs_Argtype() {}
func (m *ClientArgs) GetArgtype() isClientArgs_Argtype {
if m != nil {
return m.Argtype
}
return nil
}
func (m *ClientArgs) GetSetup() *ClientConfig {
if x, ok := m.GetArgtype().(*ClientArgs_Setup); ok {
return x.Setup
}
return nil
}
func (m *ClientArgs) GetMark() *Mark {
if x, ok := m.GetArgtype().(*ClientArgs_Mark); ok {
return x.Mark
}
return nil
}
// XXX_OneofFuncs is for the internal use of the proto package.
func (*ClientArgs) XXX_OneofFuncs() (func(msg proto.Message, b *proto.Buffer) error, func(msg proto.Message, tag, wire int, b *proto.Buffer) (bool, error), func(msg proto.Message) (n int), []interface{}) {
return _ClientArgs_OneofMarshaler, _ClientArgs_OneofUnmarshaler, _ClientArgs_OneofSizer, []interface{}{
(*ClientArgs_Setup)(nil),
(*ClientArgs_Mark)(nil),
}
}
func _ClientArgs_OneofMarshaler(msg proto.Message, b *proto.Buffer) error {
m := msg.(*ClientArgs)
// argtype
switch x := m.Argtype.(type) {
case *ClientArgs_Setup:
b.EncodeVarint(1<<3 | proto.WireBytes)
if err := b.EncodeMessage(x.Setup); err != nil {
return err
}
case *ClientArgs_Mark:
b.EncodeVarint(2<<3 | proto.WireBytes)
if err := b.EncodeMessage(x.Mark); err != nil {
return err
}
case nil:
default:
return fmt.Errorf("ClientArgs.Argtype has unexpected type %T", x)
}
return nil
}
func _ClientArgs_OneofUnmarshaler(msg proto.Message, tag, wire int, b *proto.Buffer) (bool, error) {
m := msg.(*ClientArgs)
switch tag {
case 1: // argtype.setup
if wire != proto.WireBytes {
return true, proto.ErrInternalBadWireType
}
msg := new(ClientConfig)
err := b.DecodeMessage(msg)
m.Argtype = &ClientArgs_Setup{msg}
return true, err
case 2: // argtype.mark
if wire != proto.WireBytes {
return true, proto.ErrInternalBadWireType
}
msg := new(Mark)
err := b.DecodeMessage(msg)
m.Argtype = &ClientArgs_Mark{msg}
return true, err
default:
return false, nil
}
}
func _ClientArgs_OneofSizer(msg proto.Message) (n int) {
m := msg.(*ClientArgs)
// argtype
switch x := m.Argtype.(type) {
case *ClientArgs_Setup:
s := proto.Size(x.Setup)
n += proto.SizeVarint(1<<3 | proto.WireBytes)
n += proto.SizeVarint(uint64(s))
n += s
case *ClientArgs_Mark:
s := proto.Size(x.Mark)
n += proto.SizeVarint(2<<3 | proto.WireBytes)
n += proto.SizeVarint(uint64(s))
n += s
case nil:
default:
panic(fmt.Sprintf("proto: unexpected type %T in oneof", x))
}
return n
}
type ServerConfig struct {
ServerType ServerType `protobuf:"varint,1,opt,name=server_type,json=serverType,enum=grpc.testing.ServerType" json:"server_type,omitempty"`
SecurityParams *SecurityParams `protobuf:"bytes,2,opt,name=security_params,json=securityParams" json:"security_params,omitempty"`
// Port on which to listen. Zero means pick unused port.
Port int32 `protobuf:"varint,4,opt,name=port" json:"port,omitempty"`
// Only for async server. Number of threads used to serve the requests.
AsyncServerThreads int32 `protobuf:"varint,7,opt,name=async_server_threads,json=asyncServerThreads" json:"async_server_threads,omitempty"`
// Specify the number of cores to limit server to, if desired
CoreLimit int32 `protobuf:"varint,8,opt,name=core_limit,json=coreLimit" json:"core_limit,omitempty"`
// payload config, used in generic server
PayloadConfig *PayloadConfig `protobuf:"bytes,9,opt,name=payload_config,json=payloadConfig" json:"payload_config,omitempty"`
// Specify the cores we should run the server on, if desired
CoreList []int32 `protobuf:"varint,10,rep,packed,name=core_list,json=coreList" json:"core_list,omitempty"`
}
func (m *ServerConfig) Reset() { *m = ServerConfig{} }
func (m *ServerConfig) String() string { return proto.CompactTextString(m) }
func (*ServerConfig) ProtoMessage() {}
func (*ServerConfig) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{11} }
func (m *ServerConfig) GetServerType() ServerType {
if m != nil {
return m.ServerType
}
return ServerType_SYNC_SERVER
}
func (m *ServerConfig) GetSecurityParams() *SecurityParams {
if m != nil {
return m.SecurityParams
}
return nil
}
func (m *ServerConfig) GetPort() int32 {
if m != nil {
return m.Port
}
return 0
}
func (m *ServerConfig) GetAsyncServerThreads() int32 {
if m != nil {
return m.AsyncServerThreads
}
return 0
}
func (m *ServerConfig) GetCoreLimit() int32 {
if m != nil {
return m.CoreLimit
}
return 0
}
func (m *ServerConfig) GetPayloadConfig() *PayloadConfig {
if m != nil {
return m.PayloadConfig
}
return nil
}
func (m *ServerConfig) GetCoreList() []int32 {
if m != nil {
return m.CoreList
}
return nil
}
type ServerArgs struct {
// Types that are valid to be assigned to Argtype:
// *ServerArgs_Setup
// *ServerArgs_Mark
Argtype isServerArgs_Argtype `protobuf_oneof:"argtype"`
}
func (m *ServerArgs) Reset() { *m = ServerArgs{} }
func (m *ServerArgs) String() string { return proto.CompactTextString(m) }
func (*ServerArgs) ProtoMessage() {}
func (*ServerArgs) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{12} }
type isServerArgs_Argtype interface {
isServerArgs_Argtype()
}
type ServerArgs_Setup struct {
Setup *ServerConfig `protobuf:"bytes,1,opt,name=setup,oneof"`
}
type ServerArgs_Mark struct {
Mark *Mark `protobuf:"bytes,2,opt,name=mark,oneof"`
}
func (*ServerArgs_Setup) isServerArgs_Argtype() {}
func (*ServerArgs_Mark) isServerArgs_Argtype() {}
func (m *ServerArgs) GetArgtype() isServerArgs_Argtype {
if m != nil {
return m.Argtype
}
return nil
}
func (m *ServerArgs) GetSetup() *ServerConfig {
if x, ok := m.GetArgtype().(*ServerArgs_Setup); ok {
return x.Setup
}
return nil
}
func (m *ServerArgs) GetMark() *Mark {
if x, ok := m.GetArgtype().(*ServerArgs_Mark); ok {
return x.Mark
}
return nil
}
// XXX_OneofFuncs is for the internal use of the proto package.
func (*ServerArgs) XXX_OneofFuncs() (func(msg proto.Message, b *proto.Buffer) error, func(msg proto.Message, tag, wire int, b *proto.Buffer) (bool, error), func(msg proto.Message) (n int), []interface{}) {
return _ServerArgs_OneofMarshaler, _ServerArgs_OneofUnmarshaler, _ServerArgs_OneofSizer, []interface{}{
(*ServerArgs_Setup)(nil),
(*ServerArgs_Mark)(nil),
}
}
func _ServerArgs_OneofMarshaler(msg proto.Message, b *proto.Buffer) error {
m := msg.(*ServerArgs)
// argtype
switch x := m.Argtype.(type) {
case *ServerArgs_Setup:
b.EncodeVarint(1<<3 | proto.WireBytes)
if err := b.EncodeMessage(x.Setup); err != nil {
return err
}
case *ServerArgs_Mark:
b.EncodeVarint(2<<3 | proto.WireBytes)
if err := b.EncodeMessage(x.Mark); err != nil {
return err
}
case nil:
default:
return fmt.Errorf("ServerArgs.Argtype has unexpected type %T", x)
}
return nil
}
func _ServerArgs_OneofUnmarshaler(msg proto.Message, tag, wire int, b *proto.Buffer) (bool, error) {
m := msg.(*ServerArgs)
switch tag {
case 1: // argtype.setup
if wire != proto.WireBytes {
return true, proto.ErrInternalBadWireType
}
msg := new(ServerConfig)
err := b.DecodeMessage(msg)
m.Argtype = &ServerArgs_Setup{msg}
return true, err
case 2: // argtype.mark
if wire != proto.WireBytes {
return true, proto.ErrInternalBadWireType
}
msg := new(Mark)
err := b.DecodeMessage(msg)
m.Argtype = &ServerArgs_Mark{msg}
return true, err
default:
return false, nil
}
}
func _ServerArgs_OneofSizer(msg proto.Message) (n int) {
m := msg.(*ServerArgs)
// argtype
switch x := m.Argtype.(type) {
case *ServerArgs_Setup:
s := proto.Size(x.Setup)
n += proto.SizeVarint(1<<3 | proto.WireBytes)
n += proto.SizeVarint(uint64(s))
n += s
case *ServerArgs_Mark:
s := proto.Size(x.Mark)
n += proto.SizeVarint(2<<3 | proto.WireBytes)
n += proto.SizeVarint(uint64(s))
n += s
case nil:
default:
panic(fmt.Sprintf("proto: unexpected type %T in oneof", x))
}
return n
}
type ServerStatus struct {
Stats *ServerStats `protobuf:"bytes,1,opt,name=stats" json:"stats,omitempty"`
// the port bound by the server
Port int32 `protobuf:"varint,2,opt,name=port" json:"port,omitempty"`
// Number of cores available to the server
Cores int32 `protobuf:"varint,3,opt,name=cores" json:"cores,omitempty"`
}
func (m *ServerStatus) Reset() { *m = ServerStatus{} }
func (m *ServerStatus) String() string { return proto.CompactTextString(m) }
func (*ServerStatus) ProtoMessage() {}
func (*ServerStatus) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{13} }
func (m *ServerStatus) GetStats() *ServerStats {
if m != nil {
return m.Stats
}
return nil
}
func (m *ServerStatus) GetPort() int32 {
if m != nil {
return m.Port
}
return 0
}
func (m *ServerStatus) GetCores() int32 {
if m != nil {
return m.Cores
}
return 0
}
type CoreRequest struct {
}
func (m *CoreRequest) Reset() { *m = CoreRequest{} }
func (m *CoreRequest) String() string { return proto.CompactTextString(m) }
func (*CoreRequest) ProtoMessage() {}
func (*CoreRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{14} }
type CoreResponse struct {
// Number of cores available on the server
Cores int32 `protobuf:"varint,1,opt,name=cores" json:"cores,omitempty"`
}
func (m *CoreResponse) Reset() { *m = CoreResponse{} }
func (m *CoreResponse) String() string { return proto.CompactTextString(m) }
func (*CoreResponse) ProtoMessage() {}
func (*CoreResponse) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{15} }
func (m *CoreResponse) GetCores() int32 {
if m != nil {
return m.Cores
}
return 0
}
type Void struct {
}
func (m *Void) Reset() { *m = Void{} }
func (m *Void) String() string { return proto.CompactTextString(m) }
func (*Void) ProtoMessage() {}
func (*Void) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{16} }
// A single performance scenario: input to qps_json_driver
type Scenario struct {
// Human readable name for this scenario
Name string `protobuf:"bytes,1,opt,name=name" json:"name,omitempty"`
// Client configuration
ClientConfig *ClientConfig `protobuf:"bytes,2,opt,name=client_config,json=clientConfig" json:"client_config,omitempty"`
// Number of clients to start for the test
NumClients int32 `protobuf:"varint,3,opt,name=num_clients,json=numClients" json:"num_clients,omitempty"`