You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@skywalking.apache.org by wu...@apache.org on 2021/06/28 07:39:17 UTC

[skywalking-goapi] 09/16: remove-compat-file

This is an automated email from the ASF dual-hosted git repository.

wusheng pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/skywalking-goapi.git

commit 63409c748048c9757dbab872e81d2b43d5163bd7
Author: Evan <ev...@outlook.com>
AuthorDate: Fri Jun 4 11:26:49 2021 +0800

    remove-compat-file
---
 collect/servicemesh/v3/service-mesh-compat.pb.go   | 104 ----------------
 .../servicemesh/v3/service-mesh-compat_grpc.pb.go  | 136 ---------------------
 scripts/update_sniff_protocol.sh                   |   2 +-
 3 files changed, 1 insertion(+), 241 deletions(-)

diff --git a/collect/servicemesh/v3/service-mesh-compat.pb.go b/collect/servicemesh/v3/service-mesh-compat.pb.go
deleted file mode 100644
index 4552c68..0000000
--- a/collect/servicemesh/v3/service-mesh-compat.pb.go
+++ /dev/null
@@ -1,104 +0,0 @@
-//
-// Licensed to the Apache Software Foundation (ASF) under one or more
-// contributor license agreements.  See the NOTICE file distributed with
-// this work for additional information regarding copyright ownership.
-// The ASF licenses this file to You under the Apache License, Version 2.0
-// (the "License"); you may not use this file except in compliance with
-// the License.  You may obtain a copy of the License at
-//
-//     http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-//
-
-// Code generated by protoc-gen-go. DO NOT EDIT.
-// versions:
-// 	protoc-gen-go v1.26.0
-// 	protoc        v3.14.0
-// service-mesh-probe/service-mesh-compat.proto is a deprecated file.
-
-package v3
-
-import (
-	protoreflect "google.golang.org/protobuf/reflect/protoreflect"
-	protoimpl "google.golang.org/protobuf/runtime/protoimpl"
-	reflect "reflect"
-)
-
-const (
-	// Verify that this generated code is sufficiently up-to-date.
-	_ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion)
-	// Verify that runtime/protoimpl is sufficiently up-to-date.
-	_ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
-)
-
-var File_service_mesh_probe_service_mesh_compat_proto protoreflect.FileDescriptor
-
-var file_service_mesh_probe_service_mesh_compat_proto_rawDesc = []byte{
-	0x0a, 0x2c, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2d, 0x6d, 0x65, 0x73, 0x68, 0x2d, 0x70,
-	0x72, 0x6f, 0x62, 0x65, 0x2f, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2d, 0x6d, 0x65, 0x73,
-	0x68, 0x2d, 0x63, 0x6f, 0x6d, 0x70, 0x61, 0x74, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x25,
-	0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2d, 0x6d, 0x65, 0x73, 0x68, 0x2d, 0x70, 0x72, 0x6f,
-	0x62, 0x65, 0x2f, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2d, 0x6d, 0x65, 0x73, 0x68, 0x2e,
-	0x70, 0x72, 0x6f, 0x74, 0x6f, 0x32, 0x6f, 0x0a, 0x18, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65,
-	0x4d, 0x65, 0x73, 0x68, 0x4d, 0x65, 0x74, 0x72, 0x69, 0x63, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63,
-	0x65, 0x12, 0x53, 0x0a, 0x07, 0x63, 0x6f, 0x6c, 0x6c, 0x65, 0x63, 0x74, 0x12, 0x20, 0x2e, 0x73,
-	0x6b, 0x79, 0x77, 0x61, 0x6c, 0x6b, 0x69, 0x6e, 0x67, 0x2e, 0x76, 0x33, 0x2e, 0x53, 0x65, 0x72,
-	0x76, 0x69, 0x63, 0x65, 0x4d, 0x65, 0x73, 0x68, 0x4d, 0x65, 0x74, 0x72, 0x69, 0x63, 0x1a, 0x22,
-	0x2e, 0x73, 0x6b, 0x79, 0x77, 0x61, 0x6c, 0x6b, 0x69, 0x6e, 0x67, 0x2e, 0x76, 0x33, 0x2e, 0x4d,
-	0x65, 0x73, 0x68, 0x50, 0x72, 0x6f, 0x62, 0x65, 0x44, 0x6f, 0x77, 0x6e, 0x73, 0x74, 0x72, 0x65,
-	0x61, 0x6d, 0x22, 0x00, 0x28, 0x01, 0x42, 0x97, 0x01, 0x0a, 0x37, 0x6f, 0x72, 0x67, 0x2e, 0x61,
-	0x70, 0x61, 0x63, 0x68, 0x65, 0x2e, 0x73, 0x6b, 0x79, 0x77, 0x61, 0x6c, 0x6b, 0x69, 0x6e, 0x67,
-	0x2e, 0x61, 0x70, 0x6d, 0x2e, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x2e, 0x73, 0x65, 0x72,
-	0x76, 0x69, 0x63, 0x65, 0x6d, 0x65, 0x73, 0x68, 0x2e, 0x76, 0x33, 0x2e, 0x63, 0x6f, 0x6d, 0x70,
-	0x61, 0x74, 0x50, 0x01, 0x5a, 0x37, 0x73, 0x6b, 0x79, 0x77, 0x61, 0x6c, 0x6b, 0x69, 0x6e, 0x67,
-	0x2e, 0x61, 0x70, 0x61, 0x63, 0x68, 0x65, 0x2e, 0x6f, 0x72, 0x67, 0x2f, 0x72, 0x65, 0x70, 0x6f,
-	0x2f, 0x67, 0x6f, 0x61, 0x70, 0x69, 0x2f, 0x63, 0x6f, 0x6c, 0x6c, 0x65, 0x63, 0x74, 0x2f, 0x73,
-	0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x6d, 0x65, 0x73, 0x68, 0x2f, 0x76, 0x33, 0xb8, 0x01, 0x01,
-	0xaa, 0x02, 0x1d, 0x53, 0x6b, 0x79, 0x57, 0x61, 0x6c, 0x6b, 0x69, 0x6e, 0x67, 0x2e, 0x4e, 0x65,
-	0x74, 0x77, 0x6f, 0x72, 0x6b, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x2e, 0x56, 0x33,
-	0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
-}
-
-var file_service_mesh_probe_service_mesh_compat_proto_goTypes = []interface{}{
-	(*ServiceMeshMetric)(nil),   // 0: skywalking.v3.ServiceMeshMetric
-	(*MeshProbeDownstream)(nil), // 1: skywalking.v3.MeshProbeDownstream
-}
-var file_service_mesh_probe_service_mesh_compat_proto_depIdxs = []int32{
-	0, // 0: ServiceMeshMetricService.collect:input_type -> skywalking.v3.ServiceMeshMetric
-	1, // 1: ServiceMeshMetricService.collect:output_type -> skywalking.v3.MeshProbeDownstream
-	1, // [1:2] is the sub-list for method output_type
-	0, // [0:1] is the sub-list for method input_type
-	0, // [0:0] is the sub-list for extension type_name
-	0, // [0:0] is the sub-list for extension extendee
-	0, // [0:0] is the sub-list for field type_name
-}
-
-func init() { file_service_mesh_probe_service_mesh_compat_proto_init() }
-func file_service_mesh_probe_service_mesh_compat_proto_init() {
-	if File_service_mesh_probe_service_mesh_compat_proto != nil {
-		return
-	}
-	file_service_mesh_probe_service_mesh_proto_init()
-	type x struct{}
-	out := protoimpl.TypeBuilder{
-		File: protoimpl.DescBuilder{
-			GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
-			RawDescriptor: file_service_mesh_probe_service_mesh_compat_proto_rawDesc,
-			NumEnums:      0,
-			NumMessages:   0,
-			NumExtensions: 0,
-			NumServices:   1,
-		},
-		GoTypes:           file_service_mesh_probe_service_mesh_compat_proto_goTypes,
-		DependencyIndexes: file_service_mesh_probe_service_mesh_compat_proto_depIdxs,
-	}.Build()
-	File_service_mesh_probe_service_mesh_compat_proto = out.File
-	file_service_mesh_probe_service_mesh_compat_proto_rawDesc = nil
-	file_service_mesh_probe_service_mesh_compat_proto_goTypes = nil
-	file_service_mesh_probe_service_mesh_compat_proto_depIdxs = nil
-}
diff --git a/collect/servicemesh/v3/service-mesh-compat_grpc.pb.go b/collect/servicemesh/v3/service-mesh-compat_grpc.pb.go
deleted file mode 100644
index 180718b..0000000
--- a/collect/servicemesh/v3/service-mesh-compat_grpc.pb.go
+++ /dev/null
@@ -1,136 +0,0 @@
-// Code generated by protoc-gen-go-grpc. DO NOT EDIT.
-
-package v3
-
-import (
-	context "context"
-	grpc "google.golang.org/grpc"
-	codes "google.golang.org/grpc/codes"
-	status "google.golang.org/grpc/status"
-)
-
-// This is a compile-time assertion to ensure that this generated file
-// is compatible with the grpc package it is being compiled against.
-// Requires gRPC-Go v1.32.0 or later.
-const _ = grpc.SupportPackageIsVersion7
-
-// ServiceMeshMetricServiceClient is the client API for ServiceMeshMetricService service.
-//
-// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.
-type ServiceMeshMetricServiceClient interface {
-	Collect(ctx context.Context, opts ...grpc.CallOption) (ServiceMeshMetricService_CollectClient, error)
-}
-
-type serviceMeshMetricServiceClient struct {
-	cc grpc.ClientConnInterface
-}
-
-func NewServiceMeshMetricServiceClient(cc grpc.ClientConnInterface) ServiceMeshMetricServiceClient {
-	return &serviceMeshMetricServiceClient{cc}
-}
-
-func (c *serviceMeshMetricServiceClient) Collect(ctx context.Context, opts ...grpc.CallOption) (ServiceMeshMetricService_CollectClient, error) {
-	stream, err := c.cc.NewStream(ctx, &ServiceMeshMetricService_ServiceDesc.Streams[0], "/ServiceMeshMetricService/collect", opts...)
-	if err != nil {
-		return nil, err
-	}
-	x := &serviceMeshMetricServiceCollectClient{stream}
-	return x, nil
-}
-
-type ServiceMeshMetricService_CollectClient interface {
-	Send(*ServiceMeshMetric) error
-	CloseAndRecv() (*MeshProbeDownstream, error)
-	grpc.ClientStream
-}
-
-type serviceMeshMetricServiceCollectClient struct {
-	grpc.ClientStream
-}
-
-func (x *serviceMeshMetricServiceCollectClient) Send(m *ServiceMeshMetric) error {
-	return x.ClientStream.SendMsg(m)
-}
-
-func (x *serviceMeshMetricServiceCollectClient) CloseAndRecv() (*MeshProbeDownstream, error) {
-	if err := x.ClientStream.CloseSend(); err != nil {
-		return nil, err
-	}
-	m := new(MeshProbeDownstream)
-	if err := x.ClientStream.RecvMsg(m); err != nil {
-		return nil, err
-	}
-	return m, nil
-}
-
-// ServiceMeshMetricServiceServer is the server API for ServiceMeshMetricService service.
-// All implementations must embed UnimplementedServiceMeshMetricServiceServer
-// for forward compatibility
-type ServiceMeshMetricServiceServer interface {
-	Collect(ServiceMeshMetricService_CollectServer) error
-	mustEmbedUnimplementedServiceMeshMetricServiceServer()
-}
-
-// UnimplementedServiceMeshMetricServiceServer must be embedded to have forward compatible implementations.
-type UnimplementedServiceMeshMetricServiceServer struct {
-}
-
-func (UnimplementedServiceMeshMetricServiceServer) Collect(ServiceMeshMetricService_CollectServer) error {
-	return status.Errorf(codes.Unimplemented, "method Collect not implemented")
-}
-func (UnimplementedServiceMeshMetricServiceServer) mustEmbedUnimplementedServiceMeshMetricServiceServer() {
-}
-
-// UnsafeServiceMeshMetricServiceServer may be embedded to opt out of forward compatibility for this service.
-// Use of this interface is not recommended, as added methods to ServiceMeshMetricServiceServer will
-// result in compilation errors.
-type UnsafeServiceMeshMetricServiceServer interface {
-	mustEmbedUnimplementedServiceMeshMetricServiceServer()
-}
-
-func RegisterServiceMeshMetricServiceServer(s grpc.ServiceRegistrar, srv ServiceMeshMetricServiceServer) {
-	s.RegisterService(&ServiceMeshMetricService_ServiceDesc, srv)
-}
-
-func _ServiceMeshMetricService_Collect_Handler(srv interface{}, stream grpc.ServerStream) error {
-	return srv.(ServiceMeshMetricServiceServer).Collect(&serviceMeshMetricServiceCollectServer{stream})
-}
-
-type ServiceMeshMetricService_CollectServer interface {
-	SendAndClose(*MeshProbeDownstream) error
-	Recv() (*ServiceMeshMetric, error)
-	grpc.ServerStream
-}
-
-type serviceMeshMetricServiceCollectServer struct {
-	grpc.ServerStream
-}
-
-func (x *serviceMeshMetricServiceCollectServer) SendAndClose(m *MeshProbeDownstream) error {
-	return x.ServerStream.SendMsg(m)
-}
-
-func (x *serviceMeshMetricServiceCollectServer) Recv() (*ServiceMeshMetric, error) {
-	m := new(ServiceMeshMetric)
-	if err := x.ServerStream.RecvMsg(m); err != nil {
-		return nil, err
-	}
-	return m, nil
-}
-
-// ServiceMeshMetricService_ServiceDesc is the grpc.ServiceDesc for ServiceMeshMetricService service.
-// It's only intended for direct use with grpc.RegisterService,
-// and not to be introspected or modified (even as a copy)
-var ServiceMeshMetricService_ServiceDesc = grpc.ServiceDesc{
-	ServiceName: "ServiceMeshMetricService",
-	HandlerType: (*ServiceMeshMetricServiceServer)(nil),
-	Methods:     []grpc.MethodDesc{},
-	Streams: []grpc.StreamDesc{
-		{
-			StreamName:    "collect",
-			Handler:       _ServiceMeshMetricService_Collect_Handler,
-			ClientStreams: true,
-		},
-	},
-	Metadata: "service-mesh-probe/service-mesh-compat.proto",
-}
diff --git a/scripts/update_sniff_protocol.sh b/scripts/update_sniff_protocol.sh
index c68995e..f659674 100644
--- a/scripts/update_sniff_protocol.sh
+++ b/scripts/update_sniff_protocol.sh
@@ -40,7 +40,7 @@ function makeProtocolHome(){
 
   tar -zxf "$TEMPDIR"/collect-protocol.tgz -C "$TEMPDIR"/collect-protocol --strip 1
 
-  find "$TEMPDIR"/collect-protocol -name "*Compat.proto" -exec rm {} \;
+  find "$TEMPDIR"/collect-protocol -regex ".*[cC]ompat.proto" -exec rm {} \;
 
   if [[ ! -d "$TEMPDIR"/collect-protocol/satellite ]]; then
     mkdir "$TEMPDIR"/collect-protocol/satellite