github.com/hxx258456/ccgo@v0.0.5-0.20230213014102-48b35f46f66f/go-control-plane/envoy/service/metrics/v3/metrics_service.pb.go (about) 1 // Code generated by protoc-gen-go. DO NOT EDIT. 2 // versions: 3 // protoc-gen-go v1.25.0 4 // protoc v3.16.0 5 // source: envoy/service/metrics/v3/metrics_service.proto 6 7 package envoy_service_metrics_v3 8 9 import ( 10 context "context" 11 _ "github.com/cncf/xds/go/udpa/annotations" 12 v3 "github.com/hxx258456/ccgo/go-control-plane/envoy/config/core/v3" 13 _ "github.com/envoyproxy/protoc-gen-validate/validate" 14 proto "github.com/golang/protobuf/proto" 15 _go "github.com/prometheus/client_model/go" 16 grpc "github.com/hxx258456/ccgo/grpc" 17 codes "github.com/hxx258456/ccgo/grpc/codes" 18 status "github.com/hxx258456/ccgo/grpc/status" 19 protoreflect "google.golang.org/protobuf/reflect/protoreflect" 20 protoimpl "google.golang.org/protobuf/runtime/protoimpl" 21 reflect "reflect" 22 sync "sync" 23 ) 24 25 const ( 26 // Verify that this generated code is sufficiently up-to-date. 27 _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) 28 // Verify that runtime/protoimpl is sufficiently up-to-date. 29 _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) 30 ) 31 32 // This is a compile-time assertion that a sufficiently up-to-date version 33 // of the legacy proto package is being used. 34 const _ = proto.ProtoPackageIsVersion4 35 36 type StreamMetricsResponse struct { 37 state protoimpl.MessageState 38 sizeCache protoimpl.SizeCache 39 unknownFields protoimpl.UnknownFields 40 } 41 42 func (x *StreamMetricsResponse) Reset() { 43 *x = StreamMetricsResponse{} 44 if protoimpl.UnsafeEnabled { 45 mi := &file_envoy_service_metrics_v3_metrics_service_proto_msgTypes[0] 46 ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) 47 ms.StoreMessageInfo(mi) 48 } 49 } 50 51 func (x *StreamMetricsResponse) String() string { 52 return protoimpl.X.MessageStringOf(x) 53 } 54 55 func (*StreamMetricsResponse) ProtoMessage() {} 56 57 func (x *StreamMetricsResponse) ProtoReflect() protoreflect.Message { 58 mi := &file_envoy_service_metrics_v3_metrics_service_proto_msgTypes[0] 59 if protoimpl.UnsafeEnabled && x != nil { 60 ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) 61 if ms.LoadMessageInfo() == nil { 62 ms.StoreMessageInfo(mi) 63 } 64 return ms 65 } 66 return mi.MessageOf(x) 67 } 68 69 // Deprecated: Use StreamMetricsResponse.ProtoReflect.Descriptor instead. 70 func (*StreamMetricsResponse) Descriptor() ([]byte, []int) { 71 return file_envoy_service_metrics_v3_metrics_service_proto_rawDescGZIP(), []int{0} 72 } 73 74 type StreamMetricsMessage struct { 75 state protoimpl.MessageState 76 sizeCache protoimpl.SizeCache 77 unknownFields protoimpl.UnknownFields 78 79 // Identifier data effectively is a structured metadata. As a performance optimization this will 80 // only be sent in the first message on the stream. 81 Identifier *StreamMetricsMessage_Identifier `protobuf:"bytes,1,opt,name=identifier,proto3" json:"identifier,omitempty"` 82 // A list of metric entries 83 EnvoyMetrics []*_go.MetricFamily `protobuf:"bytes,2,rep,name=envoy_metrics,json=envoyMetrics,proto3" json:"envoy_metrics,omitempty"` 84 } 85 86 func (x *StreamMetricsMessage) Reset() { 87 *x = StreamMetricsMessage{} 88 if protoimpl.UnsafeEnabled { 89 mi := &file_envoy_service_metrics_v3_metrics_service_proto_msgTypes[1] 90 ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) 91 ms.StoreMessageInfo(mi) 92 } 93 } 94 95 func (x *StreamMetricsMessage) String() string { 96 return protoimpl.X.MessageStringOf(x) 97 } 98 99 func (*StreamMetricsMessage) ProtoMessage() {} 100 101 func (x *StreamMetricsMessage) ProtoReflect() protoreflect.Message { 102 mi := &file_envoy_service_metrics_v3_metrics_service_proto_msgTypes[1] 103 if protoimpl.UnsafeEnabled && x != nil { 104 ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) 105 if ms.LoadMessageInfo() == nil { 106 ms.StoreMessageInfo(mi) 107 } 108 return ms 109 } 110 return mi.MessageOf(x) 111 } 112 113 // Deprecated: Use StreamMetricsMessage.ProtoReflect.Descriptor instead. 114 func (*StreamMetricsMessage) Descriptor() ([]byte, []int) { 115 return file_envoy_service_metrics_v3_metrics_service_proto_rawDescGZIP(), []int{1} 116 } 117 118 func (x *StreamMetricsMessage) GetIdentifier() *StreamMetricsMessage_Identifier { 119 if x != nil { 120 return x.Identifier 121 } 122 return nil 123 } 124 125 func (x *StreamMetricsMessage) GetEnvoyMetrics() []*_go.MetricFamily { 126 if x != nil { 127 return x.EnvoyMetrics 128 } 129 return nil 130 } 131 132 type StreamMetricsMessage_Identifier struct { 133 state protoimpl.MessageState 134 sizeCache protoimpl.SizeCache 135 unknownFields protoimpl.UnknownFields 136 137 // The node sending metrics over the stream. 138 Node *v3.Node `protobuf:"bytes,1,opt,name=node,proto3" json:"node,omitempty"` 139 } 140 141 func (x *StreamMetricsMessage_Identifier) Reset() { 142 *x = StreamMetricsMessage_Identifier{} 143 if protoimpl.UnsafeEnabled { 144 mi := &file_envoy_service_metrics_v3_metrics_service_proto_msgTypes[2] 145 ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) 146 ms.StoreMessageInfo(mi) 147 } 148 } 149 150 func (x *StreamMetricsMessage_Identifier) String() string { 151 return protoimpl.X.MessageStringOf(x) 152 } 153 154 func (*StreamMetricsMessage_Identifier) ProtoMessage() {} 155 156 func (x *StreamMetricsMessage_Identifier) ProtoReflect() protoreflect.Message { 157 mi := &file_envoy_service_metrics_v3_metrics_service_proto_msgTypes[2] 158 if protoimpl.UnsafeEnabled && x != nil { 159 ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) 160 if ms.LoadMessageInfo() == nil { 161 ms.StoreMessageInfo(mi) 162 } 163 return ms 164 } 165 return mi.MessageOf(x) 166 } 167 168 // Deprecated: Use StreamMetricsMessage_Identifier.ProtoReflect.Descriptor instead. 169 func (*StreamMetricsMessage_Identifier) Descriptor() ([]byte, []int) { 170 return file_envoy_service_metrics_v3_metrics_service_proto_rawDescGZIP(), []int{1, 0} 171 } 172 173 func (x *StreamMetricsMessage_Identifier) GetNode() *v3.Node { 174 if x != nil { 175 return x.Node 176 } 177 return nil 178 } 179 180 var File_envoy_service_metrics_v3_metrics_service_proto protoreflect.FileDescriptor 181 182 var file_envoy_service_metrics_v3_metrics_service_proto_rawDesc = []byte{ 183 0x0a, 0x2e, 0x65, 0x6e, 0x76, 0x6f, 0x79, 0x2f, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2f, 184 0x6d, 0x65, 0x74, 0x72, 0x69, 0x63, 0x73, 0x2f, 0x76, 0x33, 0x2f, 0x6d, 0x65, 0x74, 0x72, 0x69, 185 0x63, 0x73, 0x5f, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 186 0x12, 0x18, 0x65, 0x6e, 0x76, 0x6f, 0x79, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 187 0x6d, 0x65, 0x74, 0x72, 0x69, 0x63, 0x73, 0x2e, 0x76, 0x33, 0x1a, 0x1f, 0x65, 0x6e, 0x76, 0x6f, 188 0x79, 0x2f, 0x63, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x2f, 0x63, 0x6f, 0x72, 0x65, 0x2f, 0x76, 0x33, 189 0x2f, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x22, 0x69, 0x6f, 0x2f, 190 0x70, 0x72, 0x6f, 0x6d, 0x65, 0x74, 0x68, 0x65, 0x75, 0x73, 0x2f, 0x63, 0x6c, 0x69, 0x65, 0x6e, 191 0x74, 0x2f, 0x6d, 0x65, 0x74, 0x72, 0x69, 0x63, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 192 0x1d, 0x75, 0x64, 0x70, 0x61, 0x2f, 0x61, 0x6e, 0x6e, 0x6f, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 193 0x73, 0x2f, 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x21, 194 0x75, 0x64, 0x70, 0x61, 0x2f, 0x61, 0x6e, 0x6e, 0x6f, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 195 0x2f, 0x76, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x69, 0x6e, 0x67, 0x2e, 0x70, 0x72, 0x6f, 0x74, 196 0x6f, 0x1a, 0x17, 0x76, 0x61, 0x6c, 0x69, 0x64, 0x61, 0x74, 0x65, 0x2f, 0x76, 0x61, 0x6c, 0x69, 197 0x64, 0x61, 0x74, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x4e, 0x0a, 0x15, 0x53, 0x74, 198 0x72, 0x65, 0x61, 0x6d, 0x4d, 0x65, 0x74, 0x72, 0x69, 0x63, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 199 0x6e, 0x73, 0x65, 0x3a, 0x35, 0x9a, 0xc5, 0x88, 0x1e, 0x30, 0x0a, 0x2e, 0x65, 0x6e, 0x76, 0x6f, 200 0x79, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x6d, 0x65, 0x74, 0x72, 0x69, 0x63, 201 0x73, 0x2e, 0x76, 0x32, 0x2e, 0x53, 0x74, 0x72, 0x65, 0x61, 0x6d, 0x4d, 0x65, 0x74, 0x72, 0x69, 202 0x63, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0xfa, 0x02, 0x0a, 0x14, 0x53, 203 0x74, 0x72, 0x65, 0x61, 0x6d, 0x4d, 0x65, 0x74, 0x72, 0x69, 0x63, 0x73, 0x4d, 0x65, 0x73, 0x73, 204 0x61, 0x67, 0x65, 0x12, 0x59, 0x0a, 0x0a, 0x69, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x66, 0x69, 0x65, 205 0x72, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x39, 0x2e, 0x65, 0x6e, 0x76, 0x6f, 0x79, 0x2e, 206 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x6d, 0x65, 0x74, 0x72, 0x69, 0x63, 0x73, 0x2e, 207 0x76, 0x33, 0x2e, 0x53, 0x74, 0x72, 0x65, 0x61, 0x6d, 0x4d, 0x65, 0x74, 0x72, 0x69, 0x63, 0x73, 208 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x2e, 0x49, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x66, 0x69, 209 0x65, 0x72, 0x52, 0x0a, 0x69, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x66, 0x69, 0x65, 0x72, 0x12, 0x47, 210 0x0a, 0x0d, 0x65, 0x6e, 0x76, 0x6f, 0x79, 0x5f, 0x6d, 0x65, 0x74, 0x72, 0x69, 0x63, 0x73, 0x18, 211 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x22, 0x2e, 0x69, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x6d, 0x65, 212 0x74, 0x68, 0x65, 0x75, 0x73, 0x2e, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x2e, 0x4d, 0x65, 0x74, 213 0x72, 0x69, 0x63, 0x46, 0x61, 0x6d, 0x69, 0x6c, 0x79, 0x52, 0x0c, 0x65, 0x6e, 0x76, 0x6f, 0x79, 214 0x4d, 0x65, 0x74, 0x72, 0x69, 0x63, 0x73, 0x1a, 0x87, 0x01, 0x0a, 0x0a, 0x49, 0x64, 0x65, 0x6e, 215 0x74, 0x69, 0x66, 0x69, 0x65, 0x72, 0x12, 0x38, 0x0a, 0x04, 0x6e, 0x6f, 0x64, 0x65, 0x18, 0x01, 216 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x65, 0x6e, 0x76, 0x6f, 0x79, 0x2e, 0x63, 0x6f, 0x6e, 217 0x66, 0x69, 0x67, 0x2e, 0x63, 0x6f, 0x72, 0x65, 0x2e, 0x76, 0x33, 0x2e, 0x4e, 0x6f, 0x64, 0x65, 218 0x42, 0x08, 0xfa, 0x42, 0x05, 0x8a, 0x01, 0x02, 0x10, 0x01, 0x52, 0x04, 0x6e, 0x6f, 0x64, 0x65, 219 0x3a, 0x3f, 0x9a, 0xc5, 0x88, 0x1e, 0x3a, 0x0a, 0x38, 0x65, 0x6e, 0x76, 0x6f, 0x79, 0x2e, 0x73, 220 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x6d, 0x65, 0x74, 0x72, 0x69, 0x63, 0x73, 0x2e, 0x76, 221 0x32, 0x2e, 0x53, 0x74, 0x72, 0x65, 0x61, 0x6d, 0x4d, 0x65, 0x74, 0x72, 0x69, 0x63, 0x73, 0x4d, 222 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x2e, 0x49, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x66, 0x69, 0x65, 223 0x72, 0x3a, 0x34, 0x9a, 0xc5, 0x88, 0x1e, 0x2f, 0x0a, 0x2d, 0x65, 0x6e, 0x76, 0x6f, 0x79, 0x2e, 224 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x6d, 0x65, 0x74, 0x72, 0x69, 0x63, 0x73, 0x2e, 225 0x76, 0x32, 0x2e, 0x53, 0x74, 0x72, 0x65, 0x61, 0x6d, 0x4d, 0x65, 0x74, 0x72, 0x69, 0x63, 0x73, 226 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x32, 0x86, 0x01, 0x0a, 0x0e, 0x4d, 0x65, 0x74, 0x72, 227 0x69, 0x63, 0x73, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x12, 0x74, 0x0a, 0x0d, 0x53, 0x74, 228 0x72, 0x65, 0x61, 0x6d, 0x4d, 0x65, 0x74, 0x72, 0x69, 0x63, 0x73, 0x12, 0x2e, 0x2e, 0x65, 0x6e, 229 0x76, 0x6f, 0x79, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x6d, 0x65, 0x74, 0x72, 230 0x69, 0x63, 0x73, 0x2e, 0x76, 0x33, 0x2e, 0x53, 0x74, 0x72, 0x65, 0x61, 0x6d, 0x4d, 0x65, 0x74, 231 0x72, 0x69, 0x63, 0x73, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x1a, 0x2f, 0x2e, 0x65, 0x6e, 232 0x76, 0x6f, 0x79, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x6d, 0x65, 0x74, 0x72, 233 0x69, 0x63, 0x73, 0x2e, 0x76, 0x33, 0x2e, 0x53, 0x74, 0x72, 0x65, 0x61, 0x6d, 0x4d, 0x65, 0x74, 234 0x72, 0x69, 0x63, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x28, 0x01, 235 0x42, 0x4a, 0x0a, 0x26, 0x69, 0x6f, 0x2e, 0x65, 0x6e, 0x76, 0x6f, 0x79, 0x70, 0x72, 0x6f, 0x78, 236 0x79, 0x2e, 0x65, 0x6e, 0x76, 0x6f, 0x79, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 237 0x6d, 0x65, 0x74, 0x72, 0x69, 0x63, 0x73, 0x2e, 0x76, 0x33, 0x42, 0x13, 0x4d, 0x65, 0x74, 0x72, 238 0x69, 0x63, 0x73, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 239 0x01, 0x88, 0x01, 0x01, 0xba, 0x80, 0xc8, 0xd1, 0x06, 0x02, 0x10, 0x02, 0x62, 0x06, 0x70, 0x72, 240 0x6f, 0x74, 0x6f, 0x33, 241 } 242 243 var ( 244 file_envoy_service_metrics_v3_metrics_service_proto_rawDescOnce sync.Once 245 file_envoy_service_metrics_v3_metrics_service_proto_rawDescData = file_envoy_service_metrics_v3_metrics_service_proto_rawDesc 246 ) 247 248 func file_envoy_service_metrics_v3_metrics_service_proto_rawDescGZIP() []byte { 249 file_envoy_service_metrics_v3_metrics_service_proto_rawDescOnce.Do(func() { 250 file_envoy_service_metrics_v3_metrics_service_proto_rawDescData = protoimpl.X.CompressGZIP(file_envoy_service_metrics_v3_metrics_service_proto_rawDescData) 251 }) 252 return file_envoy_service_metrics_v3_metrics_service_proto_rawDescData 253 } 254 255 var file_envoy_service_metrics_v3_metrics_service_proto_msgTypes = make([]protoimpl.MessageInfo, 3) 256 var file_envoy_service_metrics_v3_metrics_service_proto_goTypes = []interface{}{ 257 (*StreamMetricsResponse)(nil), // 0: envoy.service.metrics.v3.StreamMetricsResponse 258 (*StreamMetricsMessage)(nil), // 1: envoy.service.metrics.v3.StreamMetricsMessage 259 (*StreamMetricsMessage_Identifier)(nil), // 2: envoy.service.metrics.v3.StreamMetricsMessage.Identifier 260 (*_go.MetricFamily)(nil), // 3: io.prometheus.client.MetricFamily 261 (*v3.Node)(nil), // 4: envoy.config.core.v3.Node 262 } 263 var file_envoy_service_metrics_v3_metrics_service_proto_depIdxs = []int32{ 264 2, // 0: envoy.service.metrics.v3.StreamMetricsMessage.identifier:type_name -> envoy.service.metrics.v3.StreamMetricsMessage.Identifier 265 3, // 1: envoy.service.metrics.v3.StreamMetricsMessage.envoy_metrics:type_name -> io.prometheus.client.MetricFamily 266 4, // 2: envoy.service.metrics.v3.StreamMetricsMessage.Identifier.node:type_name -> envoy.config.core.v3.Node 267 1, // 3: envoy.service.metrics.v3.MetricsService.StreamMetrics:input_type -> envoy.service.metrics.v3.StreamMetricsMessage 268 0, // 4: envoy.service.metrics.v3.MetricsService.StreamMetrics:output_type -> envoy.service.metrics.v3.StreamMetricsResponse 269 4, // [4:5] is the sub-list for method output_type 270 3, // [3:4] is the sub-list for method input_type 271 3, // [3:3] is the sub-list for extension type_name 272 3, // [3:3] is the sub-list for extension extendee 273 0, // [0:3] is the sub-list for field type_name 274 } 275 276 func init() { file_envoy_service_metrics_v3_metrics_service_proto_init() } 277 func file_envoy_service_metrics_v3_metrics_service_proto_init() { 278 if File_envoy_service_metrics_v3_metrics_service_proto != nil { 279 return 280 } 281 if !protoimpl.UnsafeEnabled { 282 file_envoy_service_metrics_v3_metrics_service_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { 283 switch v := v.(*StreamMetricsResponse); i { 284 case 0: 285 return &v.state 286 case 1: 287 return &v.sizeCache 288 case 2: 289 return &v.unknownFields 290 default: 291 return nil 292 } 293 } 294 file_envoy_service_metrics_v3_metrics_service_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { 295 switch v := v.(*StreamMetricsMessage); i { 296 case 0: 297 return &v.state 298 case 1: 299 return &v.sizeCache 300 case 2: 301 return &v.unknownFields 302 default: 303 return nil 304 } 305 } 306 file_envoy_service_metrics_v3_metrics_service_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { 307 switch v := v.(*StreamMetricsMessage_Identifier); i { 308 case 0: 309 return &v.state 310 case 1: 311 return &v.sizeCache 312 case 2: 313 return &v.unknownFields 314 default: 315 return nil 316 } 317 } 318 } 319 type x struct{} 320 out := protoimpl.TypeBuilder{ 321 File: protoimpl.DescBuilder{ 322 GoPackagePath: reflect.TypeOf(x{}).PkgPath(), 323 RawDescriptor: file_envoy_service_metrics_v3_metrics_service_proto_rawDesc, 324 NumEnums: 0, 325 NumMessages: 3, 326 NumExtensions: 0, 327 NumServices: 1, 328 }, 329 GoTypes: file_envoy_service_metrics_v3_metrics_service_proto_goTypes, 330 DependencyIndexes: file_envoy_service_metrics_v3_metrics_service_proto_depIdxs, 331 MessageInfos: file_envoy_service_metrics_v3_metrics_service_proto_msgTypes, 332 }.Build() 333 File_envoy_service_metrics_v3_metrics_service_proto = out.File 334 file_envoy_service_metrics_v3_metrics_service_proto_rawDesc = nil 335 file_envoy_service_metrics_v3_metrics_service_proto_goTypes = nil 336 file_envoy_service_metrics_v3_metrics_service_proto_depIdxs = nil 337 } 338 339 // Reference imports to suppress errors if they are not otherwise used. 340 var _ context.Context 341 var _ grpc.ClientConnInterface 342 343 // This is a compile-time assertion to ensure that this generated file 344 // is compatible with the grpc package it is being compiled against. 345 const _ = grpc.SupportPackageIsVersion6 346 347 // MetricsServiceClient is the client API for MetricsService service. 348 // 349 // For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream. 350 type MetricsServiceClient interface { 351 // Envoy will connect and send StreamMetricsMessage messages forever. It does not expect any 352 // response to be sent as nothing would be done in the case of failure. 353 StreamMetrics(ctx context.Context, opts ...grpc.CallOption) (MetricsService_StreamMetricsClient, error) 354 } 355 356 type metricsServiceClient struct { 357 cc grpc.ClientConnInterface 358 } 359 360 func NewMetricsServiceClient(cc grpc.ClientConnInterface) MetricsServiceClient { 361 return &metricsServiceClient{cc} 362 } 363 364 func (c *metricsServiceClient) StreamMetrics(ctx context.Context, opts ...grpc.CallOption) (MetricsService_StreamMetricsClient, error) { 365 stream, err := c.cc.NewStream(ctx, &_MetricsService_serviceDesc.Streams[0], "/envoy.service.metrics.v3.MetricsService/StreamMetrics", opts...) 366 if err != nil { 367 return nil, err 368 } 369 x := &metricsServiceStreamMetricsClient{stream} 370 return x, nil 371 } 372 373 type MetricsService_StreamMetricsClient interface { 374 Send(*StreamMetricsMessage) error 375 CloseAndRecv() (*StreamMetricsResponse, error) 376 grpc.ClientStream 377 } 378 379 type metricsServiceStreamMetricsClient struct { 380 grpc.ClientStream 381 } 382 383 func (x *metricsServiceStreamMetricsClient) Send(m *StreamMetricsMessage) error { 384 return x.ClientStream.SendMsg(m) 385 } 386 387 func (x *metricsServiceStreamMetricsClient) CloseAndRecv() (*StreamMetricsResponse, error) { 388 if err := x.ClientStream.CloseSend(); err != nil { 389 return nil, err 390 } 391 m := new(StreamMetricsResponse) 392 if err := x.ClientStream.RecvMsg(m); err != nil { 393 return nil, err 394 } 395 return m, nil 396 } 397 398 // MetricsServiceServer is the server API for MetricsService service. 399 type MetricsServiceServer interface { 400 // Envoy will connect and send StreamMetricsMessage messages forever. It does not expect any 401 // response to be sent as nothing would be done in the case of failure. 402 StreamMetrics(MetricsService_StreamMetricsServer) error 403 } 404 405 // UnimplementedMetricsServiceServer can be embedded to have forward compatible implementations. 406 type UnimplementedMetricsServiceServer struct { 407 } 408 409 func (*UnimplementedMetricsServiceServer) StreamMetrics(MetricsService_StreamMetricsServer) error { 410 return status.Errorf(codes.Unimplemented, "method StreamMetrics not implemented") 411 } 412 413 func RegisterMetricsServiceServer(s *grpc.Server, srv MetricsServiceServer) { 414 s.RegisterService(&_MetricsService_serviceDesc, srv) 415 } 416 417 func _MetricsService_StreamMetrics_Handler(srv interface{}, stream grpc.ServerStream) error { 418 return srv.(MetricsServiceServer).StreamMetrics(&metricsServiceStreamMetricsServer{stream}) 419 } 420 421 type MetricsService_StreamMetricsServer interface { 422 SendAndClose(*StreamMetricsResponse) error 423 Recv() (*StreamMetricsMessage, error) 424 grpc.ServerStream 425 } 426 427 type metricsServiceStreamMetricsServer struct { 428 grpc.ServerStream 429 } 430 431 func (x *metricsServiceStreamMetricsServer) SendAndClose(m *StreamMetricsResponse) error { 432 return x.ServerStream.SendMsg(m) 433 } 434 435 func (x *metricsServiceStreamMetricsServer) Recv() (*StreamMetricsMessage, error) { 436 m := new(StreamMetricsMessage) 437 if err := x.ServerStream.RecvMsg(m); err != nil { 438 return nil, err 439 } 440 return m, nil 441 } 442 443 var _MetricsService_serviceDesc = grpc.ServiceDesc{ 444 ServiceName: "envoy.service.metrics.v3.MetricsService", 445 HandlerType: (*MetricsServiceServer)(nil), 446 Methods: []grpc.MethodDesc{}, 447 Streams: []grpc.StreamDesc{ 448 { 449 StreamName: "StreamMetrics", 450 Handler: _MetricsService_StreamMetrics_Handler, 451 ClientStreams: true, 452 }, 453 }, 454 Metadata: "envoy/service/metrics/v3/metrics_service.proto", 455 }