github.com/google/cloudprober@v0.11.3/probes/external/proto/server.pb.go (about)

     1  // This package defines protocol for use with cloudprober's external
     2  // probe (in server mode).
     3  
     4  // Code generated by protoc-gen-go. DO NOT EDIT.
     5  // versions:
     6  // 	protoc-gen-go v1.26.0
     7  // 	protoc        v3.17.3
     8  // source: github.com/google/cloudprober/probes/external/proto/server.proto
     9  
    10  package proto
    11  
    12  import (
    13  	protoreflect "google.golang.org/protobuf/reflect/protoreflect"
    14  	protoimpl "google.golang.org/protobuf/runtime/protoimpl"
    15  	reflect "reflect"
    16  	sync "sync"
    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  // ProbeRequest is the message that cloudprober sends to the external probe
    27  // server.
    28  type ProbeRequest struct {
    29  	state         protoimpl.MessageState
    30  	sizeCache     protoimpl.SizeCache
    31  	unknownFields protoimpl.UnknownFields
    32  
    33  	// The unique identifier for this request.  This is unique across
    34  	// an execution of the probe server.  It starts at 1.
    35  	RequestId *int32 `protobuf:"varint,1,req,name=request_id,json=requestId" json:"request_id,omitempty"`
    36  	// How long to allow for the execution of this request, in
    37  	// milliseconds.  If the time limit is exceeded, the server
    38  	// should abort the request, but *not* send back a reply.  The
    39  	// client will have to do timeouts anyway.
    40  	TimeLimit *int32                 `protobuf:"varint,2,req,name=time_limit,json=timeLimit" json:"time_limit,omitempty"`
    41  	Options   []*ProbeRequest_Option `protobuf:"bytes,3,rep,name=options" json:"options,omitempty"`
    42  }
    43  
    44  func (x *ProbeRequest) Reset() {
    45  	*x = ProbeRequest{}
    46  	if protoimpl.UnsafeEnabled {
    47  		mi := &file_github_com_google_cloudprober_probes_external_proto_server_proto_msgTypes[0]
    48  		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
    49  		ms.StoreMessageInfo(mi)
    50  	}
    51  }
    52  
    53  func (x *ProbeRequest) String() string {
    54  	return protoimpl.X.MessageStringOf(x)
    55  }
    56  
    57  func (*ProbeRequest) ProtoMessage() {}
    58  
    59  func (x *ProbeRequest) ProtoReflect() protoreflect.Message {
    60  	mi := &file_github_com_google_cloudprober_probes_external_proto_server_proto_msgTypes[0]
    61  	if protoimpl.UnsafeEnabled && x != nil {
    62  		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
    63  		if ms.LoadMessageInfo() == nil {
    64  			ms.StoreMessageInfo(mi)
    65  		}
    66  		return ms
    67  	}
    68  	return mi.MessageOf(x)
    69  }
    70  
    71  // Deprecated: Use ProbeRequest.ProtoReflect.Descriptor instead.
    72  func (*ProbeRequest) Descriptor() ([]byte, []int) {
    73  	return file_github_com_google_cloudprober_probes_external_proto_server_proto_rawDescGZIP(), []int{0}
    74  }
    75  
    76  func (x *ProbeRequest) GetRequestId() int32 {
    77  	if x != nil && x.RequestId != nil {
    78  		return *x.RequestId
    79  	}
    80  	return 0
    81  }
    82  
    83  func (x *ProbeRequest) GetTimeLimit() int32 {
    84  	if x != nil && x.TimeLimit != nil {
    85  		return *x.TimeLimit
    86  	}
    87  	return 0
    88  }
    89  
    90  func (x *ProbeRequest) GetOptions() []*ProbeRequest_Option {
    91  	if x != nil {
    92  		return x.Options
    93  	}
    94  	return nil
    95  }
    96  
    97  // ProbeReply is the message that external probe server sends back to the
    98  // cloudprober.
    99  type ProbeReply struct {
   100  	state         protoimpl.MessageState
   101  	sizeCache     protoimpl.SizeCache
   102  	unknownFields protoimpl.UnknownFields
   103  
   104  	// The sequence number for this request.
   105  	RequestId *int32 `protobuf:"varint,1,req,name=request_id,json=requestId" json:"request_id,omitempty"`
   106  	// For a normal result, this is not present.
   107  	// If it is present, it indicates that the probe failed.
   108  	ErrorMessage *string `protobuf:"bytes,2,opt,name=error_message,json=errorMessage" json:"error_message,omitempty"`
   109  	// The result of the probe. Cloudprober parses the payload to retrieve
   110  	// variables from it. It expects variables in the following format:
   111  	// var1 value1 (for example: total_errors 589)
   112  	// TODO(manugarg): Add an option to export mapped variables, for example:
   113  	// client-errors map:lang java:200 python:20 golang:3
   114  	Payload *string `protobuf:"bytes,3,opt,name=payload" json:"payload,omitempty"`
   115  }
   116  
   117  func (x *ProbeReply) Reset() {
   118  	*x = ProbeReply{}
   119  	if protoimpl.UnsafeEnabled {
   120  		mi := &file_github_com_google_cloudprober_probes_external_proto_server_proto_msgTypes[1]
   121  		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
   122  		ms.StoreMessageInfo(mi)
   123  	}
   124  }
   125  
   126  func (x *ProbeReply) String() string {
   127  	return protoimpl.X.MessageStringOf(x)
   128  }
   129  
   130  func (*ProbeReply) ProtoMessage() {}
   131  
   132  func (x *ProbeReply) ProtoReflect() protoreflect.Message {
   133  	mi := &file_github_com_google_cloudprober_probes_external_proto_server_proto_msgTypes[1]
   134  	if protoimpl.UnsafeEnabled && x != nil {
   135  		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
   136  		if ms.LoadMessageInfo() == nil {
   137  			ms.StoreMessageInfo(mi)
   138  		}
   139  		return ms
   140  	}
   141  	return mi.MessageOf(x)
   142  }
   143  
   144  // Deprecated: Use ProbeReply.ProtoReflect.Descriptor instead.
   145  func (*ProbeReply) Descriptor() ([]byte, []int) {
   146  	return file_github_com_google_cloudprober_probes_external_proto_server_proto_rawDescGZIP(), []int{1}
   147  }
   148  
   149  func (x *ProbeReply) GetRequestId() int32 {
   150  	if x != nil && x.RequestId != nil {
   151  		return *x.RequestId
   152  	}
   153  	return 0
   154  }
   155  
   156  func (x *ProbeReply) GetErrorMessage() string {
   157  	if x != nil && x.ErrorMessage != nil {
   158  		return *x.ErrorMessage
   159  	}
   160  	return ""
   161  }
   162  
   163  func (x *ProbeReply) GetPayload() string {
   164  	if x != nil && x.Payload != nil {
   165  		return *x.Payload
   166  	}
   167  	return ""
   168  }
   169  
   170  type ProbeRequest_Option struct {
   171  	state         protoimpl.MessageState
   172  	sizeCache     protoimpl.SizeCache
   173  	unknownFields protoimpl.UnknownFields
   174  
   175  	Name  *string `protobuf:"bytes,1,req,name=name" json:"name,omitempty"`
   176  	Value *string `protobuf:"bytes,2,req,name=value" json:"value,omitempty"`
   177  }
   178  
   179  func (x *ProbeRequest_Option) Reset() {
   180  	*x = ProbeRequest_Option{}
   181  	if protoimpl.UnsafeEnabled {
   182  		mi := &file_github_com_google_cloudprober_probes_external_proto_server_proto_msgTypes[2]
   183  		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
   184  		ms.StoreMessageInfo(mi)
   185  	}
   186  }
   187  
   188  func (x *ProbeRequest_Option) String() string {
   189  	return protoimpl.X.MessageStringOf(x)
   190  }
   191  
   192  func (*ProbeRequest_Option) ProtoMessage() {}
   193  
   194  func (x *ProbeRequest_Option) ProtoReflect() protoreflect.Message {
   195  	mi := &file_github_com_google_cloudprober_probes_external_proto_server_proto_msgTypes[2]
   196  	if protoimpl.UnsafeEnabled && x != nil {
   197  		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
   198  		if ms.LoadMessageInfo() == nil {
   199  			ms.StoreMessageInfo(mi)
   200  		}
   201  		return ms
   202  	}
   203  	return mi.MessageOf(x)
   204  }
   205  
   206  // Deprecated: Use ProbeRequest_Option.ProtoReflect.Descriptor instead.
   207  func (*ProbeRequest_Option) Descriptor() ([]byte, []int) {
   208  	return file_github_com_google_cloudprober_probes_external_proto_server_proto_rawDescGZIP(), []int{0, 0}
   209  }
   210  
   211  func (x *ProbeRequest_Option) GetName() string {
   212  	if x != nil && x.Name != nil {
   213  		return *x.Name
   214  	}
   215  	return ""
   216  }
   217  
   218  func (x *ProbeRequest_Option) GetValue() string {
   219  	if x != nil && x.Value != nil {
   220  		return *x.Value
   221  	}
   222  	return ""
   223  }
   224  
   225  var File_github_com_google_cloudprober_probes_external_proto_server_proto protoreflect.FileDescriptor
   226  
   227  var file_github_com_google_cloudprober_probes_external_proto_server_proto_rawDesc = []byte{
   228  	0x0a, 0x40, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x67, 0x6f, 0x6f,
   229  	0x67, 0x6c, 0x65, 0x2f, 0x63, 0x6c, 0x6f, 0x75, 0x64, 0x70, 0x72, 0x6f, 0x62, 0x65, 0x72, 0x2f,
   230  	0x70, 0x72, 0x6f, 0x62, 0x65, 0x73, 0x2f, 0x65, 0x78, 0x74, 0x65, 0x72, 0x6e, 0x61, 0x6c, 0x2f,
   231  	0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x73, 0x65, 0x72, 0x76, 0x65, 0x72, 0x2e, 0x70, 0x72, 0x6f,
   232  	0x74, 0x6f, 0x12, 0x0b, 0x63, 0x6c, 0x6f, 0x75, 0x64, 0x70, 0x72, 0x6f, 0x62, 0x65, 0x72, 0x22,
   233  	0xbc, 0x01, 0x0a, 0x0c, 0x50, 0x72, 0x6f, 0x62, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74,
   234  	0x12, 0x1d, 0x0a, 0x0a, 0x72, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x5f, 0x69, 0x64, 0x18, 0x01,
   235  	0x20, 0x02, 0x28, 0x05, 0x52, 0x09, 0x72, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x49, 0x64, 0x12,
   236  	0x1d, 0x0a, 0x0a, 0x74, 0x69, 0x6d, 0x65, 0x5f, 0x6c, 0x69, 0x6d, 0x69, 0x74, 0x18, 0x02, 0x20,
   237  	0x02, 0x28, 0x05, 0x52, 0x09, 0x74, 0x69, 0x6d, 0x65, 0x4c, 0x69, 0x6d, 0x69, 0x74, 0x12, 0x3a,
   238  	0x0a, 0x07, 0x6f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32,
   239  	0x20, 0x2e, 0x63, 0x6c, 0x6f, 0x75, 0x64, 0x70, 0x72, 0x6f, 0x62, 0x65, 0x72, 0x2e, 0x50, 0x72,
   240  	0x6f, 0x62, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x2e, 0x4f, 0x70, 0x74, 0x69, 0x6f,
   241  	0x6e, 0x52, 0x07, 0x6f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x1a, 0x32, 0x0a, 0x06, 0x4f, 0x70,
   242  	0x74, 0x69, 0x6f, 0x6e, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x02,
   243  	0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75,
   244  	0x65, 0x18, 0x02, 0x20, 0x02, 0x28, 0x09, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x22, 0x6a,
   245  	0x0a, 0x0a, 0x50, 0x72, 0x6f, 0x62, 0x65, 0x52, 0x65, 0x70, 0x6c, 0x79, 0x12, 0x1d, 0x0a, 0x0a,
   246  	0x72, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x5f, 0x69, 0x64, 0x18, 0x01, 0x20, 0x02, 0x28, 0x05,
   247  	0x52, 0x09, 0x72, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x49, 0x64, 0x12, 0x23, 0x0a, 0x0d, 0x65,
   248  	0x72, 0x72, 0x6f, 0x72, 0x5f, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x18, 0x02, 0x20, 0x01,
   249  	0x28, 0x09, 0x52, 0x0c, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65,
   250  	0x12, 0x18, 0x0a, 0x07, 0x70, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28,
   251  	0x09, 0x52, 0x07, 0x70, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x42, 0x35, 0x5a, 0x33, 0x67, 0x69,
   252  	0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f,
   253  	0x63, 0x6c, 0x6f, 0x75, 0x64, 0x70, 0x72, 0x6f, 0x62, 0x65, 0x72, 0x2f, 0x70, 0x72, 0x6f, 0x62,
   254  	0x65, 0x73, 0x2f, 0x65, 0x78, 0x74, 0x65, 0x72, 0x6e, 0x61, 0x6c, 0x2f, 0x70, 0x72, 0x6f, 0x74,
   255  	0x6f,
   256  }
   257  
   258  var (
   259  	file_github_com_google_cloudprober_probes_external_proto_server_proto_rawDescOnce sync.Once
   260  	file_github_com_google_cloudprober_probes_external_proto_server_proto_rawDescData = file_github_com_google_cloudprober_probes_external_proto_server_proto_rawDesc
   261  )
   262  
   263  func file_github_com_google_cloudprober_probes_external_proto_server_proto_rawDescGZIP() []byte {
   264  	file_github_com_google_cloudprober_probes_external_proto_server_proto_rawDescOnce.Do(func() {
   265  		file_github_com_google_cloudprober_probes_external_proto_server_proto_rawDescData = protoimpl.X.CompressGZIP(file_github_com_google_cloudprober_probes_external_proto_server_proto_rawDescData)
   266  	})
   267  	return file_github_com_google_cloudprober_probes_external_proto_server_proto_rawDescData
   268  }
   269  
   270  var file_github_com_google_cloudprober_probes_external_proto_server_proto_msgTypes = make([]protoimpl.MessageInfo, 3)
   271  var file_github_com_google_cloudprober_probes_external_proto_server_proto_goTypes = []interface{}{
   272  	(*ProbeRequest)(nil),        // 0: cloudprober.ProbeRequest
   273  	(*ProbeReply)(nil),          // 1: cloudprober.ProbeReply
   274  	(*ProbeRequest_Option)(nil), // 2: cloudprober.ProbeRequest.Option
   275  }
   276  var file_github_com_google_cloudprober_probes_external_proto_server_proto_depIdxs = []int32{
   277  	2, // 0: cloudprober.ProbeRequest.options:type_name -> cloudprober.ProbeRequest.Option
   278  	1, // [1:1] is the sub-list for method output_type
   279  	1, // [1:1] is the sub-list for method input_type
   280  	1, // [1:1] is the sub-list for extension type_name
   281  	1, // [1:1] is the sub-list for extension extendee
   282  	0, // [0:1] is the sub-list for field type_name
   283  }
   284  
   285  func init() { file_github_com_google_cloudprober_probes_external_proto_server_proto_init() }
   286  func file_github_com_google_cloudprober_probes_external_proto_server_proto_init() {
   287  	if File_github_com_google_cloudprober_probes_external_proto_server_proto != nil {
   288  		return
   289  	}
   290  	if !protoimpl.UnsafeEnabled {
   291  		file_github_com_google_cloudprober_probes_external_proto_server_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} {
   292  			switch v := v.(*ProbeRequest); i {
   293  			case 0:
   294  				return &v.state
   295  			case 1:
   296  				return &v.sizeCache
   297  			case 2:
   298  				return &v.unknownFields
   299  			default:
   300  				return nil
   301  			}
   302  		}
   303  		file_github_com_google_cloudprober_probes_external_proto_server_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} {
   304  			switch v := v.(*ProbeReply); i {
   305  			case 0:
   306  				return &v.state
   307  			case 1:
   308  				return &v.sizeCache
   309  			case 2:
   310  				return &v.unknownFields
   311  			default:
   312  				return nil
   313  			}
   314  		}
   315  		file_github_com_google_cloudprober_probes_external_proto_server_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} {
   316  			switch v := v.(*ProbeRequest_Option); i {
   317  			case 0:
   318  				return &v.state
   319  			case 1:
   320  				return &v.sizeCache
   321  			case 2:
   322  				return &v.unknownFields
   323  			default:
   324  				return nil
   325  			}
   326  		}
   327  	}
   328  	type x struct{}
   329  	out := protoimpl.TypeBuilder{
   330  		File: protoimpl.DescBuilder{
   331  			GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
   332  			RawDescriptor: file_github_com_google_cloudprober_probes_external_proto_server_proto_rawDesc,
   333  			NumEnums:      0,
   334  			NumMessages:   3,
   335  			NumExtensions: 0,
   336  			NumServices:   0,
   337  		},
   338  		GoTypes:           file_github_com_google_cloudprober_probes_external_proto_server_proto_goTypes,
   339  		DependencyIndexes: file_github_com_google_cloudprober_probes_external_proto_server_proto_depIdxs,
   340  		MessageInfos:      file_github_com_google_cloudprober_probes_external_proto_server_proto_msgTypes,
   341  	}.Build()
   342  	File_github_com_google_cloudprober_probes_external_proto_server_proto = out.File
   343  	file_github_com_google_cloudprober_probes_external_proto_server_proto_rawDesc = nil
   344  	file_github_com_google_cloudprober_probes_external_proto_server_proto_goTypes = nil
   345  	file_github_com_google_cloudprober_probes_external_proto_server_proto_depIdxs = nil
   346  }