Documentation ¶
Index ¶
- Variables
- func RegisterMapReduceServiceServer(s grpc.ServiceRegistrar, srv MapReduceServiceServer)
- type MapReduceServiceClient
- type MapReduceServiceServer
- type MapReduceTask
- func (*MapReduceTask) Descriptor() ([]byte, []int)deprecated
- func (x *MapReduceTask) GetInput() string
- func (x *MapReduceTask) GetIntermediates() []string
- func (x *MapReduceTask) GetNReducer() int64
- func (x *MapReduceTask) GetOutput() string
- func (x *MapReduceTask) GetTaskNumber() int64
- func (x *MapReduceTask) GetTaskState() int64
- func (*MapReduceTask) ProtoMessage()
- func (x *MapReduceTask) ProtoReflect() protoreflect.Message
- func (x *MapReduceTask) Reset()
- func (x *MapReduceTask) String() string
- type MasterTaskCompletedResp
- func (*MasterTaskCompletedResp) Descriptor() ([]byte, []int)deprecated
- func (x *MasterTaskCompletedResp) GetCode() int64
- func (x *MasterTaskCompletedResp) GetMessage() string
- func (*MasterTaskCompletedResp) ProtoMessage()
- func (x *MasterTaskCompletedResp) ProtoReflect() protoreflect.Message
- func (x *MasterTaskCompletedResp) Reset()
- func (x *MasterTaskCompletedResp) String() string
- type UnimplementedMapReduceServiceServer
- type UnsafeMapReduceServiceServer
Constants ¶
This section is empty.
Variables ¶
var File_mapreduce_proto protoreflect.FileDescriptor
var MapReduceService_ServiceDesc = grpc.ServiceDesc{ ServiceName: "MapReduceService", HandlerType: (*MapReduceServiceServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "MasterAssignTask", Handler: _MapReduceService_MasterAssignTask_Handler, }, { MethodName: "MasterTaskCompleted", Handler: _MapReduceService_MasterTaskCompleted_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "mapreduce.proto", }
MapReduceService_ServiceDesc is the grpc.ServiceDesc for MapReduceService service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
Functions ¶
func RegisterMapReduceServiceServer ¶
func RegisterMapReduceServiceServer(s grpc.ServiceRegistrar, srv MapReduceServiceServer)
Types ¶
type MapReduceServiceClient ¶
type MapReduceServiceClient interface { MasterAssignTask(ctx context.Context, in *MapReduceTask, opts ...grpc.CallOption) (*MapReduceTask, error) MasterTaskCompleted(ctx context.Context, in *MapReduceTask, opts ...grpc.CallOption) (*MasterTaskCompletedResp, error) }
MapReduceServiceClient is the client API for MapReduceService 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.
func NewMapReduceServiceClient ¶
func NewMapReduceServiceClient(cc grpc.ClientConnInterface) MapReduceServiceClient
type MapReduceServiceServer ¶
type MapReduceServiceServer interface { MasterAssignTask(context.Context, *MapReduceTask) (*MapReduceTask, error) MasterTaskCompleted(context.Context, *MapReduceTask) (*MasterTaskCompletedResp, error) // contains filtered or unexported methods }
MapReduceServiceServer is the server API for MapReduceService service. All implementations must embed UnimplementedMapReduceServiceServer for forward compatibility
type MapReduceTask ¶
type MapReduceTask struct { // @inject_tag:form:"input" uri:"input" Input string `protobuf:"bytes,1,opt,name=input,proto3" json:"input,omitempty" form:"input" uri:"input"` // @inject_tag:form:"task_state" uri:"task_state" TaskState int64 `protobuf:"varint,2,opt,name=task_state,json=taskState,proto3" json:"task_state,omitempty" form:"task_state" uri:"task_state"` // @inject_tag:form:"n_reducer" uri:"n_reducer" NReducer int64 `protobuf:"varint,3,opt,name=n_reducer,json=nReducer,proto3" json:"n_reducer,omitempty" form:"n_reducer" uri:"n_reducer"` // @inject_tag:form:"task_number" uri:"task_number" TaskNumber int64 `` /* 129-byte string literal not displayed */ // @inject_tag:form:"intermediates" uri:"intermediates" Intermediates []string `protobuf:"bytes,5,rep,name=intermediates,proto3" json:"intermediates,omitempty" form:"intermediates" uri:"intermediates"` // @inject_tag:form:"output" uri:"output" Output string `protobuf:"bytes,6,opt,name=output,proto3" json:"output,omitempty" form:"output" uri:"output"` // contains filtered or unexported fields }
func (*MapReduceTask) Descriptor
deprecated
func (*MapReduceTask) Descriptor() ([]byte, []int)
Deprecated: Use MapReduceTask.ProtoReflect.Descriptor instead.
func (*MapReduceTask) GetInput ¶
func (x *MapReduceTask) GetInput() string
func (*MapReduceTask) GetIntermediates ¶
func (x *MapReduceTask) GetIntermediates() []string
func (*MapReduceTask) GetNReducer ¶
func (x *MapReduceTask) GetNReducer() int64
func (*MapReduceTask) GetOutput ¶
func (x *MapReduceTask) GetOutput() string
func (*MapReduceTask) GetTaskNumber ¶
func (x *MapReduceTask) GetTaskNumber() int64
func (*MapReduceTask) GetTaskState ¶
func (x *MapReduceTask) GetTaskState() int64
func (*MapReduceTask) ProtoMessage ¶
func (*MapReduceTask) ProtoMessage()
func (*MapReduceTask) ProtoReflect ¶
func (x *MapReduceTask) ProtoReflect() protoreflect.Message
func (*MapReduceTask) Reset ¶
func (x *MapReduceTask) Reset()
func (*MapReduceTask) String ¶
func (x *MapReduceTask) String() string
type MasterTaskCompletedResp ¶
type MasterTaskCompletedResp struct { // @inject_tag:form:"code" uri:"code" Code int64 `protobuf:"varint,1,opt,name=code,proto3" json:"code,omitempty" form:"code" uri:"code"` // @inject_tag:form:"message" uri:"message" Message string `protobuf:"bytes,2,opt,name=message,proto3" json:"message,omitempty" form:"message" uri:"message"` // contains filtered or unexported fields }
func (*MasterTaskCompletedResp) Descriptor
deprecated
func (*MasterTaskCompletedResp) Descriptor() ([]byte, []int)
Deprecated: Use MasterTaskCompletedResp.ProtoReflect.Descriptor instead.
func (*MasterTaskCompletedResp) GetCode ¶
func (x *MasterTaskCompletedResp) GetCode() int64
func (*MasterTaskCompletedResp) GetMessage ¶
func (x *MasterTaskCompletedResp) GetMessage() string
func (*MasterTaskCompletedResp) ProtoMessage ¶
func (*MasterTaskCompletedResp) ProtoMessage()
func (*MasterTaskCompletedResp) ProtoReflect ¶
func (x *MasterTaskCompletedResp) ProtoReflect() protoreflect.Message
func (*MasterTaskCompletedResp) Reset ¶
func (x *MasterTaskCompletedResp) Reset()
func (*MasterTaskCompletedResp) String ¶
func (x *MasterTaskCompletedResp) String() string
type UnimplementedMapReduceServiceServer ¶
type UnimplementedMapReduceServiceServer struct { }
UnimplementedMapReduceServiceServer must be embedded to have forward compatible implementations.
func (UnimplementedMapReduceServiceServer) MasterAssignTask ¶
func (UnimplementedMapReduceServiceServer) MasterAssignTask(context.Context, *MapReduceTask) (*MapReduceTask, error)
func (UnimplementedMapReduceServiceServer) MasterTaskCompleted ¶
func (UnimplementedMapReduceServiceServer) MasterTaskCompleted(context.Context, *MapReduceTask) (*MasterTaskCompletedResp, error)
type UnsafeMapReduceServiceServer ¶
type UnsafeMapReduceServiceServer interface {
// contains filtered or unexported methods
}
UnsafeMapReduceServiceServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to MapReduceServiceServer will result in compilation errors.