blob: 33ebeeec392420d5b543f3e7441ccb9a4a60309e [file] [log] [blame]
// Copyright 2018 The Goma Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
// Code generated by protoc-gen-go. DO NOT EDIT.
// versions:
// protoc-gen-go v1.25.0
// protoc v3.13.0
// source: exec/exec_service.proto
package exec
import (
context "context"
proto "github.com/golang/protobuf/proto"
api "go.chromium.org/goma/server/proto/api"
grpc "google.golang.org/grpc"
codes "google.golang.org/grpc/codes"
status "google.golang.org/grpc/status"
protoreflect "google.golang.org/protobuf/reflect/protoreflect"
protoimpl "google.golang.org/protobuf/runtime/protoimpl"
reflect "reflect"
sync "sync"
)
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)
)
// This is a compile-time assertion that a sufficiently up-to-date version
// of the legacy proto package is being used.
const _ = proto.ProtoPackageIsVersion4
// TODO: reconsider good error codes.
type ExecServiceApplicationError int32
const (
ExecServiceApplicationError_BAD_REQUEST ExecServiceApplicationError = -1
ExecServiceApplicationError_EXEC_OK ExecServiceApplicationError = 0
ExecServiceApplicationError_EXECUTABLE_NOT_READY ExecServiceApplicationError = 1
ExecServiceApplicationError_DISK_EXCEEDED ExecServiceApplicationError = 2
ExecServiceApplicationError_EXEC_INTERNAL_ERROR ExecServiceApplicationError = 3
ExecServiceApplicationError_EXECUTOR_IS_LOADING ExecServiceApplicationError = 4
ExecServiceApplicationError_EXECUTOR_MEMORY_NOT_ENOUGH ExecServiceApplicationError = 5
)
// Enum value maps for ExecServiceApplicationError.
var (
ExecServiceApplicationError_name = map[int32]string{
-1: "BAD_REQUEST",
0: "EXEC_OK",
1: "EXECUTABLE_NOT_READY",
2: "DISK_EXCEEDED",
3: "EXEC_INTERNAL_ERROR",
4: "EXECUTOR_IS_LOADING",
5: "EXECUTOR_MEMORY_NOT_ENOUGH",
}
ExecServiceApplicationError_value = map[string]int32{
"BAD_REQUEST": -1,
"EXEC_OK": 0,
"EXECUTABLE_NOT_READY": 1,
"DISK_EXCEEDED": 2,
"EXEC_INTERNAL_ERROR": 3,
"EXECUTOR_IS_LOADING": 4,
"EXECUTOR_MEMORY_NOT_ENOUGH": 5,
}
)
func (x ExecServiceApplicationError) Enum() *ExecServiceApplicationError {
p := new(ExecServiceApplicationError)
*p = x
return p
}
func (x ExecServiceApplicationError) String() string {
return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x))
}
func (ExecServiceApplicationError) Descriptor() protoreflect.EnumDescriptor {
return file_exec_exec_service_proto_enumTypes[0].Descriptor()
}
func (ExecServiceApplicationError) Type() protoreflect.EnumType {
return &file_exec_exec_service_proto_enumTypes[0]
}
func (x ExecServiceApplicationError) Number() protoreflect.EnumNumber {
return protoreflect.EnumNumber(x)
}
// Deprecated: Do not use.
func (x *ExecServiceApplicationError) UnmarshalJSON(b []byte) error {
num, err := protoimpl.X.UnmarshalJSONEnum(x.Descriptor(), b)
if err != nil {
return err
}
*x = ExecServiceApplicationError(num)
return nil
}
// Deprecated: Use ExecServiceApplicationError.Descriptor instead.
func (ExecServiceApplicationError) EnumDescriptor() ([]byte, []int) {
return file_exec_exec_service_proto_rawDescGZIP(), []int{0}
}
var File_exec_exec_service_proto protoreflect.FileDescriptor
var file_exec_exec_service_proto_rawDesc = []byte{
0x0a, 0x17, 0x65, 0x78, 0x65, 0x63, 0x2f, 0x65, 0x78, 0x65, 0x63, 0x5f, 0x73, 0x65, 0x72, 0x76,
0x69, 0x63, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x0d, 0x64, 0x65, 0x76, 0x74, 0x6f,
0x6f, 0x6c, 0x73, 0x5f, 0x67, 0x6f, 0x6d, 0x61, 0x1a, 0x13, 0x61, 0x70, 0x69, 0x2f, 0x67, 0x6f,
0x6d, 0x61, 0x5f, 0x64, 0x61, 0x74, 0x61, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2a, 0xc3, 0x01,
0x0a, 0x1b, 0x45, 0x78, 0x65, 0x63, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x41, 0x70, 0x70,
0x6c, 0x69, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x12, 0x18, 0x0a,
0x0b, 0x42, 0x41, 0x44, 0x5f, 0x52, 0x45, 0x51, 0x55, 0x45, 0x53, 0x54, 0x10, 0xff, 0xff, 0xff,
0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0x12, 0x0b, 0x0a, 0x07, 0x45, 0x58, 0x45, 0x43, 0x5f,
0x4f, 0x4b, 0x10, 0x00, 0x12, 0x18, 0x0a, 0x14, 0x45, 0x58, 0x45, 0x43, 0x55, 0x54, 0x41, 0x42,
0x4c, 0x45, 0x5f, 0x4e, 0x4f, 0x54, 0x5f, 0x52, 0x45, 0x41, 0x44, 0x59, 0x10, 0x01, 0x12, 0x11,
0x0a, 0x0d, 0x44, 0x49, 0x53, 0x4b, 0x5f, 0x45, 0x58, 0x43, 0x45, 0x45, 0x44, 0x45, 0x44, 0x10,
0x02, 0x12, 0x17, 0x0a, 0x13, 0x45, 0x58, 0x45, 0x43, 0x5f, 0x49, 0x4e, 0x54, 0x45, 0x52, 0x4e,
0x41, 0x4c, 0x5f, 0x45, 0x52, 0x52, 0x4f, 0x52, 0x10, 0x03, 0x12, 0x17, 0x0a, 0x13, 0x45, 0x58,
0x45, 0x43, 0x55, 0x54, 0x4f, 0x52, 0x5f, 0x49, 0x53, 0x5f, 0x4c, 0x4f, 0x41, 0x44, 0x49, 0x4e,
0x47, 0x10, 0x04, 0x12, 0x1e, 0x0a, 0x1a, 0x45, 0x58, 0x45, 0x43, 0x55, 0x54, 0x4f, 0x52, 0x5f,
0x4d, 0x45, 0x4d, 0x4f, 0x52, 0x59, 0x5f, 0x4e, 0x4f, 0x54, 0x5f, 0x45, 0x4e, 0x4f, 0x55, 0x47,
0x48, 0x10, 0x05, 0x32, 0x48, 0x0a, 0x0b, 0x45, 0x78, 0x65, 0x63, 0x53, 0x65, 0x72, 0x76, 0x69,
0x63, 0x65, 0x12, 0x39, 0x0a, 0x04, 0x45, 0x78, 0x65, 0x63, 0x12, 0x16, 0x2e, 0x64, 0x65, 0x76,
0x74, 0x6f, 0x6f, 0x6c, 0x73, 0x5f, 0x67, 0x6f, 0x6d, 0x61, 0x2e, 0x45, 0x78, 0x65, 0x63, 0x52,
0x65, 0x71, 0x1a, 0x17, 0x2e, 0x64, 0x65, 0x76, 0x74, 0x6f, 0x6f, 0x6c, 0x73, 0x5f, 0x67, 0x6f,
0x6d, 0x61, 0x2e, 0x45, 0x78, 0x65, 0x63, 0x52, 0x65, 0x73, 0x70, 0x22, 0x00, 0x42, 0x31, 0x5a,
0x26, 0x67, 0x6f, 0x2e, 0x63, 0x68, 0x72, 0x6f, 0x6d, 0x69, 0x75, 0x6d, 0x2e, 0x6f, 0x72, 0x67,
0x2f, 0x67, 0x6f, 0x6d, 0x61, 0x2f, 0x73, 0x65, 0x72, 0x76, 0x65, 0x72, 0x2f, 0x70, 0x72, 0x6f,
0x74, 0x6f, 0x2f, 0x65, 0x78, 0x65, 0x63, 0x80, 0x01, 0x00, 0x88, 0x01, 0x00, 0x90, 0x01, 0x00,
}
var (
file_exec_exec_service_proto_rawDescOnce sync.Once
file_exec_exec_service_proto_rawDescData = file_exec_exec_service_proto_rawDesc
)
func file_exec_exec_service_proto_rawDescGZIP() []byte {
file_exec_exec_service_proto_rawDescOnce.Do(func() {
file_exec_exec_service_proto_rawDescData = protoimpl.X.CompressGZIP(file_exec_exec_service_proto_rawDescData)
})
return file_exec_exec_service_proto_rawDescData
}
var file_exec_exec_service_proto_enumTypes = make([]protoimpl.EnumInfo, 1)
var file_exec_exec_service_proto_goTypes = []interface{}{
(ExecServiceApplicationError)(0), // 0: devtools_goma.ExecServiceApplicationError
(*api.ExecReq)(nil), // 1: devtools_goma.ExecReq
(*api.ExecResp)(nil), // 2: devtools_goma.ExecResp
}
var file_exec_exec_service_proto_depIdxs = []int32{
1, // 0: devtools_goma.ExecService.Exec:input_type -> devtools_goma.ExecReq
2, // 1: devtools_goma.ExecService.Exec:output_type -> devtools_goma.ExecResp
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_exec_exec_service_proto_init() }
func file_exec_exec_service_proto_init() {
if File_exec_exec_service_proto != nil {
return
}
type x struct{}
out := protoimpl.TypeBuilder{
File: protoimpl.DescBuilder{
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
RawDescriptor: file_exec_exec_service_proto_rawDesc,
NumEnums: 1,
NumMessages: 0,
NumExtensions: 0,
NumServices: 1,
},
GoTypes: file_exec_exec_service_proto_goTypes,
DependencyIndexes: file_exec_exec_service_proto_depIdxs,
EnumInfos: file_exec_exec_service_proto_enumTypes,
}.Build()
File_exec_exec_service_proto = out.File
file_exec_exec_service_proto_rawDesc = nil
file_exec_exec_service_proto_goTypes = nil
file_exec_exec_service_proto_depIdxs = nil
}
// Reference imports to suppress errors if they are not otherwise used.
var _ context.Context
var _ grpc.ClientConnInterface
// This is a compile-time assertion to ensure that this generated file
// is compatible with the grpc package it is being compiled against.
const _ = grpc.SupportPackageIsVersion6
// ExecServiceClient is the client API for ExecService service.
//
// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
type ExecServiceClient interface {
Exec(ctx context.Context, in *api.ExecReq, opts ...grpc.CallOption) (*api.ExecResp, error)
}
type execServiceClient struct {
cc grpc.ClientConnInterface
}
func NewExecServiceClient(cc grpc.ClientConnInterface) ExecServiceClient {
return &execServiceClient{cc}
}
func (c *execServiceClient) Exec(ctx context.Context, in *api.ExecReq, opts ...grpc.CallOption) (*api.ExecResp, error) {
out := new(api.ExecResp)
err := c.cc.Invoke(ctx, "/devtools_goma.ExecService/Exec", in, out, opts...)
if err != nil {
return nil, err
}
return out, nil
}
// ExecServiceServer is the server API for ExecService service.
type ExecServiceServer interface {
Exec(context.Context, *api.ExecReq) (*api.ExecResp, error)
}
// UnimplementedExecServiceServer can be embedded to have forward compatible implementations.
type UnimplementedExecServiceServer struct {
}
func (*UnimplementedExecServiceServer) Exec(context.Context, *api.ExecReq) (*api.ExecResp, error) {
return nil, status.Errorf(codes.Unimplemented, "method Exec not implemented")
}
func RegisterExecServiceServer(s *grpc.Server, srv ExecServiceServer) {
s.RegisterService(&_ExecService_serviceDesc, srv)
}
func _ExecService_Exec_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(api.ExecReq)
if err := dec(in); err != nil {
return nil, err
}
if interceptor == nil {
return srv.(ExecServiceServer).Exec(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: "/devtools_goma.ExecService/Exec",
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(ExecServiceServer).Exec(ctx, req.(*api.ExecReq))
}
return interceptor(ctx, in, info, handler)
}
var _ExecService_serviceDesc = grpc.ServiceDesc{
ServiceName: "devtools_goma.ExecService",
HandlerType: (*ExecServiceServer)(nil),
Methods: []grpc.MethodDesc{
{
MethodName: "Exec",
Handler: _ExecService_Exec_Handler,
},
},
Streams: []grpc.StreamDesc{},
Metadata: "exec/exec_service.proto",
}