| @@ -1,4 +1,4 @@ | |||
| Name: slurmshuguang.rpc | |||
| Name: hpcac.rpc | |||
| ListenOn: 0.0.0.0:2001 | |||
| ClusterUrl: "https://api01.hpccube.com:65106/hpc/openapi/v2/cluster" | |||
| @@ -2,9 +2,9 @@ | |||
| // versions: | |||
| // protoc-gen-go v1.28.1 | |||
| // protoc v3.19.4 | |||
| // source: slurmShuguang.proto | |||
| // source: hpcAC.proto | |||
| package slurmShuguang | |||
| package hpcAC | |||
| import ( | |||
| protoreflect "google.golang.org/protobuf/reflect/protoreflect" | |||
| @@ -48,7 +48,7 @@ type Job struct { | |||
| func (x *Job) Reset() { | |||
| *x = Job{} | |||
| if protoimpl.UnsafeEnabled { | |||
| mi := &file_slurmShuguang_proto_msgTypes[0] | |||
| mi := &file_hpcAC_proto_msgTypes[0] | |||
| ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) | |||
| ms.StoreMessageInfo(mi) | |||
| } | |||
| @@ -61,7 +61,7 @@ func (x *Job) String() string { | |||
| func (*Job) ProtoMessage() {} | |||
| func (x *Job) ProtoReflect() protoreflect.Message { | |||
| mi := &file_slurmShuguang_proto_msgTypes[0] | |||
| mi := &file_hpcAC_proto_msgTypes[0] | |||
| if protoimpl.UnsafeEnabled && x != nil { | |||
| ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) | |||
| if ms.LoadMessageInfo() == nil { | |||
| @@ -74,7 +74,7 @@ func (x *Job) ProtoReflect() protoreflect.Message { | |||
| // Deprecated: Use Job.ProtoReflect.Descriptor instead. | |||
| func (*Job) Descriptor() ([]byte, []int) { | |||
| return file_slurmShuguang_proto_rawDescGZIP(), []int{0} | |||
| return file_hpcAC_proto_rawDescGZIP(), []int{0} | |||
| } | |||
| func (x *Job) GetJobId() string { | |||
| @@ -205,7 +205,7 @@ type ListJobReq struct { | |||
| func (x *ListJobReq) Reset() { | |||
| *x = ListJobReq{} | |||
| if protoimpl.UnsafeEnabled { | |||
| mi := &file_slurmShuguang_proto_msgTypes[1] | |||
| mi := &file_hpcAC_proto_msgTypes[1] | |||
| ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) | |||
| ms.StoreMessageInfo(mi) | |||
| } | |||
| @@ -218,7 +218,7 @@ func (x *ListJobReq) String() string { | |||
| func (*ListJobReq) ProtoMessage() {} | |||
| func (x *ListJobReq) ProtoReflect() protoreflect.Message { | |||
| mi := &file_slurmShuguang_proto_msgTypes[1] | |||
| mi := &file_hpcAC_proto_msgTypes[1] | |||
| if protoimpl.UnsafeEnabled && x != nil { | |||
| ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) | |||
| if ms.LoadMessageInfo() == nil { | |||
| @@ -231,7 +231,7 @@ func (x *ListJobReq) ProtoReflect() protoreflect.Message { | |||
| // Deprecated: Use ListJobReq.ProtoReflect.Descriptor instead. | |||
| func (*ListJobReq) Descriptor() ([]byte, []int) { | |||
| return file_slurmShuguang_proto_rawDescGZIP(), []int{1} | |||
| return file_hpcAC_proto_rawDescGZIP(), []int{1} | |||
| } | |||
| type ListJobResp struct { | |||
| @@ -248,7 +248,7 @@ type ListJobResp struct { | |||
| func (x *ListJobResp) Reset() { | |||
| *x = ListJobResp{} | |||
| if protoimpl.UnsafeEnabled { | |||
| mi := &file_slurmShuguang_proto_msgTypes[2] | |||
| mi := &file_hpcAC_proto_msgTypes[2] | |||
| ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) | |||
| ms.StoreMessageInfo(mi) | |||
| } | |||
| @@ -261,7 +261,7 @@ func (x *ListJobResp) String() string { | |||
| func (*ListJobResp) ProtoMessage() {} | |||
| func (x *ListJobResp) ProtoReflect() protoreflect.Message { | |||
| mi := &file_slurmShuguang_proto_msgTypes[2] | |||
| mi := &file_hpcAC_proto_msgTypes[2] | |||
| if protoimpl.UnsafeEnabled && x != nil { | |||
| ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) | |||
| if ms.LoadMessageInfo() == nil { | |||
| @@ -274,7 +274,7 @@ func (x *ListJobResp) ProtoReflect() protoreflect.Message { | |||
| // Deprecated: Use ListJobResp.ProtoReflect.Descriptor instead. | |||
| func (*ListJobResp) Descriptor() ([]byte, []int) { | |||
| return file_slurmShuguang_proto_rawDescGZIP(), []int{2} | |||
| return file_hpcAC_proto_rawDescGZIP(), []int{2} | |||
| } | |||
| func (x *ListJobResp) GetCode() uint32 { | |||
| @@ -332,7 +332,7 @@ type HistoryJob struct { | |||
| func (x *HistoryJob) Reset() { | |||
| *x = HistoryJob{} | |||
| if protoimpl.UnsafeEnabled { | |||
| mi := &file_slurmShuguang_proto_msgTypes[3] | |||
| mi := &file_hpcAC_proto_msgTypes[3] | |||
| ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) | |||
| ms.StoreMessageInfo(mi) | |||
| } | |||
| @@ -345,7 +345,7 @@ func (x *HistoryJob) String() string { | |||
| func (*HistoryJob) ProtoMessage() {} | |||
| func (x *HistoryJob) ProtoReflect() protoreflect.Message { | |||
| mi := &file_slurmShuguang_proto_msgTypes[3] | |||
| mi := &file_hpcAC_proto_msgTypes[3] | |||
| if protoimpl.UnsafeEnabled && x != nil { | |||
| ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) | |||
| if ms.LoadMessageInfo() == nil { | |||
| @@ -358,7 +358,7 @@ func (x *HistoryJob) ProtoReflect() protoreflect.Message { | |||
| // Deprecated: Use HistoryJob.ProtoReflect.Descriptor instead. | |||
| func (*HistoryJob) Descriptor() ([]byte, []int) { | |||
| return file_slurmShuguang_proto_rawDescGZIP(), []int{3} | |||
| return file_hpcAC_proto_rawDescGZIP(), []int{3} | |||
| } | |||
| func (x *HistoryJob) GetAcctTime() string { | |||
| @@ -489,7 +489,7 @@ type ListHistoryJobReq struct { | |||
| func (x *ListHistoryJobReq) Reset() { | |||
| *x = ListHistoryJobReq{} | |||
| if protoimpl.UnsafeEnabled { | |||
| mi := &file_slurmShuguang_proto_msgTypes[4] | |||
| mi := &file_hpcAC_proto_msgTypes[4] | |||
| ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) | |||
| ms.StoreMessageInfo(mi) | |||
| } | |||
| @@ -502,7 +502,7 @@ func (x *ListHistoryJobReq) String() string { | |||
| func (*ListHistoryJobReq) ProtoMessage() {} | |||
| func (x *ListHistoryJobReq) ProtoReflect() protoreflect.Message { | |||
| mi := &file_slurmShuguang_proto_msgTypes[4] | |||
| mi := &file_hpcAC_proto_msgTypes[4] | |||
| if protoimpl.UnsafeEnabled && x != nil { | |||
| ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) | |||
| if ms.LoadMessageInfo() == nil { | |||
| @@ -515,7 +515,7 @@ func (x *ListHistoryJobReq) ProtoReflect() protoreflect.Message { | |||
| // Deprecated: Use ListHistoryJobReq.ProtoReflect.Descriptor instead. | |||
| func (*ListHistoryJobReq) Descriptor() ([]byte, []int) { | |||
| return file_slurmShuguang_proto_rawDescGZIP(), []int{4} | |||
| return file_hpcAC_proto_rawDescGZIP(), []int{4} | |||
| } | |||
| func (x *ListHistoryJobReq) GetStartTime() string { | |||
| @@ -574,7 +574,7 @@ type ListHistoryJobResp struct { | |||
| func (x *ListHistoryJobResp) Reset() { | |||
| *x = ListHistoryJobResp{} | |||
| if protoimpl.UnsafeEnabled { | |||
| mi := &file_slurmShuguang_proto_msgTypes[5] | |||
| mi := &file_hpcAC_proto_msgTypes[5] | |||
| ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) | |||
| ms.StoreMessageInfo(mi) | |||
| } | |||
| @@ -587,7 +587,7 @@ func (x *ListHistoryJobResp) String() string { | |||
| func (*ListHistoryJobResp) ProtoMessage() {} | |||
| func (x *ListHistoryJobResp) ProtoReflect() protoreflect.Message { | |||
| mi := &file_slurmShuguang_proto_msgTypes[5] | |||
| mi := &file_hpcAC_proto_msgTypes[5] | |||
| if protoimpl.UnsafeEnabled && x != nil { | |||
| ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) | |||
| if ms.LoadMessageInfo() == nil { | |||
| @@ -600,7 +600,7 @@ func (x *ListHistoryJobResp) ProtoReflect() protoreflect.Message { | |||
| // Deprecated: Use ListHistoryJobResp.ProtoReflect.Descriptor instead. | |||
| func (*ListHistoryJobResp) Descriptor() ([]byte, []int) { | |||
| return file_slurmShuguang_proto_rawDescGZIP(), []int{5} | |||
| return file_hpcAC_proto_rawDescGZIP(), []int{5} | |||
| } | |||
| func (x *ListHistoryJobResp) GetCode() uint32 { | |||
| @@ -646,7 +646,7 @@ type SubmitJobReq struct { | |||
| func (x *SubmitJobReq) Reset() { | |||
| *x = SubmitJobReq{} | |||
| if protoimpl.UnsafeEnabled { | |||
| mi := &file_slurmShuguang_proto_msgTypes[6] | |||
| mi := &file_hpcAC_proto_msgTypes[6] | |||
| ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) | |||
| ms.StoreMessageInfo(mi) | |||
| } | |||
| @@ -659,7 +659,7 @@ func (x *SubmitJobReq) String() string { | |||
| func (*SubmitJobReq) ProtoMessage() {} | |||
| func (x *SubmitJobReq) ProtoReflect() protoreflect.Message { | |||
| mi := &file_slurmShuguang_proto_msgTypes[6] | |||
| mi := &file_hpcAC_proto_msgTypes[6] | |||
| if protoimpl.UnsafeEnabled && x != nil { | |||
| ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) | |||
| if ms.LoadMessageInfo() == nil { | |||
| @@ -672,7 +672,7 @@ func (x *SubmitJobReq) ProtoReflect() protoreflect.Message { | |||
| // Deprecated: Use SubmitJobReq.ProtoReflect.Descriptor instead. | |||
| func (*SubmitJobReq) Descriptor() ([]byte, []int) { | |||
| return file_slurmShuguang_proto_rawDescGZIP(), []int{6} | |||
| return file_hpcAC_proto_rawDescGZIP(), []int{6} | |||
| } | |||
| func (x *SubmitJobReq) GetApptype() string { | |||
| @@ -716,7 +716,7 @@ type SubmitJobResp struct { | |||
| func (x *SubmitJobResp) Reset() { | |||
| *x = SubmitJobResp{} | |||
| if protoimpl.UnsafeEnabled { | |||
| mi := &file_slurmShuguang_proto_msgTypes[7] | |||
| mi := &file_hpcAC_proto_msgTypes[7] | |||
| ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) | |||
| ms.StoreMessageInfo(mi) | |||
| } | |||
| @@ -729,7 +729,7 @@ func (x *SubmitJobResp) String() string { | |||
| func (*SubmitJobResp) ProtoMessage() {} | |||
| func (x *SubmitJobResp) ProtoReflect() protoreflect.Message { | |||
| mi := &file_slurmShuguang_proto_msgTypes[7] | |||
| mi := &file_hpcAC_proto_msgTypes[7] | |||
| if protoimpl.UnsafeEnabled && x != nil { | |||
| ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) | |||
| if ms.LoadMessageInfo() == nil { | |||
| @@ -742,7 +742,7 @@ func (x *SubmitJobResp) ProtoReflect() protoreflect.Message { | |||
| // Deprecated: Use SubmitJobResp.ProtoReflect.Descriptor instead. | |||
| func (*SubmitJobResp) Descriptor() ([]byte, []int) { | |||
| return file_slurmShuguang_proto_rawDescGZIP(), []int{7} | |||
| return file_hpcAC_proto_rawDescGZIP(), []int{7} | |||
| } | |||
| func (x *SubmitJobResp) GetCode() string { | |||
| @@ -794,7 +794,7 @@ type MapAppJobInfo struct { | |||
| func (x *MapAppJobInfo) Reset() { | |||
| *x = MapAppJobInfo{} | |||
| if protoimpl.UnsafeEnabled { | |||
| mi := &file_slurmShuguang_proto_msgTypes[8] | |||
| mi := &file_hpcAC_proto_msgTypes[8] | |||
| ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) | |||
| ms.StoreMessageInfo(mi) | |||
| } | |||
| @@ -807,7 +807,7 @@ func (x *MapAppJobInfo) String() string { | |||
| func (*MapAppJobInfo) ProtoMessage() {} | |||
| func (x *MapAppJobInfo) ProtoReflect() protoreflect.Message { | |||
| mi := &file_slurmShuguang_proto_msgTypes[8] | |||
| mi := &file_hpcAC_proto_msgTypes[8] | |||
| if protoimpl.UnsafeEnabled && x != nil { | |||
| ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) | |||
| if ms.LoadMessageInfo() == nil { | |||
| @@ -820,7 +820,7 @@ func (x *MapAppJobInfo) ProtoReflect() protoreflect.Message { | |||
| // Deprecated: Use MapAppJobInfo.ProtoReflect.Descriptor instead. | |||
| func (*MapAppJobInfo) Descriptor() ([]byte, []int) { | |||
| return file_slurmShuguang_proto_rawDescGZIP(), []int{8} | |||
| return file_hpcAC_proto_rawDescGZIP(), []int{8} | |||
| } | |||
| func (x *MapAppJobInfo) GetGAP_CMD_FILE() string { | |||
| @@ -949,12 +949,11 @@ func (x *MapAppJobInfo) GetGAP_STD_ERR_FILE() string { | |||
| return "" | |||
| } | |||
| var File_slurmShuguang_proto protoreflect.FileDescriptor | |||
| var File_hpcAC_proto protoreflect.FileDescriptor | |||
| var file_slurmShuguang_proto_rawDesc = []byte{ | |||
| 0x0a, 0x13, 0x73, 0x6c, 0x75, 0x72, 0x6d, 0x53, 0x68, 0x75, 0x67, 0x75, 0x61, 0x6e, 0x67, 0x2e, | |||
| 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x0d, 0x73, 0x6c, 0x75, 0x72, 0x6d, 0x53, 0x68, 0x75, 0x67, | |||
| 0x75, 0x61, 0x6e, 0x67, 0x22, 0x91, 0x04, 0x0a, 0x03, 0x6a, 0x6f, 0x62, 0x12, 0x15, 0x0a, 0x06, | |||
| var file_hpcAC_proto_rawDesc = []byte{ | |||
| 0x0a, 0x0b, 0x68, 0x70, 0x63, 0x41, 0x43, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x05, 0x68, | |||
| 0x70, 0x63, 0x41, 0x43, 0x22, 0x91, 0x04, 0x0a, 0x03, 0x6a, 0x6f, 0x62, 0x12, 0x15, 0x0a, 0x06, | |||
| 0x6a, 0x6f, 0x62, 0x5f, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x6a, 0x6f, | |||
| 0x62, 0x49, 0x64, 0x12, 0x19, 0x0a, 0x08, 0x6a, 0x6f, 0x62, 0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x18, | |||
| 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x6a, 0x6f, 0x62, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x1d, | |||
| @@ -988,177 +987,172 @@ var file_slurmShuguang_proto_rawDesc = []byte{ | |||
| 0x10, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x72, 0x65, 0x61, 0x73, 0x6f, 0x6e, 0x12, 0x19, 0x0a, | |||
| 0x08, 0x61, 0x70, 0x70, 0x5f, 0x74, 0x79, 0x70, 0x65, 0x18, 0x11, 0x20, 0x01, 0x28, 0x09, 0x52, | |||
| 0x07, 0x61, 0x70, 0x70, 0x54, 0x79, 0x70, 0x65, 0x22, 0x0c, 0x0a, 0x0a, 0x4c, 0x69, 0x73, 0x74, | |||
| 0x4a, 0x6f, 0x62, 0x52, 0x65, 0x71, 0x22, 0x7e, 0x0a, 0x0b, 0x4c, 0x69, 0x73, 0x74, 0x4a, 0x6f, | |||
| 0x4a, 0x6f, 0x62, 0x52, 0x65, 0x71, 0x22, 0x76, 0x0a, 0x0b, 0x4c, 0x69, 0x73, 0x74, 0x4a, 0x6f, | |||
| 0x62, 0x52, 0x65, 0x73, 0x70, 0x12, 0x12, 0x0a, 0x04, 0x63, 0x6f, 0x64, 0x65, 0x18, 0x01, 0x20, | |||
| 0x01, 0x28, 0x0d, 0x52, 0x04, 0x63, 0x6f, 0x64, 0x65, 0x12, 0x10, 0x0a, 0x03, 0x6d, 0x73, 0x67, | |||
| 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6d, 0x73, 0x67, 0x12, 0x21, 0x0a, 0x0c, 0x72, | |||
| 0x65, 0x63, 0x6f, 0x72, 0x64, 0x5f, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, | |||
| 0x0d, 0x52, 0x0b, 0x72, 0x65, 0x63, 0x6f, 0x72, 0x64, 0x43, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x26, | |||
| 0x0a, 0x04, 0x6a, 0x6f, 0x62, 0x73, 0x18, 0x04, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x12, 0x2e, 0x73, | |||
| 0x6c, 0x75, 0x72, 0x6d, 0x53, 0x68, 0x75, 0x67, 0x75, 0x61, 0x6e, 0x67, 0x2e, 0x6a, 0x6f, 0x62, | |||
| 0x52, 0x04, 0x6a, 0x6f, 0x62, 0x73, 0x22, 0x85, 0x04, 0x0a, 0x0a, 0x68, 0x69, 0x73, 0x74, 0x6f, | |||
| 0x72, 0x79, 0x4a, 0x6f, 0x62, 0x12, 0x1b, 0x0a, 0x09, 0x61, 0x63, 0x63, 0x74, 0x5f, 0x74, 0x69, | |||
| 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x61, 0x63, 0x63, 0x74, 0x54, 0x69, | |||
| 0x6d, 0x65, 0x12, 0x19, 0x0a, 0x08, 0x61, 0x70, 0x70, 0x5f, 0x74, 0x79, 0x70, 0x65, 0x18, 0x02, | |||
| 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x61, 0x70, 0x70, 0x54, 0x79, 0x70, 0x65, 0x12, 0x20, 0x0a, | |||
| 0x0c, 0x6a, 0x6f, 0x62, 0x5f, 0x65, 0x6e, 0x64, 0x5f, 0x74, 0x69, 0x6d, 0x65, 0x18, 0x03, 0x20, | |||
| 0x01, 0x28, 0x09, 0x52, 0x0a, 0x6a, 0x6f, 0x62, 0x45, 0x6e, 0x64, 0x54, 0x69, 0x6d, 0x65, 0x12, | |||
| 0x22, 0x0a, 0x0d, 0x6a, 0x6f, 0x62, 0x5f, 0x65, 0x78, 0x65, 0x63, 0x5f, 0x68, 0x6f, 0x73, 0x74, | |||
| 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x6a, 0x6f, 0x62, 0x45, 0x78, 0x65, 0x63, 0x48, | |||
| 0x6f, 0x73, 0x74, 0x12, 0x26, 0x0a, 0x0f, 0x6a, 0x6f, 0x62, 0x5f, 0x65, 0x78, 0x69, 0x74, 0x5f, | |||
| 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0x18, 0x05, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0d, 0x6a, 0x6f, | |||
| 0x62, 0x45, 0x78, 0x69, 0x74, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x12, 0x15, 0x0a, 0x06, 0x6a, | |||
| 0x6f, 0x62, 0x5f, 0x69, 0x64, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x6a, 0x6f, 0x62, | |||
| 0x49, 0x64, 0x12, 0x19, 0x0a, 0x08, 0x6a, 0x6f, 0x62, 0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x07, | |||
| 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x6a, 0x6f, 0x62, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x24, 0x0a, | |||
| 0x0e, 0x6a, 0x6f, 0x62, 0x5f, 0x71, 0x75, 0x65, 0x75, 0x65, 0x5f, 0x74, 0x69, 0x6d, 0x65, 0x18, | |||
| 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x6a, 0x6f, 0x62, 0x51, 0x75, 0x65, 0x75, 0x65, 0x54, | |||
| 0x69, 0x6d, 0x65, 0x12, 0x24, 0x0a, 0x0e, 0x6a, 0x6f, 0x62, 0x5f, 0x73, 0x74, 0x61, 0x72, 0x74, | |||
| 0x5f, 0x74, 0x69, 0x6d, 0x65, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x6a, 0x6f, 0x62, | |||
| 0x53, 0x74, 0x61, 0x72, 0x74, 0x54, 0x69, 0x6d, 0x65, 0x12, 0x1b, 0x0a, 0x09, 0x6a, 0x6f, 0x62, | |||
| 0x5f, 0x73, 0x74, 0x61, 0x74, 0x65, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x6a, 0x6f, | |||
| 0x62, 0x53, 0x74, 0x61, 0x74, 0x65, 0x12, 0x2a, 0x0a, 0x11, 0x6a, 0x6f, 0x62, 0x5f, 0x77, 0x61, | |||
| 0x6c, 0x6c, 0x74, 0x69, 0x6d, 0x65, 0x5f, 0x75, 0x73, 0x65, 0x64, 0x18, 0x0b, 0x20, 0x01, 0x28, | |||
| 0x09, 0x52, 0x0f, 0x6a, 0x6f, 0x62, 0x57, 0x61, 0x6c, 0x6c, 0x74, 0x69, 0x6d, 0x65, 0x55, 0x73, | |||
| 0x65, 0x64, 0x12, 0x24, 0x0a, 0x0e, 0x6a, 0x6f, 0x62, 0x5f, 0x6d, 0x61, 0x6e, 0x61, 0x67, 0x65, | |||
| 0x72, 0x5f, 0x69, 0x64, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0c, 0x6a, 0x6f, 0x62, 0x4d, | |||
| 0x61, 0x6e, 0x61, 0x67, 0x65, 0x72, 0x49, 0x64, 0x12, 0x17, 0x0a, 0x07, 0x6e, 0x6f, 0x64, 0x65, | |||
| 0x5f, 0x63, 0x74, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x05, 0x52, 0x06, 0x6e, 0x6f, 0x64, 0x65, 0x43, | |||
| 0x74, 0x12, 0x14, 0x0a, 0x05, 0x71, 0x75, 0x65, 0x75, 0x65, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x09, | |||
| 0x52, 0x05, 0x71, 0x75, 0x65, 0x75, 0x65, 0x12, 0x1b, 0x0a, 0x09, 0x75, 0x73, 0x65, 0x72, 0x5f, | |||
| 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x75, 0x73, 0x65, 0x72, | |||
| 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x77, 0x6f, 0x72, 0x6b, 0x64, 0x69, 0x72, 0x18, | |||
| 0x10, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x77, 0x6f, 0x72, 0x6b, 0x64, 0x69, 0x72, 0x22, 0xc3, | |||
| 0x01, 0x0a, 0x11, 0x4c, 0x69, 0x73, 0x74, 0x48, 0x69, 0x73, 0x74, 0x6f, 0x72, 0x79, 0x4a, 0x6f, | |||
| 0x62, 0x52, 0x65, 0x71, 0x12, 0x1c, 0x0a, 0x09, 0x73, 0x74, 0x61, 0x72, 0x74, 0x54, 0x69, 0x6d, | |||
| 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x73, 0x74, 0x61, 0x72, 0x74, 0x54, 0x69, | |||
| 0x6d, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x65, 0x6e, 0x64, 0x54, 0x69, 0x6d, 0x65, 0x18, 0x02, 0x20, | |||
| 0x01, 0x28, 0x09, 0x52, 0x07, 0x65, 0x6e, 0x64, 0x54, 0x69, 0x6d, 0x65, 0x12, 0x1a, 0x0a, 0x08, | |||
| 0x74, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, | |||
| 0x74, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x73, 0x74, 0x61, 0x72, | |||
| 0x74, 0x18, 0x04, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x73, 0x74, 0x61, 0x72, 0x74, 0x12, 0x14, | |||
| 0x0a, 0x05, 0x6c, 0x69, 0x6d, 0x69, 0x74, 0x18, 0x05, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x6c, | |||
| 0x69, 0x6d, 0x69, 0x74, 0x12, 0x2e, 0x0a, 0x12, 0x69, 0x73, 0x51, 0x75, 0x65, 0x72, 0x79, 0x42, | |||
| 0x79, 0x51, 0x75, 0x65, 0x75, 0x65, 0x54, 0x69, 0x6d, 0x65, 0x18, 0x06, 0x20, 0x01, 0x28, 0x05, | |||
| 0x52, 0x12, 0x69, 0x73, 0x51, 0x75, 0x65, 0x72, 0x79, 0x42, 0x79, 0x51, 0x75, 0x65, 0x75, 0x65, | |||
| 0x54, 0x69, 0x6d, 0x65, 0x22, 0x9b, 0x01, 0x0a, 0x12, 0x4c, 0x69, 0x73, 0x74, 0x48, 0x69, 0x73, | |||
| 0x74, 0x6f, 0x72, 0x79, 0x4a, 0x6f, 0x62, 0x52, 0x65, 0x73, 0x70, 0x12, 0x12, 0x0a, 0x04, 0x63, | |||
| 0x6f, 0x64, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x04, 0x63, 0x6f, 0x64, 0x65, 0x12, | |||
| 0x10, 0x0a, 0x03, 0x6d, 0x73, 0x67, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6d, 0x73, | |||
| 0x67, 0x12, 0x21, 0x0a, 0x0c, 0x72, 0x65, 0x63, 0x6f, 0x72, 0x64, 0x5f, 0x63, 0x6f, 0x75, 0x6e, | |||
| 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x0b, 0x72, 0x65, 0x63, 0x6f, 0x72, 0x64, 0x43, | |||
| 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x3c, 0x0a, 0x0c, 0x68, 0x69, 0x73, 0x74, 0x6f, 0x72, 0x79, 0x5f, | |||
| 0x6a, 0x6f, 0x62, 0x73, 0x18, 0x04, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x73, 0x6c, 0x75, | |||
| 0x72, 0x6d, 0x53, 0x68, 0x75, 0x67, 0x75, 0x61, 0x6e, 0x67, 0x2e, 0x68, 0x69, 0x73, 0x74, 0x6f, | |||
| 0x0d, 0x52, 0x0b, 0x72, 0x65, 0x63, 0x6f, 0x72, 0x64, 0x43, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x1e, | |||
| 0x0a, 0x04, 0x6a, 0x6f, 0x62, 0x73, 0x18, 0x04, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0a, 0x2e, 0x68, | |||
| 0x70, 0x63, 0x41, 0x43, 0x2e, 0x6a, 0x6f, 0x62, 0x52, 0x04, 0x6a, 0x6f, 0x62, 0x73, 0x22, 0x85, | |||
| 0x04, 0x0a, 0x0a, 0x68, 0x69, 0x73, 0x74, 0x6f, 0x72, 0x79, 0x4a, 0x6f, 0x62, 0x12, 0x1b, 0x0a, | |||
| 0x09, 0x61, 0x63, 0x63, 0x74, 0x5f, 0x74, 0x69, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, | |||
| 0x52, 0x08, 0x61, 0x63, 0x63, 0x74, 0x54, 0x69, 0x6d, 0x65, 0x12, 0x19, 0x0a, 0x08, 0x61, 0x70, | |||
| 0x70, 0x5f, 0x74, 0x79, 0x70, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x61, 0x70, | |||
| 0x70, 0x54, 0x79, 0x70, 0x65, 0x12, 0x20, 0x0a, 0x0c, 0x6a, 0x6f, 0x62, 0x5f, 0x65, 0x6e, 0x64, | |||
| 0x5f, 0x74, 0x69, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x6a, 0x6f, 0x62, | |||
| 0x45, 0x6e, 0x64, 0x54, 0x69, 0x6d, 0x65, 0x12, 0x22, 0x0a, 0x0d, 0x6a, 0x6f, 0x62, 0x5f, 0x65, | |||
| 0x78, 0x65, 0x63, 0x5f, 0x68, 0x6f, 0x73, 0x74, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, | |||
| 0x6a, 0x6f, 0x62, 0x45, 0x78, 0x65, 0x63, 0x48, 0x6f, 0x73, 0x74, 0x12, 0x26, 0x0a, 0x0f, 0x6a, | |||
| 0x6f, 0x62, 0x5f, 0x65, 0x78, 0x69, 0x74, 0x5f, 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0x18, 0x05, | |||
| 0x20, 0x01, 0x28, 0x05, 0x52, 0x0d, 0x6a, 0x6f, 0x62, 0x45, 0x78, 0x69, 0x74, 0x53, 0x74, 0x61, | |||
| 0x74, 0x75, 0x73, 0x12, 0x15, 0x0a, 0x06, 0x6a, 0x6f, 0x62, 0x5f, 0x69, 0x64, 0x18, 0x06, 0x20, | |||
| 0x01, 0x28, 0x03, 0x52, 0x05, 0x6a, 0x6f, 0x62, 0x49, 0x64, 0x12, 0x19, 0x0a, 0x08, 0x6a, 0x6f, | |||
| 0x62, 0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x6a, 0x6f, | |||
| 0x62, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x24, 0x0a, 0x0e, 0x6a, 0x6f, 0x62, 0x5f, 0x71, 0x75, 0x65, | |||
| 0x75, 0x65, 0x5f, 0x74, 0x69, 0x6d, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x6a, | |||
| 0x6f, 0x62, 0x51, 0x75, 0x65, 0x75, 0x65, 0x54, 0x69, 0x6d, 0x65, 0x12, 0x24, 0x0a, 0x0e, 0x6a, | |||
| 0x6f, 0x62, 0x5f, 0x73, 0x74, 0x61, 0x72, 0x74, 0x5f, 0x74, 0x69, 0x6d, 0x65, 0x18, 0x09, 0x20, | |||
| 0x01, 0x28, 0x09, 0x52, 0x0c, 0x6a, 0x6f, 0x62, 0x53, 0x74, 0x61, 0x72, 0x74, 0x54, 0x69, 0x6d, | |||
| 0x65, 0x12, 0x1b, 0x0a, 0x09, 0x6a, 0x6f, 0x62, 0x5f, 0x73, 0x74, 0x61, 0x74, 0x65, 0x18, 0x0a, | |||
| 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x6a, 0x6f, 0x62, 0x53, 0x74, 0x61, 0x74, 0x65, 0x12, 0x2a, | |||
| 0x0a, 0x11, 0x6a, 0x6f, 0x62, 0x5f, 0x77, 0x61, 0x6c, 0x6c, 0x74, 0x69, 0x6d, 0x65, 0x5f, 0x75, | |||
| 0x73, 0x65, 0x64, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0f, 0x6a, 0x6f, 0x62, 0x57, 0x61, | |||
| 0x6c, 0x6c, 0x74, 0x69, 0x6d, 0x65, 0x55, 0x73, 0x65, 0x64, 0x12, 0x24, 0x0a, 0x0e, 0x6a, 0x6f, | |||
| 0x62, 0x5f, 0x6d, 0x61, 0x6e, 0x61, 0x67, 0x65, 0x72, 0x5f, 0x69, 0x64, 0x18, 0x0c, 0x20, 0x01, | |||
| 0x28, 0x03, 0x52, 0x0c, 0x6a, 0x6f, 0x62, 0x4d, 0x61, 0x6e, 0x61, 0x67, 0x65, 0x72, 0x49, 0x64, | |||
| 0x12, 0x17, 0x0a, 0x07, 0x6e, 0x6f, 0x64, 0x65, 0x5f, 0x63, 0x74, 0x18, 0x0d, 0x20, 0x01, 0x28, | |||
| 0x05, 0x52, 0x06, 0x6e, 0x6f, 0x64, 0x65, 0x43, 0x74, 0x12, 0x14, 0x0a, 0x05, 0x71, 0x75, 0x65, | |||
| 0x75, 0x65, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x71, 0x75, 0x65, 0x75, 0x65, 0x12, | |||
| 0x1b, 0x0a, 0x09, 0x75, 0x73, 0x65, 0x72, 0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x0f, 0x20, 0x01, | |||
| 0x28, 0x09, 0x52, 0x08, 0x75, 0x73, 0x65, 0x72, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x18, 0x0a, 0x07, | |||
| 0x77, 0x6f, 0x72, 0x6b, 0x64, 0x69, 0x72, 0x18, 0x10, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x77, | |||
| 0x6f, 0x72, 0x6b, 0x64, 0x69, 0x72, 0x22, 0xc3, 0x01, 0x0a, 0x11, 0x4c, 0x69, 0x73, 0x74, 0x48, | |||
| 0x69, 0x73, 0x74, 0x6f, 0x72, 0x79, 0x4a, 0x6f, 0x62, 0x52, 0x65, 0x71, 0x12, 0x1c, 0x0a, 0x09, | |||
| 0x73, 0x74, 0x61, 0x72, 0x74, 0x54, 0x69, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, | |||
| 0x09, 0x73, 0x74, 0x61, 0x72, 0x74, 0x54, 0x69, 0x6d, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x65, 0x6e, | |||
| 0x64, 0x54, 0x69, 0x6d, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x65, 0x6e, 0x64, | |||
| 0x54, 0x69, 0x6d, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x74, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, | |||
| 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x74, 0x69, 0x6d, 0x65, 0x54, 0x79, 0x70, 0x65, | |||
| 0x12, 0x14, 0x0a, 0x05, 0x73, 0x74, 0x61, 0x72, 0x74, 0x18, 0x04, 0x20, 0x01, 0x28, 0x05, 0x52, | |||
| 0x05, 0x73, 0x74, 0x61, 0x72, 0x74, 0x12, 0x14, 0x0a, 0x05, 0x6c, 0x69, 0x6d, 0x69, 0x74, 0x18, | |||
| 0x05, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x6c, 0x69, 0x6d, 0x69, 0x74, 0x12, 0x2e, 0x0a, 0x12, | |||
| 0x69, 0x73, 0x51, 0x75, 0x65, 0x72, 0x79, 0x42, 0x79, 0x51, 0x75, 0x65, 0x75, 0x65, 0x54, 0x69, | |||
| 0x6d, 0x65, 0x18, 0x06, 0x20, 0x01, 0x28, 0x05, 0x52, 0x12, 0x69, 0x73, 0x51, 0x75, 0x65, 0x72, | |||
| 0x79, 0x42, 0x79, 0x51, 0x75, 0x65, 0x75, 0x65, 0x54, 0x69, 0x6d, 0x65, 0x22, 0x93, 0x01, 0x0a, | |||
| 0x12, 0x4c, 0x69, 0x73, 0x74, 0x48, 0x69, 0x73, 0x74, 0x6f, 0x72, 0x79, 0x4a, 0x6f, 0x62, 0x52, | |||
| 0x65, 0x73, 0x70, 0x12, 0x12, 0x0a, 0x04, 0x63, 0x6f, 0x64, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, | |||
| 0x0d, 0x52, 0x04, 0x63, 0x6f, 0x64, 0x65, 0x12, 0x10, 0x0a, 0x03, 0x6d, 0x73, 0x67, 0x18, 0x02, | |||
| 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6d, 0x73, 0x67, 0x12, 0x21, 0x0a, 0x0c, 0x72, 0x65, 0x63, | |||
| 0x6f, 0x72, 0x64, 0x5f, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0d, 0x52, | |||
| 0x0b, 0x72, 0x65, 0x63, 0x6f, 0x72, 0x64, 0x43, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x34, 0x0a, 0x0c, | |||
| 0x68, 0x69, 0x73, 0x74, 0x6f, 0x72, 0x79, 0x5f, 0x6a, 0x6f, 0x62, 0x73, 0x18, 0x04, 0x20, 0x03, | |||
| 0x28, 0x0b, 0x32, 0x11, 0x2e, 0x68, 0x70, 0x63, 0x41, 0x43, 0x2e, 0x68, 0x69, 0x73, 0x74, 0x6f, | |||
| 0x72, 0x79, 0x4a, 0x6f, 0x62, 0x52, 0x0b, 0x68, 0x69, 0x73, 0x74, 0x6f, 0x72, 0x79, 0x4a, 0x6f, | |||
| 0x62, 0x73, 0x22, 0xb0, 0x01, 0x0a, 0x0c, 0x53, 0x75, 0x62, 0x6d, 0x69, 0x74, 0x4a, 0x6f, 0x62, | |||
| 0x62, 0x73, 0x22, 0xa8, 0x01, 0x0a, 0x0c, 0x53, 0x75, 0x62, 0x6d, 0x69, 0x74, 0x4a, 0x6f, 0x62, | |||
| 0x52, 0x65, 0x71, 0x12, 0x18, 0x0a, 0x07, 0x61, 0x70, 0x70, 0x74, 0x79, 0x70, 0x65, 0x18, 0x01, | |||
| 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x61, 0x70, 0x70, 0x74, 0x79, 0x70, 0x65, 0x12, 0x18, 0x0a, | |||
| 0x07, 0x61, 0x70, 0x70, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, | |||
| 0x61, 0x70, 0x70, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x28, 0x0a, 0x0f, 0x73, 0x74, 0x72, 0x4a, 0x6f, | |||
| 0x62, 0x4d, 0x61, 0x6e, 0x61, 0x67, 0x65, 0x72, 0x49, 0x44, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, | |||
| 0x52, 0x0f, 0x73, 0x74, 0x72, 0x4a, 0x6f, 0x62, 0x4d, 0x61, 0x6e, 0x61, 0x67, 0x65, 0x72, 0x49, | |||
| 0x44, 0x12, 0x42, 0x0a, 0x0d, 0x6d, 0x61, 0x70, 0x41, 0x70, 0x70, 0x4a, 0x6f, 0x62, 0x49, 0x6e, | |||
| 0x66, 0x6f, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1c, 0x2e, 0x73, 0x6c, 0x75, 0x72, 0x6d, | |||
| 0x53, 0x68, 0x75, 0x67, 0x75, 0x61, 0x6e, 0x67, 0x2e, 0x4d, 0x61, 0x70, 0x41, 0x70, 0x70, 0x4a, | |||
| 0x6f, 0x62, 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x0d, 0x6d, 0x61, 0x70, 0x41, 0x70, 0x70, 0x4a, 0x6f, | |||
| 0x62, 0x49, 0x6e, 0x66, 0x6f, 0x22, 0x49, 0x0a, 0x0d, 0x53, 0x75, 0x62, 0x6d, 0x69, 0x74, 0x4a, | |||
| 0x6f, 0x62, 0x52, 0x65, 0x73, 0x70, 0x12, 0x12, 0x0a, 0x04, 0x43, 0x6f, 0x64, 0x65, 0x18, 0x01, | |||
| 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x43, 0x6f, 0x64, 0x65, 0x12, 0x10, 0x0a, 0x03, 0x4d, 0x73, | |||
| 0x67, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x4d, 0x73, 0x67, 0x12, 0x12, 0x0a, 0x04, | |||
| 0x44, 0x61, 0x74, 0x61, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x44, 0x61, 0x74, 0x61, | |||
| 0x22, 0xeb, 0x04, 0x0a, 0x0d, 0x4d, 0x61, 0x70, 0x41, 0x70, 0x70, 0x4a, 0x6f, 0x62, 0x49, 0x6e, | |||
| 0x66, 0x6f, 0x12, 0x20, 0x0a, 0x0c, 0x47, 0x41, 0x50, 0x5f, 0x43, 0x4d, 0x44, 0x5f, 0x46, 0x49, | |||
| 0x4c, 0x45, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x47, 0x41, 0x50, 0x43, 0x4d, 0x44, | |||
| 0x46, 0x49, 0x4c, 0x45, 0x12, 0x1b, 0x0a, 0x09, 0x47, 0x41, 0x50, 0x5f, 0x4e, 0x4e, 0x4f, 0x44, | |||
| 0x45, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x47, 0x41, 0x50, 0x4e, 0x4e, 0x4f, 0x44, | |||
| 0x45, 0x12, 0x26, 0x0a, 0x0f, 0x47, 0x41, 0x50, 0x5f, 0x4e, 0x4f, 0x44, 0x45, 0x5f, 0x53, 0x54, | |||
| 0x52, 0x49, 0x4e, 0x47, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x47, 0x41, 0x50, 0x4e, | |||
| 0x4f, 0x44, 0x45, 0x53, 0x54, 0x52, 0x49, 0x4e, 0x47, 0x12, 0x26, 0x0a, 0x0f, 0x47, 0x41, 0x50, | |||
| 0x5f, 0x53, 0x55, 0x42, 0x4d, 0x49, 0x54, 0x5f, 0x54, 0x59, 0x50, 0x45, 0x18, 0x04, 0x20, 0x01, | |||
| 0x28, 0x09, 0x52, 0x0d, 0x47, 0x41, 0x50, 0x53, 0x55, 0x42, 0x4d, 0x49, 0x54, 0x54, 0x59, 0x50, | |||
| 0x45, 0x12, 0x20, 0x0a, 0x0c, 0x47, 0x41, 0x50, 0x5f, 0x4a, 0x4f, 0x42, 0x5f, 0x4e, 0x41, 0x4d, | |||
| 0x45, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x47, 0x41, 0x50, 0x4a, 0x4f, 0x42, 0x4e, | |||
| 0x41, 0x4d, 0x45, 0x12, 0x20, 0x0a, 0x0c, 0x47, 0x41, 0x50, 0x5f, 0x57, 0x4f, 0x52, 0x4b, 0x5f, | |||
| 0x44, 0x49, 0x52, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x47, 0x41, 0x50, 0x57, 0x4f, | |||
| 0x52, 0x4b, 0x44, 0x49, 0x52, 0x12, 0x1b, 0x0a, 0x09, 0x47, 0x41, 0x50, 0x5f, 0x51, 0x55, 0x45, | |||
| 0x55, 0x45, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x47, 0x41, 0x50, 0x51, 0x55, 0x45, | |||
| 0x55, 0x45, 0x12, 0x1b, 0x0a, 0x09, 0x47, 0x41, 0x50, 0x5f, 0x4e, 0x50, 0x52, 0x4f, 0x43, 0x18, | |||
| 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x47, 0x41, 0x50, 0x4e, 0x50, 0x52, 0x4f, 0x43, 0x12, | |||
| 0x17, 0x0a, 0x07, 0x47, 0x41, 0x50, 0x5f, 0x50, 0x50, 0x4e, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, | |||
| 0x52, 0x06, 0x47, 0x41, 0x50, 0x50, 0x50, 0x4e, 0x12, 0x19, 0x0a, 0x08, 0x47, 0x41, 0x50, 0x5f, | |||
| 0x4e, 0x47, 0x50, 0x55, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x47, 0x41, 0x50, 0x4e, | |||
| 0x47, 0x50, 0x55, 0x12, 0x19, 0x0a, 0x08, 0x47, 0x41, 0x50, 0x5f, 0x4e, 0x44, 0x43, 0x55, 0x18, | |||
| 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x47, 0x41, 0x50, 0x4e, 0x44, 0x43, 0x55, 0x12, 0x1e, | |||
| 0x0a, 0x0b, 0x47, 0x41, 0x50, 0x5f, 0x4a, 0x4f, 0x42, 0x5f, 0x4d, 0x45, 0x4d, 0x18, 0x0c, 0x20, | |||
| 0x01, 0x28, 0x09, 0x52, 0x09, 0x47, 0x41, 0x50, 0x4a, 0x4f, 0x42, 0x4d, 0x45, 0x4d, 0x12, 0x22, | |||
| 0x0a, 0x0d, 0x47, 0x41, 0x50, 0x5f, 0x57, 0x41, 0x4c, 0x4c, 0x5f, 0x54, 0x49, 0x4d, 0x45, 0x18, | |||
| 0x0d, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x47, 0x41, 0x50, 0x57, 0x41, 0x4c, 0x4c, 0x54, 0x49, | |||
| 0x4d, 0x45, 0x12, 0x23, 0x0a, 0x0d, 0x47, 0x41, 0x50, 0x5f, 0x45, 0x58, 0x43, 0x4c, 0x55, 0x53, | |||
| 0x49, 0x56, 0x45, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x47, 0x41, 0x50, 0x45, 0x58, | |||
| 0x43, 0x4c, 0x55, 0x53, 0x49, 0x56, 0x45, 0x12, 0x1f, 0x0a, 0x0b, 0x47, 0x41, 0x50, 0x5f, 0x41, | |||
| 0x50, 0x50, 0x4e, 0x41, 0x4d, 0x45, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x47, 0x41, | |||
| 0x50, 0x41, 0x50, 0x50, 0x4e, 0x41, 0x4d, 0x45, 0x12, 0x22, 0x0a, 0x0d, 0x47, 0x41, 0x50, 0x5f, | |||
| 0x4d, 0x55, 0x4c, 0x54, 0x49, 0x5f, 0x53, 0x55, 0x42, 0x18, 0x10, 0x20, 0x01, 0x28, 0x09, 0x52, | |||
| 0x0b, 0x47, 0x41, 0x50, 0x4d, 0x55, 0x4c, 0x54, 0x49, 0x53, 0x55, 0x42, 0x12, 0x27, 0x0a, 0x10, | |||
| 0x47, 0x41, 0x50, 0x5f, 0x53, 0x54, 0x44, 0x5f, 0x4f, 0x55, 0x54, 0x5f, 0x46, 0x49, 0x4c, 0x45, | |||
| 0x18, 0x11, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x47, 0x41, 0x50, 0x53, 0x54, 0x44, 0x4f, 0x55, | |||
| 0x54, 0x46, 0x49, 0x4c, 0x45, 0x12, 0x27, 0x0a, 0x10, 0x47, 0x41, 0x50, 0x5f, 0x53, 0x54, 0x44, | |||
| 0x5f, 0x45, 0x52, 0x52, 0x5f, 0x46, 0x49, 0x4c, 0x45, 0x18, 0x12, 0x20, 0x01, 0x28, 0x09, 0x52, | |||
| 0x0d, 0x47, 0x41, 0x50, 0x53, 0x54, 0x44, 0x45, 0x52, 0x52, 0x46, 0x49, 0x4c, 0x45, 0x32, 0xf0, | |||
| 0x01, 0x0a, 0x0d, 0x53, 0x6c, 0x75, 0x72, 0x6d, 0x53, 0x68, 0x75, 0x67, 0x75, 0x61, 0x6e, 0x67, | |||
| 0x12, 0x40, 0x0a, 0x07, 0x4c, 0x69, 0x73, 0x74, 0x4a, 0x6f, 0x62, 0x12, 0x19, 0x2e, 0x73, 0x6c, | |||
| 0x75, 0x72, 0x6d, 0x53, 0x68, 0x75, 0x67, 0x75, 0x61, 0x6e, 0x67, 0x2e, 0x4c, 0x69, 0x73, 0x74, | |||
| 0x4a, 0x6f, 0x62, 0x52, 0x65, 0x71, 0x1a, 0x1a, 0x2e, 0x73, 0x6c, 0x75, 0x72, 0x6d, 0x53, 0x68, | |||
| 0x75, 0x67, 0x75, 0x61, 0x6e, 0x67, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x4a, 0x6f, 0x62, 0x52, 0x65, | |||
| 0x73, 0x70, 0x12, 0x55, 0x0a, 0x0e, 0x4c, 0x69, 0x73, 0x74, 0x48, 0x69, 0x73, 0x74, 0x6f, 0x72, | |||
| 0x79, 0x4a, 0x6f, 0x62, 0x12, 0x20, 0x2e, 0x73, 0x6c, 0x75, 0x72, 0x6d, 0x53, 0x68, 0x75, 0x67, | |||
| 0x75, 0x61, 0x6e, 0x67, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x48, 0x69, 0x73, 0x74, 0x6f, 0x72, 0x79, | |||
| 0x4a, 0x6f, 0x62, 0x52, 0x65, 0x71, 0x1a, 0x21, 0x2e, 0x73, 0x6c, 0x75, 0x72, 0x6d, 0x53, 0x68, | |||
| 0x75, 0x67, 0x75, 0x61, 0x6e, 0x67, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x48, 0x69, 0x73, 0x74, 0x6f, | |||
| 0x72, 0x79, 0x4a, 0x6f, 0x62, 0x52, 0x65, 0x73, 0x70, 0x12, 0x46, 0x0a, 0x09, 0x53, 0x75, 0x62, | |||
| 0x6d, 0x69, 0x74, 0x4a, 0x6f, 0x62, 0x12, 0x1b, 0x2e, 0x73, 0x6c, 0x75, 0x72, 0x6d, 0x53, 0x68, | |||
| 0x75, 0x67, 0x75, 0x61, 0x6e, 0x67, 0x2e, 0x53, 0x75, 0x62, 0x6d, 0x69, 0x74, 0x4a, 0x6f, 0x62, | |||
| 0x52, 0x65, 0x71, 0x1a, 0x1c, 0x2e, 0x73, 0x6c, 0x75, 0x72, 0x6d, 0x53, 0x68, 0x75, 0x67, 0x75, | |||
| 0x61, 0x6e, 0x67, 0x2e, 0x53, 0x75, 0x62, 0x6d, 0x69, 0x74, 0x4a, 0x6f, 0x62, 0x52, 0x65, 0x73, | |||
| 0x70, 0x42, 0x10, 0x5a, 0x0e, 0x2f, 0x73, 0x6c, 0x75, 0x72, 0x6d, 0x53, 0x68, 0x75, 0x67, 0x75, | |||
| 0x61, 0x6e, 0x67, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, | |||
| 0x44, 0x12, 0x3a, 0x0a, 0x0d, 0x6d, 0x61, 0x70, 0x41, 0x70, 0x70, 0x4a, 0x6f, 0x62, 0x49, 0x6e, | |||
| 0x66, 0x6f, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x14, 0x2e, 0x68, 0x70, 0x63, 0x41, 0x43, | |||
| 0x2e, 0x4d, 0x61, 0x70, 0x41, 0x70, 0x70, 0x4a, 0x6f, 0x62, 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x0d, | |||
| 0x6d, 0x61, 0x70, 0x41, 0x70, 0x70, 0x4a, 0x6f, 0x62, 0x49, 0x6e, 0x66, 0x6f, 0x22, 0x49, 0x0a, | |||
| 0x0d, 0x53, 0x75, 0x62, 0x6d, 0x69, 0x74, 0x4a, 0x6f, 0x62, 0x52, 0x65, 0x73, 0x70, 0x12, 0x12, | |||
| 0x0a, 0x04, 0x43, 0x6f, 0x64, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x43, 0x6f, | |||
| 0x64, 0x65, 0x12, 0x10, 0x0a, 0x03, 0x4d, 0x73, 0x67, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, | |||
| 0x03, 0x4d, 0x73, 0x67, 0x12, 0x12, 0x0a, 0x04, 0x44, 0x61, 0x74, 0x61, 0x18, 0x03, 0x20, 0x01, | |||
| 0x28, 0x09, 0x52, 0x04, 0x44, 0x61, 0x74, 0x61, 0x22, 0xeb, 0x04, 0x0a, 0x0d, 0x4d, 0x61, 0x70, | |||
| 0x41, 0x70, 0x70, 0x4a, 0x6f, 0x62, 0x49, 0x6e, 0x66, 0x6f, 0x12, 0x20, 0x0a, 0x0c, 0x47, 0x41, | |||
| 0x50, 0x5f, 0x43, 0x4d, 0x44, 0x5f, 0x46, 0x49, 0x4c, 0x45, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, | |||
| 0x52, 0x0a, 0x47, 0x41, 0x50, 0x43, 0x4d, 0x44, 0x46, 0x49, 0x4c, 0x45, 0x12, 0x1b, 0x0a, 0x09, | |||
| 0x47, 0x41, 0x50, 0x5f, 0x4e, 0x4e, 0x4f, 0x44, 0x45, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, | |||
| 0x08, 0x47, 0x41, 0x50, 0x4e, 0x4e, 0x4f, 0x44, 0x45, 0x12, 0x26, 0x0a, 0x0f, 0x47, 0x41, 0x50, | |||
| 0x5f, 0x4e, 0x4f, 0x44, 0x45, 0x5f, 0x53, 0x54, 0x52, 0x49, 0x4e, 0x47, 0x18, 0x03, 0x20, 0x01, | |||
| 0x28, 0x09, 0x52, 0x0d, 0x47, 0x41, 0x50, 0x4e, 0x4f, 0x44, 0x45, 0x53, 0x54, 0x52, 0x49, 0x4e, | |||
| 0x47, 0x12, 0x26, 0x0a, 0x0f, 0x47, 0x41, 0x50, 0x5f, 0x53, 0x55, 0x42, 0x4d, 0x49, 0x54, 0x5f, | |||
| 0x54, 0x59, 0x50, 0x45, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x47, 0x41, 0x50, 0x53, | |||
| 0x55, 0x42, 0x4d, 0x49, 0x54, 0x54, 0x59, 0x50, 0x45, 0x12, 0x20, 0x0a, 0x0c, 0x47, 0x41, 0x50, | |||
| 0x5f, 0x4a, 0x4f, 0x42, 0x5f, 0x4e, 0x41, 0x4d, 0x45, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, | |||
| 0x0a, 0x47, 0x41, 0x50, 0x4a, 0x4f, 0x42, 0x4e, 0x41, 0x4d, 0x45, 0x12, 0x20, 0x0a, 0x0c, 0x47, | |||
| 0x41, 0x50, 0x5f, 0x57, 0x4f, 0x52, 0x4b, 0x5f, 0x44, 0x49, 0x52, 0x18, 0x06, 0x20, 0x01, 0x28, | |||
| 0x09, 0x52, 0x0a, 0x47, 0x41, 0x50, 0x57, 0x4f, 0x52, 0x4b, 0x44, 0x49, 0x52, 0x12, 0x1b, 0x0a, | |||
| 0x09, 0x47, 0x41, 0x50, 0x5f, 0x51, 0x55, 0x45, 0x55, 0x45, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, | |||
| 0x52, 0x08, 0x47, 0x41, 0x50, 0x51, 0x55, 0x45, 0x55, 0x45, 0x12, 0x1b, 0x0a, 0x09, 0x47, 0x41, | |||
| 0x50, 0x5f, 0x4e, 0x50, 0x52, 0x4f, 0x43, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x47, | |||
| 0x41, 0x50, 0x4e, 0x50, 0x52, 0x4f, 0x43, 0x12, 0x17, 0x0a, 0x07, 0x47, 0x41, 0x50, 0x5f, 0x50, | |||
| 0x50, 0x4e, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x47, 0x41, 0x50, 0x50, 0x50, 0x4e, | |||
| 0x12, 0x19, 0x0a, 0x08, 0x47, 0x41, 0x50, 0x5f, 0x4e, 0x47, 0x50, 0x55, 0x18, 0x0a, 0x20, 0x01, | |||
| 0x28, 0x09, 0x52, 0x07, 0x47, 0x41, 0x50, 0x4e, 0x47, 0x50, 0x55, 0x12, 0x19, 0x0a, 0x08, 0x47, | |||
| 0x41, 0x50, 0x5f, 0x4e, 0x44, 0x43, 0x55, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x47, | |||
| 0x41, 0x50, 0x4e, 0x44, 0x43, 0x55, 0x12, 0x1e, 0x0a, 0x0b, 0x47, 0x41, 0x50, 0x5f, 0x4a, 0x4f, | |||
| 0x42, 0x5f, 0x4d, 0x45, 0x4d, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x47, 0x41, 0x50, | |||
| 0x4a, 0x4f, 0x42, 0x4d, 0x45, 0x4d, 0x12, 0x22, 0x0a, 0x0d, 0x47, 0x41, 0x50, 0x5f, 0x57, 0x41, | |||
| 0x4c, 0x4c, 0x5f, 0x54, 0x49, 0x4d, 0x45, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x47, | |||
| 0x41, 0x50, 0x57, 0x41, 0x4c, 0x4c, 0x54, 0x49, 0x4d, 0x45, 0x12, 0x23, 0x0a, 0x0d, 0x47, 0x41, | |||
| 0x50, 0x5f, 0x45, 0x58, 0x43, 0x4c, 0x55, 0x53, 0x49, 0x56, 0x45, 0x18, 0x0e, 0x20, 0x01, 0x28, | |||
| 0x09, 0x52, 0x0c, 0x47, 0x41, 0x50, 0x45, 0x58, 0x43, 0x4c, 0x55, 0x53, 0x49, 0x56, 0x45, 0x12, | |||
| 0x1f, 0x0a, 0x0b, 0x47, 0x41, 0x50, 0x5f, 0x41, 0x50, 0x50, 0x4e, 0x41, 0x4d, 0x45, 0x18, 0x0f, | |||
| 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x47, 0x41, 0x50, 0x41, 0x50, 0x50, 0x4e, 0x41, 0x4d, 0x45, | |||
| 0x12, 0x22, 0x0a, 0x0d, 0x47, 0x41, 0x50, 0x5f, 0x4d, 0x55, 0x4c, 0x54, 0x49, 0x5f, 0x53, 0x55, | |||
| 0x42, 0x18, 0x10, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x47, 0x41, 0x50, 0x4d, 0x55, 0x4c, 0x54, | |||
| 0x49, 0x53, 0x55, 0x42, 0x12, 0x27, 0x0a, 0x10, 0x47, 0x41, 0x50, 0x5f, 0x53, 0x54, 0x44, 0x5f, | |||
| 0x4f, 0x55, 0x54, 0x5f, 0x46, 0x49, 0x4c, 0x45, 0x18, 0x11, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, | |||
| 0x47, 0x41, 0x50, 0x53, 0x54, 0x44, 0x4f, 0x55, 0x54, 0x46, 0x49, 0x4c, 0x45, 0x12, 0x27, 0x0a, | |||
| 0x10, 0x47, 0x41, 0x50, 0x5f, 0x53, 0x54, 0x44, 0x5f, 0x45, 0x52, 0x52, 0x5f, 0x46, 0x49, 0x4c, | |||
| 0x45, 0x18, 0x12, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x47, 0x41, 0x50, 0x53, 0x54, 0x44, 0x45, | |||
| 0x52, 0x52, 0x46, 0x49, 0x4c, 0x45, 0x32, 0xb8, 0x01, 0x0a, 0x05, 0x68, 0x70, 0x63, 0x41, 0x43, | |||
| 0x12, 0x30, 0x0a, 0x07, 0x4c, 0x69, 0x73, 0x74, 0x4a, 0x6f, 0x62, 0x12, 0x11, 0x2e, 0x68, 0x70, | |||
| 0x63, 0x41, 0x43, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x4a, 0x6f, 0x62, 0x52, 0x65, 0x71, 0x1a, 0x12, | |||
| 0x2e, 0x68, 0x70, 0x63, 0x41, 0x43, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x4a, 0x6f, 0x62, 0x52, 0x65, | |||
| 0x73, 0x70, 0x12, 0x45, 0x0a, 0x0e, 0x4c, 0x69, 0x73, 0x74, 0x48, 0x69, 0x73, 0x74, 0x6f, 0x72, | |||
| 0x79, 0x4a, 0x6f, 0x62, 0x12, 0x18, 0x2e, 0x68, 0x70, 0x63, 0x41, 0x43, 0x2e, 0x4c, 0x69, 0x73, | |||
| 0x74, 0x48, 0x69, 0x73, 0x74, 0x6f, 0x72, 0x79, 0x4a, 0x6f, 0x62, 0x52, 0x65, 0x71, 0x1a, 0x19, | |||
| 0x2e, 0x68, 0x70, 0x63, 0x41, 0x43, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x48, 0x69, 0x73, 0x74, 0x6f, | |||
| 0x72, 0x79, 0x4a, 0x6f, 0x62, 0x52, 0x65, 0x73, 0x70, 0x12, 0x36, 0x0a, 0x09, 0x53, 0x75, 0x62, | |||
| 0x6d, 0x69, 0x74, 0x4a, 0x6f, 0x62, 0x12, 0x13, 0x2e, 0x68, 0x70, 0x63, 0x41, 0x43, 0x2e, 0x53, | |||
| 0x75, 0x62, 0x6d, 0x69, 0x74, 0x4a, 0x6f, 0x62, 0x52, 0x65, 0x71, 0x1a, 0x14, 0x2e, 0x68, 0x70, | |||
| 0x63, 0x41, 0x43, 0x2e, 0x53, 0x75, 0x62, 0x6d, 0x69, 0x74, 0x4a, 0x6f, 0x62, 0x52, 0x65, 0x73, | |||
| 0x70, 0x42, 0x08, 0x5a, 0x06, 0x2f, 0x68, 0x70, 0x63, 0x41, 0x43, 0x62, 0x06, 0x70, 0x72, 0x6f, | |||
| 0x74, 0x6f, 0x33, | |||
| } | |||
| var ( | |||
| file_slurmShuguang_proto_rawDescOnce sync.Once | |||
| file_slurmShuguang_proto_rawDescData = file_slurmShuguang_proto_rawDesc | |||
| file_hpcAC_proto_rawDescOnce sync.Once | |||
| file_hpcAC_proto_rawDescData = file_hpcAC_proto_rawDesc | |||
| ) | |||
| func file_slurmShuguang_proto_rawDescGZIP() []byte { | |||
| file_slurmShuguang_proto_rawDescOnce.Do(func() { | |||
| file_slurmShuguang_proto_rawDescData = protoimpl.X.CompressGZIP(file_slurmShuguang_proto_rawDescData) | |||
| func file_hpcAC_proto_rawDescGZIP() []byte { | |||
| file_hpcAC_proto_rawDescOnce.Do(func() { | |||
| file_hpcAC_proto_rawDescData = protoimpl.X.CompressGZIP(file_hpcAC_proto_rawDescData) | |||
| }) | |||
| return file_slurmShuguang_proto_rawDescData | |||
| } | |||
| var file_slurmShuguang_proto_msgTypes = make([]protoimpl.MessageInfo, 9) | |||
| var file_slurmShuguang_proto_goTypes = []interface{}{ | |||
| (*Job)(nil), // 0: slurmShuguang.job | |||
| (*ListJobReq)(nil), // 1: slurmShuguang.ListJobReq | |||
| (*ListJobResp)(nil), // 2: slurmShuguang.ListJobResp | |||
| (*HistoryJob)(nil), // 3: slurmShuguang.historyJob | |||
| (*ListHistoryJobReq)(nil), // 4: slurmShuguang.ListHistoryJobReq | |||
| (*ListHistoryJobResp)(nil), // 5: slurmShuguang.ListHistoryJobResp | |||
| (*SubmitJobReq)(nil), // 6: slurmShuguang.SubmitJobReq | |||
| (*SubmitJobResp)(nil), // 7: slurmShuguang.SubmitJobResp | |||
| (*MapAppJobInfo)(nil), // 8: slurmShuguang.MapAppJobInfo | |||
| } | |||
| var file_slurmShuguang_proto_depIdxs = []int32{ | |||
| 0, // 0: slurmShuguang.ListJobResp.jobs:type_name -> slurmShuguang.job | |||
| 3, // 1: slurmShuguang.ListHistoryJobResp.history_jobs:type_name -> slurmShuguang.historyJob | |||
| 8, // 2: slurmShuguang.SubmitJobReq.mapAppJobInfo:type_name -> slurmShuguang.MapAppJobInfo | |||
| 1, // 3: slurmShuguang.SlurmShuguang.ListJob:input_type -> slurmShuguang.ListJobReq | |||
| 4, // 4: slurmShuguang.SlurmShuguang.ListHistoryJob:input_type -> slurmShuguang.ListHistoryJobReq | |||
| 6, // 5: slurmShuguang.SlurmShuguang.SubmitJob:input_type -> slurmShuguang.SubmitJobReq | |||
| 2, // 6: slurmShuguang.SlurmShuguang.ListJob:output_type -> slurmShuguang.ListJobResp | |||
| 5, // 7: slurmShuguang.SlurmShuguang.ListHistoryJob:output_type -> slurmShuguang.ListHistoryJobResp | |||
| 7, // 8: slurmShuguang.SlurmShuguang.SubmitJob:output_type -> slurmShuguang.SubmitJobResp | |||
| return file_hpcAC_proto_rawDescData | |||
| } | |||
| var file_hpcAC_proto_msgTypes = make([]protoimpl.MessageInfo, 9) | |||
| var file_hpcAC_proto_goTypes = []interface{}{ | |||
| (*Job)(nil), // 0: hpcAC.job | |||
| (*ListJobReq)(nil), // 1: hpcAC.ListJobReq | |||
| (*ListJobResp)(nil), // 2: hpcAC.ListJobResp | |||
| (*HistoryJob)(nil), // 3: hpcAC.historyJob | |||
| (*ListHistoryJobReq)(nil), // 4: hpcAC.ListHistoryJobReq | |||
| (*ListHistoryJobResp)(nil), // 5: hpcAC.ListHistoryJobResp | |||
| (*SubmitJobReq)(nil), // 6: hpcAC.SubmitJobReq | |||
| (*SubmitJobResp)(nil), // 7: hpcAC.SubmitJobResp | |||
| (*MapAppJobInfo)(nil), // 8: hpcAC.MapAppJobInfo | |||
| } | |||
| var file_hpcAC_proto_depIdxs = []int32{ | |||
| 0, // 0: hpcAC.ListJobResp.jobs:type_name -> hpcAC.job | |||
| 3, // 1: hpcAC.ListHistoryJobResp.history_jobs:type_name -> hpcAC.historyJob | |||
| 8, // 2: hpcAC.SubmitJobReq.mapAppJobInfo:type_name -> hpcAC.MapAppJobInfo | |||
| 1, // 3: hpcAC.hpcAC.ListJob:input_type -> hpcAC.ListJobReq | |||
| 4, // 4: hpcAC.hpcAC.ListHistoryJob:input_type -> hpcAC.ListHistoryJobReq | |||
| 6, // 5: hpcAC.hpcAC.SubmitJob:input_type -> hpcAC.SubmitJobReq | |||
| 2, // 6: hpcAC.hpcAC.ListJob:output_type -> hpcAC.ListJobResp | |||
| 5, // 7: hpcAC.hpcAC.ListHistoryJob:output_type -> hpcAC.ListHistoryJobResp | |||
| 7, // 8: hpcAC.hpcAC.SubmitJob:output_type -> hpcAC.SubmitJobResp | |||
| 6, // [6:9] is the sub-list for method output_type | |||
| 3, // [3:6] is the sub-list for method input_type | |||
| 3, // [3:3] is the sub-list for extension type_name | |||
| @@ -1166,13 +1160,13 @@ var file_slurmShuguang_proto_depIdxs = []int32{ | |||
| 0, // [0:3] is the sub-list for field type_name | |||
| } | |||
| func init() { file_slurmShuguang_proto_init() } | |||
| func file_slurmShuguang_proto_init() { | |||
| if File_slurmShuguang_proto != nil { | |||
| func init() { file_hpcAC_proto_init() } | |||
| func file_hpcAC_proto_init() { | |||
| if File_hpcAC_proto != nil { | |||
| return | |||
| } | |||
| if !protoimpl.UnsafeEnabled { | |||
| file_slurmShuguang_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { | |||
| file_hpcAC_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { | |||
| switch v := v.(*Job); i { | |||
| case 0: | |||
| return &v.state | |||
| @@ -1184,7 +1178,7 @@ func file_slurmShuguang_proto_init() { | |||
| return nil | |||
| } | |||
| } | |||
| file_slurmShuguang_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { | |||
| file_hpcAC_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { | |||
| switch v := v.(*ListJobReq); i { | |||
| case 0: | |||
| return &v.state | |||
| @@ -1196,7 +1190,7 @@ func file_slurmShuguang_proto_init() { | |||
| return nil | |||
| } | |||
| } | |||
| file_slurmShuguang_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { | |||
| file_hpcAC_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { | |||
| switch v := v.(*ListJobResp); i { | |||
| case 0: | |||
| return &v.state | |||
| @@ -1208,7 +1202,7 @@ func file_slurmShuguang_proto_init() { | |||
| return nil | |||
| } | |||
| } | |||
| file_slurmShuguang_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { | |||
| file_hpcAC_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { | |||
| switch v := v.(*HistoryJob); i { | |||
| case 0: | |||
| return &v.state | |||
| @@ -1220,7 +1214,7 @@ func file_slurmShuguang_proto_init() { | |||
| return nil | |||
| } | |||
| } | |||
| file_slurmShuguang_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { | |||
| file_hpcAC_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { | |||
| switch v := v.(*ListHistoryJobReq); i { | |||
| case 0: | |||
| return &v.state | |||
| @@ -1232,7 +1226,7 @@ func file_slurmShuguang_proto_init() { | |||
| return nil | |||
| } | |||
| } | |||
| file_slurmShuguang_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} { | |||
| file_hpcAC_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} { | |||
| switch v := v.(*ListHistoryJobResp); i { | |||
| case 0: | |||
| return &v.state | |||
| @@ -1244,7 +1238,7 @@ func file_slurmShuguang_proto_init() { | |||
| return nil | |||
| } | |||
| } | |||
| file_slurmShuguang_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} { | |||
| file_hpcAC_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} { | |||
| switch v := v.(*SubmitJobReq); i { | |||
| case 0: | |||
| return &v.state | |||
| @@ -1256,7 +1250,7 @@ func file_slurmShuguang_proto_init() { | |||
| return nil | |||
| } | |||
| } | |||
| file_slurmShuguang_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} { | |||
| file_hpcAC_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} { | |||
| switch v := v.(*SubmitJobResp); i { | |||
| case 0: | |||
| return &v.state | |||
| @@ -1268,7 +1262,7 @@ func file_slurmShuguang_proto_init() { | |||
| return nil | |||
| } | |||
| } | |||
| file_slurmShuguang_proto_msgTypes[8].Exporter = func(v interface{}, i int) interface{} { | |||
| file_hpcAC_proto_msgTypes[8].Exporter = func(v interface{}, i int) interface{} { | |||
| switch v := v.(*MapAppJobInfo); i { | |||
| case 0: | |||
| return &v.state | |||
| @@ -1285,18 +1279,18 @@ func file_slurmShuguang_proto_init() { | |||
| out := protoimpl.TypeBuilder{ | |||
| File: protoimpl.DescBuilder{ | |||
| GoPackagePath: reflect.TypeOf(x{}).PkgPath(), | |||
| RawDescriptor: file_slurmShuguang_proto_rawDesc, | |||
| RawDescriptor: file_hpcAC_proto_rawDesc, | |||
| NumEnums: 0, | |||
| NumMessages: 9, | |||
| NumExtensions: 0, | |||
| NumServices: 1, | |||
| }, | |||
| GoTypes: file_slurmShuguang_proto_goTypes, | |||
| DependencyIndexes: file_slurmShuguang_proto_depIdxs, | |||
| MessageInfos: file_slurmShuguang_proto_msgTypes, | |||
| GoTypes: file_hpcAC_proto_goTypes, | |||
| DependencyIndexes: file_hpcAC_proto_depIdxs, | |||
| MessageInfos: file_hpcAC_proto_msgTypes, | |||
| }.Build() | |||
| File_slurmShuguang_proto = out.File | |||
| file_slurmShuguang_proto_rawDesc = nil | |||
| file_slurmShuguang_proto_goTypes = nil | |||
| file_slurmShuguang_proto_depIdxs = nil | |||
| File_hpcAC_proto = out.File | |||
| file_hpcAC_proto_rawDesc = nil | |||
| file_hpcAC_proto_goTypes = nil | |||
| file_hpcAC_proto_depIdxs = nil | |||
| } | |||
| @@ -0,0 +1,183 @@ | |||
| // Code generated by protoc-gen-go-grpc. DO NOT EDIT. | |||
| // versions: | |||
| // - protoc-gen-go-grpc v1.2.0 | |||
| // - protoc v3.19.4 | |||
| // source: hpcAC.proto | |||
| package hpcAC | |||
| 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 | |||
| // HpcACClient is the client API for HpcAC 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 HpcACClient interface { | |||
| // ListJob list all jobs | |||
| ListJob(ctx context.Context, in *ListJobReq, opts ...grpc.CallOption) (*ListJobResp, error) | |||
| // ListHistoryJob list all history jobs | |||
| ListHistoryJob(ctx context.Context, in *ListHistoryJobReq, opts ...grpc.CallOption) (*ListHistoryJobResp, error) | |||
| // Submit job | |||
| SubmitJob(ctx context.Context, in *SubmitJobReq, opts ...grpc.CallOption) (*SubmitJobResp, error) | |||
| } | |||
| type hpcACClient struct { | |||
| cc grpc.ClientConnInterface | |||
| } | |||
| func NewHpcACClient(cc grpc.ClientConnInterface) HpcACClient { | |||
| return &hpcACClient{cc} | |||
| } | |||
| func (c *hpcACClient) ListJob(ctx context.Context, in *ListJobReq, opts ...grpc.CallOption) (*ListJobResp, error) { | |||
| out := new(ListJobResp) | |||
| err := c.cc.Invoke(ctx, "/hpcAC.hpcAC/ListJob", in, out, opts...) | |||
| if err != nil { | |||
| return nil, err | |||
| } | |||
| return out, nil | |||
| } | |||
| func (c *hpcACClient) ListHistoryJob(ctx context.Context, in *ListHistoryJobReq, opts ...grpc.CallOption) (*ListHistoryJobResp, error) { | |||
| out := new(ListHistoryJobResp) | |||
| err := c.cc.Invoke(ctx, "/hpcAC.hpcAC/ListHistoryJob", in, out, opts...) | |||
| if err != nil { | |||
| return nil, err | |||
| } | |||
| return out, nil | |||
| } | |||
| func (c *hpcACClient) SubmitJob(ctx context.Context, in *SubmitJobReq, opts ...grpc.CallOption) (*SubmitJobResp, error) { | |||
| out := new(SubmitJobResp) | |||
| err := c.cc.Invoke(ctx, "/hpcAC.hpcAC/SubmitJob", in, out, opts...) | |||
| if err != nil { | |||
| return nil, err | |||
| } | |||
| return out, nil | |||
| } | |||
| // HpcACServer is the server API for HpcAC service. | |||
| // All implementations must embed UnimplementedHpcACServer | |||
| // for forward compatibility | |||
| type HpcACServer interface { | |||
| // ListJob list all jobs | |||
| ListJob(context.Context, *ListJobReq) (*ListJobResp, error) | |||
| // ListHistoryJob list all history jobs | |||
| ListHistoryJob(context.Context, *ListHistoryJobReq) (*ListHistoryJobResp, error) | |||
| // Submit job | |||
| SubmitJob(context.Context, *SubmitJobReq) (*SubmitJobResp, error) | |||
| mustEmbedUnimplementedHpcACServer() | |||
| } | |||
| // UnimplementedHpcACServer must be embedded to have forward compatible implementations. | |||
| type UnimplementedHpcACServer struct { | |||
| } | |||
| func (UnimplementedHpcACServer) ListJob(context.Context, *ListJobReq) (*ListJobResp, error) { | |||
| return nil, status.Errorf(codes.Unimplemented, "method ListJob not implemented") | |||
| } | |||
| func (UnimplementedHpcACServer) ListHistoryJob(context.Context, *ListHistoryJobReq) (*ListHistoryJobResp, error) { | |||
| return nil, status.Errorf(codes.Unimplemented, "method ListHistoryJob not implemented") | |||
| } | |||
| func (UnimplementedHpcACServer) SubmitJob(context.Context, *SubmitJobReq) (*SubmitJobResp, error) { | |||
| return nil, status.Errorf(codes.Unimplemented, "method SubmitJob not implemented") | |||
| } | |||
| func (UnimplementedHpcACServer) mustEmbedUnimplementedHpcACServer() {} | |||
| // UnsafeHpcACServer may be embedded to opt out of forward compatibility for this service. | |||
| // Use of this interface is not recommended, as added methods to HpcACServer will | |||
| // result in compilation errors. | |||
| type UnsafeHpcACServer interface { | |||
| mustEmbedUnimplementedHpcACServer() | |||
| } | |||
| func RegisterHpcACServer(s grpc.ServiceRegistrar, srv HpcACServer) { | |||
| s.RegisterService(&HpcAC_ServiceDesc, srv) | |||
| } | |||
| func _HpcAC_ListJob_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { | |||
| in := new(ListJobReq) | |||
| if err := dec(in); err != nil { | |||
| return nil, err | |||
| } | |||
| if interceptor == nil { | |||
| return srv.(HpcACServer).ListJob(ctx, in) | |||
| } | |||
| info := &grpc.UnaryServerInfo{ | |||
| Server: srv, | |||
| FullMethod: "/hpcAC.hpcAC/ListJob", | |||
| } | |||
| handler := func(ctx context.Context, req interface{}) (interface{}, error) { | |||
| return srv.(HpcACServer).ListJob(ctx, req.(*ListJobReq)) | |||
| } | |||
| return interceptor(ctx, in, info, handler) | |||
| } | |||
| func _HpcAC_ListHistoryJob_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { | |||
| in := new(ListHistoryJobReq) | |||
| if err := dec(in); err != nil { | |||
| return nil, err | |||
| } | |||
| if interceptor == nil { | |||
| return srv.(HpcACServer).ListHistoryJob(ctx, in) | |||
| } | |||
| info := &grpc.UnaryServerInfo{ | |||
| Server: srv, | |||
| FullMethod: "/hpcAC.hpcAC/ListHistoryJob", | |||
| } | |||
| handler := func(ctx context.Context, req interface{}) (interface{}, error) { | |||
| return srv.(HpcACServer).ListHistoryJob(ctx, req.(*ListHistoryJobReq)) | |||
| } | |||
| return interceptor(ctx, in, info, handler) | |||
| } | |||
| func _HpcAC_SubmitJob_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { | |||
| in := new(SubmitJobReq) | |||
| if err := dec(in); err != nil { | |||
| return nil, err | |||
| } | |||
| if interceptor == nil { | |||
| return srv.(HpcACServer).SubmitJob(ctx, in) | |||
| } | |||
| info := &grpc.UnaryServerInfo{ | |||
| Server: srv, | |||
| FullMethod: "/hpcAC.hpcAC/SubmitJob", | |||
| } | |||
| handler := func(ctx context.Context, req interface{}) (interface{}, error) { | |||
| return srv.(HpcACServer).SubmitJob(ctx, req.(*SubmitJobReq)) | |||
| } | |||
| return interceptor(ctx, in, info, handler) | |||
| } | |||
| // HpcAC_ServiceDesc is the grpc.ServiceDesc for HpcAC service. | |||
| // It's only intended for direct use with grpc.RegisterService, | |||
| // and not to be introspected or modified (even as a copy) | |||
| var HpcAC_ServiceDesc = grpc.ServiceDesc{ | |||
| ServiceName: "hpcAC.hpcAC", | |||
| HandlerType: (*HpcACServer)(nil), | |||
| Methods: []grpc.MethodDesc{ | |||
| { | |||
| MethodName: "ListJob", | |||
| Handler: _HpcAC_ListJob_Handler, | |||
| }, | |||
| { | |||
| MethodName: "ListHistoryJob", | |||
| Handler: _HpcAC_ListHistoryJob_Handler, | |||
| }, | |||
| { | |||
| MethodName: "SubmitJob", | |||
| Handler: _HpcAC_SubmitJob_Handler, | |||
| }, | |||
| }, | |||
| Streams: []grpc.StreamDesc{}, | |||
| Metadata: "hpcAC.proto", | |||
| } | |||
| @@ -1,12 +1,13 @@ | |||
| package main | |||
| import ( | |||
| "flag" | |||
| "fmt" | |||
| "PCM/adaptor/PCM-HPC/PCM-AC/rpc/hpcAC" | |||
| "PCM/adaptor/PCM-HPC/PCM-AC/rpc/internal/config" | |||
| "PCM/adaptor/PCM-HPC/PCM-AC/rpc/internal/server" | |||
| "PCM/adaptor/PCM-HPC/PCM-AC/rpc/internal/svc" | |||
| "PCM/adaptor/PCM-HPC/PCM-AC/rpc/slurmShuguang" | |||
| "flag" | |||
| "fmt" | |||
| "github.com/zeromicro/go-zero/core/conf" | |||
| "github.com/zeromicro/go-zero/core/service" | |||
| @@ -15,7 +16,7 @@ import ( | |||
| "google.golang.org/grpc/reflection" | |||
| ) | |||
| var configFile = flag.String("f", "adaptor/PCM-HPC/PCM-AC/rpc/etc/slurmshuguang.yaml", "the config file") | |||
| var configFile = flag.String("f", "adaptor/PCM-HPC/PCM-AC/rpc/etc/hpcac.yaml", "the config file") | |||
| func main() { | |||
| flag.Parse() | |||
| @@ -25,7 +26,7 @@ func main() { | |||
| ctx := svc.NewServiceContext(c) | |||
| s := zrpc.MustNewServer(c.RpcServerConf, func(grpcServer *grpc.Server) { | |||
| slurmShuguang.RegisterSlurmShuguangServer(grpcServer, server.NewSlurmShuguangServer(ctx)) | |||
| hpcAC.RegisterHpcACServer(grpcServer, server.NewHpcACServer(ctx)) | |||
| if c.Mode == service.DevMode || c.Mode == service.TestMode { | |||
| reflection.Register(grpcServer) | |||
| @@ -0,0 +1,62 @@ | |||
| // Code generated by goctl. DO NOT EDIT. | |||
| // Source: hpcAC.proto | |||
| package hpcacclient | |||
| import ( | |||
| "context" | |||
| "PCM/adaptor/PCM-HPC/PCM-AC/rpc/hpcAC" | |||
| "github.com/zeromicro/go-zero/zrpc" | |||
| "google.golang.org/grpc" | |||
| ) | |||
| type ( | |||
| HistoryJob = hpcAC.HistoryJob | |||
| Job = hpcAC.Job | |||
| ListHistoryJobReq = hpcAC.ListHistoryJobReq | |||
| ListHistoryJobResp = hpcAC.ListHistoryJobResp | |||
| ListJobReq = hpcAC.ListJobReq | |||
| ListJobResp = hpcAC.ListJobResp | |||
| MapAppJobInfo = hpcAC.MapAppJobInfo | |||
| SubmitJobReq = hpcAC.SubmitJobReq | |||
| SubmitJobResp = hpcAC.SubmitJobResp | |||
| HpcAC interface { | |||
| // ListJob list all jobs | |||
| ListJob(ctx context.Context, in *ListJobReq, opts ...grpc.CallOption) (*ListJobResp, error) | |||
| // ListHistoryJob list all history jobs | |||
| ListHistoryJob(ctx context.Context, in *ListHistoryJobReq, opts ...grpc.CallOption) (*ListHistoryJobResp, error) | |||
| // Submit job | |||
| SubmitJob(ctx context.Context, in *SubmitJobReq, opts ...grpc.CallOption) (*SubmitJobResp, error) | |||
| } | |||
| defaultHpcAC struct { | |||
| cli zrpc.Client | |||
| } | |||
| ) | |||
| func NewHpcAC(cli zrpc.Client) HpcAC { | |||
| return &defaultHpcAC{ | |||
| cli: cli, | |||
| } | |||
| } | |||
| // ListJob list all jobs | |||
| func (m *defaultHpcAC) ListJob(ctx context.Context, in *ListJobReq, opts ...grpc.CallOption) (*ListJobResp, error) { | |||
| client := hpcAC.NewHpcACClient(m.cli.Conn()) | |||
| return client.ListJob(ctx, in, opts...) | |||
| } | |||
| // ListHistoryJob list all history jobs | |||
| func (m *defaultHpcAC) ListHistoryJob(ctx context.Context, in *ListHistoryJobReq, opts ...grpc.CallOption) (*ListHistoryJobResp, error) { | |||
| client := hpcAC.NewHpcACClient(m.cli.Conn()) | |||
| return client.ListHistoryJob(ctx, in, opts...) | |||
| } | |||
| // Submit job | |||
| func (m *defaultHpcAC) SubmitJob(ctx context.Context, in *SubmitJobReq, opts ...grpc.CallOption) (*SubmitJobResp, error) { | |||
| client := hpcAC.NewHpcACClient(m.cli.Conn()) | |||
| return client.SubmitJob(ctx, in, opts...) | |||
| } | |||
| @@ -1,9 +1,9 @@ | |||
| package logic | |||
| import ( | |||
| "PCM/adaptor/PCM-HPC/PCM-AC/rpc/hpcAC" | |||
| "PCM/adaptor/PCM-HPC/PCM-AC/rpc/internal/svc" | |||
| "PCM/adaptor/PCM-HPC/PCM-AC/rpc/internal/util" | |||
| "PCM/adaptor/PCM-HPC/PCM-AC/rpc/slurmShuguang" | |||
| "context" | |||
| "io" | |||
| "log" | |||
| @@ -31,12 +31,12 @@ func NewListHistoryJobLogic(ctx context.Context, svcCtx *svc.ServiceContext) *Li | |||
| } | |||
| // ListHistoryJob list all jobs from slurmdb | |||
| func (l *ListHistoryJobLogic) ListHistoryJob(in *slurmShuguang.ListHistoryJobReq) (*slurmShuguang.ListHistoryJobResp, error) { | |||
| func (l *ListHistoryJobLogic) ListHistoryJob(in *hpcAC.ListHistoryJobReq) (*hpcAC.ListHistoryJobResp, error) { | |||
| //tokenUrl := l.svcCtx.Config.TokenUrl | |||
| //stateUrl = l.svcCtx.Config.StateUrl | |||
| //clusterUrl = l.svcCtx.Config.ClusterUrl | |||
| var resp slurmShuguang.ListHistoryJobResp | |||
| var resp hpcAC.ListHistoryJobResp | |||
| jobHistoryUrl := "hpc/openapi/v2/historyjobs?" | |||
| ClusterId := util.GetClusterId() | |||
| @@ -91,11 +91,11 @@ func (l *ListHistoryJobLogic) ListHistoryJob(in *slurmShuguang.ListHistoryJobReq | |||
| } | |||
| }(respUrl.Body) | |||
| var historyJobs []*slurmShuguang.HistoryJob | |||
| var historyJobs []*hpcAC.HistoryJob | |||
| for index := range rows { | |||
| jobShuguang := jobHistoryList.GetIndex(index) | |||
| var job slurmShuguang.HistoryJob | |||
| var job hpcAC.HistoryJob | |||
| job.JobId, _ = strconv.ParseInt(jobShuguang.Get("jobId").MustString(), 10, 8) | |||
| job.JobName = jobShuguang.Get("jobName").MustString() | |||
| @@ -1,9 +1,9 @@ | |||
| package logic | |||
| import ( | |||
| "PCM/adaptor/PCM-HPC/PCM-AC/rpc/hpcAC" | |||
| "PCM/adaptor/PCM-HPC/PCM-AC/rpc/internal/svc" | |||
| "PCM/adaptor/PCM-HPC/PCM-AC/rpc/internal/util" | |||
| "PCM/adaptor/PCM-HPC/PCM-AC/rpc/slurmShuguang" | |||
| "context" | |||
| "github.com/bitly/go-simplejson" | |||
| "io" | |||
| @@ -31,9 +31,9 @@ func NewListJobLogic(ctx context.Context, svcCtx *svc.ServiceContext) *ListJobLo | |||
| } | |||
| // ListJob list all jobs | |||
| func (l *ListJobLogic) ListJob(in *slurmShuguang.ListJobReq) (*slurmShuguang.ListJobResp, error) { | |||
| func (l *ListJobLogic) ListJob(in *hpcAC.ListJobReq) (*hpcAC.ListJobResp, error) { | |||
| var resp slurmShuguang.ListJobResp | |||
| var resp hpcAC.ListJobResp | |||
| jobUrl := "hpc/openapi/v2/jobs?" | |||
| ClusterId := util.GetClusterId() | |||
| @@ -87,11 +87,11 @@ func (l *ListJobLogic) ListJob(in *slurmShuguang.ListJobReq) (*slurmShuguang.Lis | |||
| } | |||
| }(respUrl.Body) | |||
| var Jobs []*slurmShuguang.Job | |||
| var Jobs []*hpcAC.Job | |||
| for index := range rows { | |||
| jobShuguang := jobList.GetIndex(index) | |||
| var job slurmShuguang.Job | |||
| var job hpcAC.Job | |||
| job.AppType = jobShuguang.Get("appType").MustString() | |||
| job.ErrorPath = jobShuguang.Get("errorPath").MustString() | |||
| @@ -1,9 +1,9 @@ | |||
| package logic | |||
| import ( | |||
| "PCM/adaptor/PCM-HPC/PCM-AC/rpc/hpcAC" | |||
| "PCM/adaptor/PCM-HPC/PCM-AC/rpc/internal/svc" | |||
| "PCM/adaptor/PCM-HPC/PCM-AC/rpc/internal/util" | |||
| "PCM/adaptor/PCM-HPC/PCM-AC/rpc/slurmShuguang" | |||
| "bytes" | |||
| "context" | |||
| "encoding/json" | |||
| @@ -30,8 +30,8 @@ func NewSubmitJobLogic(ctx context.Context, svcCtx *svc.ServiceContext) *SubmitJ | |||
| } | |||
| } | |||
| func (l *SubmitJobLogic) SubmitJob(in *slurmShuguang.SubmitJobReq) (*slurmShuguang.SubmitJobResp, error) { | |||
| resp := &slurmShuguang.SubmitJobResp{} | |||
| func (l *SubmitJobLogic) SubmitJob(in *hpcAC.SubmitJobReq) (*hpcAC.SubmitJobResp, error) { | |||
| resp := &hpcAC.SubmitJobResp{} | |||
| jobSubmitUrl := "hpc/openapi/v2/apptemplates/{apptype}/{appname}/job" | |||
| jobSubmitUrl = strings.Replace(jobSubmitUrl, "{apptype}", in.Apptype, -1) | |||
| @@ -0,0 +1,41 @@ | |||
| // Code generated by goctl. DO NOT EDIT. | |||
| // Source: hpcAC.proto | |||
| package server | |||
| import ( | |||
| "context" | |||
| "PCM/adaptor/PCM-HPC/PCM-AC/rpc/hpcAC" | |||
| "PCM/adaptor/PCM-HPC/PCM-AC/rpc/internal/logic" | |||
| "PCM/adaptor/PCM-HPC/PCM-AC/rpc/internal/svc" | |||
| ) | |||
| type HpcACServer struct { | |||
| svcCtx *svc.ServiceContext | |||
| hpcAC.UnimplementedHpcACServer | |||
| } | |||
| func NewHpcACServer(svcCtx *svc.ServiceContext) *HpcACServer { | |||
| return &HpcACServer{ | |||
| svcCtx: svcCtx, | |||
| } | |||
| } | |||
| // ListJob list all jobs | |||
| func (s *HpcACServer) ListJob(ctx context.Context, in *hpcAC.ListJobReq) (*hpcAC.ListJobResp, error) { | |||
| l := logic.NewListJobLogic(ctx, s.svcCtx) | |||
| return l.ListJob(in) | |||
| } | |||
| // ListHistoryJob list all history jobs | |||
| func (s *HpcACServer) ListHistoryJob(ctx context.Context, in *hpcAC.ListHistoryJobReq) (*hpcAC.ListHistoryJobResp, error) { | |||
| l := logic.NewListHistoryJobLogic(ctx, s.svcCtx) | |||
| return l.ListHistoryJob(in) | |||
| } | |||
| // Submit job | |||
| func (s *HpcACServer) SubmitJob(ctx context.Context, in *hpcAC.SubmitJobReq) (*hpcAC.SubmitJobResp, error) { | |||
| l := logic.NewSubmitJobLogic(ctx, s.svcCtx) | |||
| return l.SubmitJob(in) | |||
| } | |||
| @@ -1,40 +0,0 @@ | |||
| // Code generated by goctl. DO NOT EDIT. | |||
| // Source: slurmShuguang.proto | |||
| package server | |||
| import ( | |||
| logic2 "PCM/adaptor/PCM-HPC/PCM-AC/rpc/internal/logic" | |||
| "PCM/adaptor/PCM-HPC/PCM-AC/rpc/internal/svc" | |||
| slurmShuguang2 "PCM/adaptor/PCM-HPC/PCM-AC/rpc/slurmShuguang" | |||
| "context" | |||
| ) | |||
| type SlurmShuguangServer struct { | |||
| svcCtx *svc.ServiceContext | |||
| slurmShuguang2.UnimplementedSlurmShuguangServer | |||
| } | |||
| func NewSlurmShuguangServer(svcCtx *svc.ServiceContext) *SlurmShuguangServer { | |||
| return &SlurmShuguangServer{ | |||
| svcCtx: svcCtx, | |||
| } | |||
| } | |||
| // ListJob list all jobs | |||
| func (s *SlurmShuguangServer) ListJob(ctx context.Context, in *slurmShuguang2.ListJobReq) (*slurmShuguang2.ListJobResp, error) { | |||
| l := logic2.NewListJobLogic(ctx, s.svcCtx) | |||
| return l.ListJob(in) | |||
| } | |||
| // ListHistoryJob list all history jobs | |||
| func (s *SlurmShuguangServer) ListHistoryJob(ctx context.Context, in *slurmShuguang2.ListHistoryJobReq) (*slurmShuguang2.ListHistoryJobResp, error) { | |||
| l := logic2.NewListHistoryJobLogic(ctx, s.svcCtx) | |||
| return l.ListHistoryJob(in) | |||
| } | |||
| // Submit job | |||
| func (s *SlurmShuguangServer) SubmitJob(ctx context.Context, in *slurmShuguang2.SubmitJobReq) (*slurmShuguang2.SubmitJobResp, error) { | |||
| l := logic2.NewSubmitJobLogic(ctx, s.svcCtx) | |||
| return l.SubmitJob(in) | |||
| } | |||
| @@ -69,7 +69,7 @@ type dataToken struct { | |||
| Token string `json:"token"` | |||
| } | |||
| var configFile = flag.String("flll", "C:\\Users\\admin\\Documents\\122\\jcce\\pcm\\adaptor\\slurm\\slurmShuguang\\rpc\\etc\\slurmshuguang.yaml", "the config file") | |||
| var configFile = flag.String("f2", "adaptor/PCM-HPC/PCM-AC/rpc/etc/hpcac.yaml", "the config file") | |||
| func GetClusterId() int { | |||
| httpClient := http.Client{Timeout: time.Duration(3) * time.Second} | |||
| @@ -1,7 +1,7 @@ | |||
| syntax = "proto3"; | |||
| package slurmShuguang; | |||
| option go_package = "/slurmShuguang"; | |||
| package hpcAC; | |||
| option go_package = "/hpcAC"; | |||
| @@ -112,8 +112,8 @@ message MapAppJobInfo{ | |||
| /******************Job(Submit) End*************************/ | |||
| // Slurm Services for Shuguang Branch | |||
| service SlurmShuguang { | |||
| // HPC Services for AC | |||
| service hpcAC { | |||
| //ListJob list all jobs | |||
| rpc ListJob(ListJobReq) returns (ListJobResp); | |||
| @@ -1,183 +0,0 @@ | |||
| // Code generated by protoc-gen-go-grpc. DO NOT EDIT. | |||
| // versions: | |||
| // - protoc-gen-go-grpc v1.2.0 | |||
| // - protoc v3.19.4 | |||
| // source: slurmShuguang.proto | |||
| package slurmShuguang | |||
| 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 | |||
| // SlurmShuguangClient is the client API for SlurmShuguang 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 SlurmShuguangClient interface { | |||
| // ListJob list all jobs | |||
| ListJob(ctx context.Context, in *ListJobReq, opts ...grpc.CallOption) (*ListJobResp, error) | |||
| // ListHistoryJob list all history jobs | |||
| ListHistoryJob(ctx context.Context, in *ListHistoryJobReq, opts ...grpc.CallOption) (*ListHistoryJobResp, error) | |||
| // Submit job | |||
| SubmitJob(ctx context.Context, in *SubmitJobReq, opts ...grpc.CallOption) (*SubmitJobResp, error) | |||
| } | |||
| type slurmShuguangClient struct { | |||
| cc grpc.ClientConnInterface | |||
| } | |||
| func NewSlurmShuguangClient(cc grpc.ClientConnInterface) SlurmShuguangClient { | |||
| return &slurmShuguangClient{cc} | |||
| } | |||
| func (c *slurmShuguangClient) ListJob(ctx context.Context, in *ListJobReq, opts ...grpc.CallOption) (*ListJobResp, error) { | |||
| out := new(ListJobResp) | |||
| err := c.cc.Invoke(ctx, "/slurmShuguang.SlurmShuguang/ListJob", in, out, opts...) | |||
| if err != nil { | |||
| return nil, err | |||
| } | |||
| return out, nil | |||
| } | |||
| func (c *slurmShuguangClient) ListHistoryJob(ctx context.Context, in *ListHistoryJobReq, opts ...grpc.CallOption) (*ListHistoryJobResp, error) { | |||
| out := new(ListHistoryJobResp) | |||
| err := c.cc.Invoke(ctx, "/slurmShuguang.SlurmShuguang/ListHistoryJob", in, out, opts...) | |||
| if err != nil { | |||
| return nil, err | |||
| } | |||
| return out, nil | |||
| } | |||
| func (c *slurmShuguangClient) SubmitJob(ctx context.Context, in *SubmitJobReq, opts ...grpc.CallOption) (*SubmitJobResp, error) { | |||
| out := new(SubmitJobResp) | |||
| err := c.cc.Invoke(ctx, "/slurmShuguang.SlurmShuguang/SubmitJob", in, out, opts...) | |||
| if err != nil { | |||
| return nil, err | |||
| } | |||
| return out, nil | |||
| } | |||
| // SlurmShuguangServer is the server API for SlurmShuguang service. | |||
| // All implementations must embed UnimplementedSlurmShuguangServer | |||
| // for forward compatibility | |||
| type SlurmShuguangServer interface { | |||
| // ListJob list all jobs | |||
| ListJob(context.Context, *ListJobReq) (*ListJobResp, error) | |||
| // ListHistoryJob list all history jobs | |||
| ListHistoryJob(context.Context, *ListHistoryJobReq) (*ListHistoryJobResp, error) | |||
| // Submit job | |||
| SubmitJob(context.Context, *SubmitJobReq) (*SubmitJobResp, error) | |||
| mustEmbedUnimplementedSlurmShuguangServer() | |||
| } | |||
| // UnimplementedSlurmShuguangServer must be embedded to have forward compatible implementations. | |||
| type UnimplementedSlurmShuguangServer struct { | |||
| } | |||
| func (UnimplementedSlurmShuguangServer) ListJob(context.Context, *ListJobReq) (*ListJobResp, error) { | |||
| return nil, status.Errorf(codes.Unimplemented, "method ListJob not implemented") | |||
| } | |||
| func (UnimplementedSlurmShuguangServer) ListHistoryJob(context.Context, *ListHistoryJobReq) (*ListHistoryJobResp, error) { | |||
| return nil, status.Errorf(codes.Unimplemented, "method ListHistoryJob not implemented") | |||
| } | |||
| func (UnimplementedSlurmShuguangServer) SubmitJob(context.Context, *SubmitJobReq) (*SubmitJobResp, error) { | |||
| return nil, status.Errorf(codes.Unimplemented, "method SubmitJob not implemented") | |||
| } | |||
| func (UnimplementedSlurmShuguangServer) mustEmbedUnimplementedSlurmShuguangServer() {} | |||
| // UnsafeSlurmShuguangServer may be embedded to opt out of forward compatibility for this service. | |||
| // Use of this interface is not recommended, as added methods to SlurmShuguangServer will | |||
| // result in compilation errors. | |||
| type UnsafeSlurmShuguangServer interface { | |||
| mustEmbedUnimplementedSlurmShuguangServer() | |||
| } | |||
| func RegisterSlurmShuguangServer(s grpc.ServiceRegistrar, srv SlurmShuguangServer) { | |||
| s.RegisterService(&SlurmShuguang_ServiceDesc, srv) | |||
| } | |||
| func _SlurmShuguang_ListJob_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { | |||
| in := new(ListJobReq) | |||
| if err := dec(in); err != nil { | |||
| return nil, err | |||
| } | |||
| if interceptor == nil { | |||
| return srv.(SlurmShuguangServer).ListJob(ctx, in) | |||
| } | |||
| info := &grpc.UnaryServerInfo{ | |||
| Server: srv, | |||
| FullMethod: "/slurmShuguang.SlurmShuguang/ListJob", | |||
| } | |||
| handler := func(ctx context.Context, req interface{}) (interface{}, error) { | |||
| return srv.(SlurmShuguangServer).ListJob(ctx, req.(*ListJobReq)) | |||
| } | |||
| return interceptor(ctx, in, info, handler) | |||
| } | |||
| func _SlurmShuguang_ListHistoryJob_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { | |||
| in := new(ListHistoryJobReq) | |||
| if err := dec(in); err != nil { | |||
| return nil, err | |||
| } | |||
| if interceptor == nil { | |||
| return srv.(SlurmShuguangServer).ListHistoryJob(ctx, in) | |||
| } | |||
| info := &grpc.UnaryServerInfo{ | |||
| Server: srv, | |||
| FullMethod: "/slurmShuguang.SlurmShuguang/ListHistoryJob", | |||
| } | |||
| handler := func(ctx context.Context, req interface{}) (interface{}, error) { | |||
| return srv.(SlurmShuguangServer).ListHistoryJob(ctx, req.(*ListHistoryJobReq)) | |||
| } | |||
| return interceptor(ctx, in, info, handler) | |||
| } | |||
| func _SlurmShuguang_SubmitJob_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { | |||
| in := new(SubmitJobReq) | |||
| if err := dec(in); err != nil { | |||
| return nil, err | |||
| } | |||
| if interceptor == nil { | |||
| return srv.(SlurmShuguangServer).SubmitJob(ctx, in) | |||
| } | |||
| info := &grpc.UnaryServerInfo{ | |||
| Server: srv, | |||
| FullMethod: "/slurmShuguang.SlurmShuguang/SubmitJob", | |||
| } | |||
| handler := func(ctx context.Context, req interface{}) (interface{}, error) { | |||
| return srv.(SlurmShuguangServer).SubmitJob(ctx, req.(*SubmitJobReq)) | |||
| } | |||
| return interceptor(ctx, in, info, handler) | |||
| } | |||
| // SlurmShuguang_ServiceDesc is the grpc.ServiceDesc for SlurmShuguang service. | |||
| // It's only intended for direct use with grpc.RegisterService, | |||
| // and not to be introspected or modified (even as a copy) | |||
| var SlurmShuguang_ServiceDesc = grpc.ServiceDesc{ | |||
| ServiceName: "slurmShuguang.SlurmShuguang", | |||
| HandlerType: (*SlurmShuguangServer)(nil), | |||
| Methods: []grpc.MethodDesc{ | |||
| { | |||
| MethodName: "ListJob", | |||
| Handler: _SlurmShuguang_ListJob_Handler, | |||
| }, | |||
| { | |||
| MethodName: "ListHistoryJob", | |||
| Handler: _SlurmShuguang_ListHistoryJob_Handler, | |||
| }, | |||
| { | |||
| MethodName: "SubmitJob", | |||
| Handler: _SlurmShuguang_SubmitJob_Handler, | |||
| }, | |||
| }, | |||
| Streams: []grpc.StreamDesc{}, | |||
| Metadata: "slurmShuguang.proto", | |||
| } | |||
| @@ -1,61 +0,0 @@ | |||
| // Code generated by goctl. DO NOT EDIT. | |||
| // Source: slurmShuguang.proto | |||
| package slurmshuguangclient | |||
| import ( | |||
| slurmShuguang2 "PCM/adaptor/PCM-HPC/PCM-AC/rpc/slurmShuguang" | |||
| "context" | |||
| "github.com/zeromicro/go-zero/zrpc" | |||
| "google.golang.org/grpc" | |||
| ) | |||
| type ( | |||
| HistoryJob = slurmShuguang2.HistoryJob | |||
| Job = slurmShuguang2.Job | |||
| ListHistoryJobReq = slurmShuguang2.ListHistoryJobReq | |||
| ListHistoryJobResp = slurmShuguang2.ListHistoryJobResp | |||
| ListJobReq = slurmShuguang2.ListJobReq | |||
| ListJobResp = slurmShuguang2.ListJobResp | |||
| MapAppJobInfo = slurmShuguang2.MapAppJobInfo | |||
| SubmitJobReq = slurmShuguang2.SubmitJobReq | |||
| SubmitJobResp = slurmShuguang2.SubmitJobResp | |||
| SlurmShuguang interface { | |||
| // ListJob list all jobs | |||
| ListJob(ctx context.Context, in *ListJobReq, opts ...grpc.CallOption) (*ListJobResp, error) | |||
| // ListHistoryJob list all history jobs | |||
| ListHistoryJob(ctx context.Context, in *ListHistoryJobReq, opts ...grpc.CallOption) (*ListHistoryJobResp, error) | |||
| // Submit job | |||
| SubmitJob(ctx context.Context, in *SubmitJobReq, opts ...grpc.CallOption) (*SubmitJobResp, error) | |||
| } | |||
| defaultSlurmShuguang struct { | |||
| cli zrpc.Client | |||
| } | |||
| ) | |||
| func NewSlurmShuguang(cli zrpc.Client) SlurmShuguang { | |||
| return &defaultSlurmShuguang{ | |||
| cli: cli, | |||
| } | |||
| } | |||
| // ListJob list all jobs | |||
| func (m *defaultSlurmShuguang) ListJob(ctx context.Context, in *ListJobReq, opts ...grpc.CallOption) (*ListJobResp, error) { | |||
| client := slurmShuguang2.NewSlurmShuguangClient(m.cli.Conn()) | |||
| return client.ListJob(ctx, in, opts...) | |||
| } | |||
| // ListHistoryJob list all history jobs | |||
| func (m *defaultSlurmShuguang) ListHistoryJob(ctx context.Context, in *ListHistoryJobReq, opts ...grpc.CallOption) (*ListHistoryJobResp, error) { | |||
| client := slurmShuguang2.NewSlurmShuguangClient(m.cli.Conn()) | |||
| return client.ListHistoryJob(ctx, in, opts...) | |||
| } | |||
| // Submit job | |||
| func (m *defaultSlurmShuguang) SubmitJob(ctx context.Context, in *SubmitJobReq, opts ...grpc.CallOption) (*SubmitJobResp, error) { | |||
| client := slurmShuguang2.NewSlurmShuguangClient(m.cli.Conn()) | |||
| return client.SubmitJob(ctx, in, opts...) | |||
| } | |||
| @@ -0,0 +1,16 @@ | |||
| Name: hpcCoreApi | |||
| Host: 0.0.0.0 | |||
| Port: 8999 | |||
| DataSourceName: root:uJpLd6u-J?HC1@(106.53.150.192:3306)/slurm | |||
| #rpc | |||
| ACRpcConf: | |||
| Endpoints: | |||
| - 127.0.0.1:2001 | |||
| NonBlock: true | |||
| #rpc | |||
| THRpcConf: | |||
| Endpoints: | |||
| - 127.0.0.1:2002 | |||
| NonBlock: true | |||
| @@ -1,4 +0,0 @@ | |||
| Name: gateway-api | |||
| Host: 0.0.0.0 | |||
| Port: 8999 | |||
| DataSourceName: root:uJpLd6u-J?HC1@(106.53.150.192:3306)/slurm | |||
| @@ -26,14 +26,14 @@ type Job { | |||
| DerivedEc uint32 `json:"derivedEc"` | |||
| EligibleTime int64 `json:"eligibleTime"` | |||
| EndTime int64 `json:"endTime"` | |||
| ExcNodes string `json:"excNodes"` //NodeUsed in shuguang | |||
| ExcNodes string `json:"excNodes"` //NodeUsed in ac | |||
| ExcNodeInx int32 `json:"excNodeInx"` | |||
| ExitCode uint32 `json:"exitCode"` | |||
| Features string `json:"features"` | |||
| Gres string `json:"gres"` | |||
| GroupId uint32 `json:"groupId"` | |||
| JobId uint32 `json:"jobId"` //JobId in shuguang | |||
| JobState uint32 `json:"jobState"` //JobStatus in shuguang | |||
| JobId uint32 `json:"jobId"` //JobId in ac | |||
| JobState uint32 `json:"jobState"` //JobStatus in ac | |||
| Licenses string `json:"licenses"` | |||
| MaxCpus uint32 `json:"maxCpus"` | |||
| MaxNodes uint32 `json:"maxNodes"` | |||
| @@ -42,7 +42,7 @@ type Job { | |||
| SocketsPerNode uint32 `json:"socketsPerNode"` | |||
| CoresPerSocket uint32 `json:"coresPerSocket"` | |||
| ThreadsPerCore uint32 `json:"threadsPerCore"` | |||
| Name string `json:"name"` //JobName in shuguang | |||
| Name string `json:"name"` //JobName in ac | |||
| Network string `json:"network"` | |||
| Nodes string `json:"nodes"` | |||
| Nice uint32 `json:"nice"` | |||
| @@ -52,8 +52,8 @@ type Job { | |||
| NtasksPerSocket uint32 `json:"ntasksPerSocket"` | |||
| NtasksPerBoard uint32 `json:"ntasksPerBoard"` | |||
| NumNodes uint32 `json:"numNodes"` | |||
| NumCpus uint32 `json:"numCpus"` //ProcNumUsed in shuguang | |||
| Partition string `json:"partition"` //Queue in shuguang | |||
| NumCpus uint32 `json:"numCpus"` //ProcNumUsed in ac | |||
| Partition string `json:"partition"` //Queue in ac | |||
| PnMinMemory uint32 `json:"pnMinMemory"` | |||
| PnMinCpus uint32 `json:"pnMinCpus"` | |||
| PnMinTmpDisk uint32 `json:"pnMinTmpDisk"` | |||
| @@ -70,20 +70,20 @@ type Job { | |||
| ResvName string `json:"resvName"` | |||
| Shared uint32 `json:"shared"` | |||
| ShowFlags uint32 `json:"showFlags"` | |||
| StartTime int64 `json:"startTime"` //JobStartTime in shuguang | |||
| StartTime int64 `json:"startTime"` //JobStartTime in ac | |||
| StateDesc string `json:"stateDesc"` | |||
| StateReason uint32 `json:"stateReason"` | |||
| SubmitTime int64 `json:"submitTime"` | |||
| SuspendTime int64 `json:"suspendTime"` | |||
| TimeLimit uint32 `json:"timeLimit"` | |||
| TimeMin uint32 `json:"timeMin"` | |||
| UserId uint32 `json:"userId"` //User in shuguang | |||
| UserId uint32 `json:"userId"` //User in ac | |||
| PreemptTime int64 `json:"preemptTime"` | |||
| Wait4Switch uint32 `json:"wait4Switch"` | |||
| Wckey string `json:"wckey"` | |||
| WorkDir string `json:"workDir"` //WorkDir in shuguang | |||
| WorkDir string `json:"workDir"` //WorkDir in ac | |||
| /****shuguang****/ | |||
| /****ac****/ | |||
| JobRunTime string `json:"jobRunTime"` | |||
| JobmanagerId string `json:"jobmanagerId"` | |||
| JobmanagerName string `json:"jobmanagerName"` | |||
| @@ -92,7 +92,7 @@ type Job { | |||
| OutputPath string `json:"outputPath"` | |||
| Reason string `json:"reason"` | |||
| AppType string `json:"appType"` | |||
| /****shuguang****/ | |||
| /****ac****/ | |||
| } | |||
| type ( | |||
| @@ -109,7 +109,7 @@ type ( | |||
| type HistoryJob { | |||
| SlurmVersion string `json:"slurmVersion"` | |||
| AllocCPU uint32 `json:"allocCPU"` | |||
| AllocNodes uint32 `json:"allocNodes"` //Nodect 分配的节点数 in shuguang | |||
| AllocNodes uint32 `json:"allocNodes"` //Nodect 分配的节点数 in ac | |||
| Account string `json:"account"` | |||
| AssocId uint32 `json:"assocId"` | |||
| BlockId string `json:"blockId"` | |||
| @@ -118,14 +118,14 @@ type HistoryJob { | |||
| DerivedEs string `json:"derivedEs"` | |||
| Elapsed uint32 `json:"elapsed"` | |||
| Eligible int64 `json:"eligible"` | |||
| End int64 `json:"end"` //JobEndTime 作业结束时间 in shuguang | |||
| ExitCode uint32 `json:"exitCode"` //JobExitStatus 作业退出码 in shuguang | |||
| End int64 `json:"end"` //JobEndTime 作业结束时间 in ac | |||
| ExitCode uint32 `json:"exitCode"` //JobExitStatus 作业退出码 in ac | |||
| Gid uint32 `json:"gid"` | |||
| JobId uint32 `json:"jobId"` //JobId in shuguang | |||
| JobName string `json:"jobName"` //JobName in shuguang | |||
| JobId uint32 `json:"jobId"` //JobId in ac | |||
| JobName string `json:"jobName"` //JobName in ac | |||
| Lft uint32 `json:"lft"` | |||
| Partition string `json:"partition"` //Queue 队列名 in shuguang | |||
| Nodes string `json:"nodes"` //JobExecHost 作业执行节点 in shuguang | |||
| Partition string `json:"partition"` //Queue 队列名 in ac | |||
| Nodes string `json:"nodes"` //JobExecHost 作业执行节点 in ac | |||
| Priority uint32 `json:"priority"` | |||
| Qosid uint32 `json:"qosid"` | |||
| ReqCpus uint32 `json:"reqCpus"` | |||
| @@ -133,8 +133,8 @@ type HistoryJob { | |||
| Requid uint32 `json:"requid"` | |||
| Resvid uint32 `json:"resvid"` | |||
| ShowFull uint32 `json:"showFull"` | |||
| Start int64 `json:"start"` //JobStartTime 作业启动时间 in shuguang | |||
| State uint32 `json:"state"` //JobState 作业状态 in shuguang | |||
| Start int64 `json:"start"` //JobStartTime 作业启动时间 in ac | |||
| State uint32 `json:"state"` //JobState 作业状态 in ac | |||
| Submit int64 `json:"submit"` | |||
| Suspended uint32 `json:"suspended"` | |||
| SysCpuSec uint32 `json:"sysCpuSec"` | |||
| @@ -144,19 +144,19 @@ type HistoryJob { | |||
| TotCpuUsec uint32 `json:"totCpuUsec"` | |||
| TrackSteps uint32 `json:"trackSteps"` | |||
| Uid uint32 `json:"uid"` | |||
| User string `json:"user"` //UserName 用户名 in shuguang | |||
| User string `json:"user"` //UserName 用户名 in ac | |||
| UserCpuSec uint32 `json:"userCpuSec"` | |||
| UserCpuUsec uint32 `json:"userCpuUsec"` | |||
| Wckey string `json:"wckey"` | |||
| Wckeyid uint32 `json:"wckeyid"` | |||
| WorkDir string `json:"workDir"` //Workdir 工作空间 in shuguang | |||
| /****************parmas from shuguang********************/ | |||
| WorkDir string `json:"workDir"` //Workdir 工作空间 in ac | |||
| /****************parmas from ac********************/ | |||
| AcctTime string `json:"acctTime"` // 记账时间 | |||
| AppType string `json:"appType"` // 作业应用类型 | |||
| JobQueueTime string `json:"jobQueueTime"` //作业入队列时间 | |||
| JobWalltimeUsed string `json:"jobWalltimeUsed"` //作业实际使用的Walltime,单位为秒 | |||
| JobManagerId int `json:"jobmanagerId"` //区域id | |||
| /****************parmas from shuguang********************/ | |||
| /****************parmas from ac********************/ | |||
| } | |||
| type ( | |||
| @@ -181,12 +181,12 @@ type ( | |||
| submitJobReq { | |||
| SlurmVersion string `json:"slurmVersion"` | |||
| /****************parmas from shuguang********************/ | |||
| /****************parmas from ac********************/ | |||
| Apptype string `json:"apptype,optional"` | |||
| Appname string `json:"appname,optional"` | |||
| StrJobManagerID int64 `json:"strJobManagerID,optional"` | |||
| MapAppJobInfo MapAppJobInfo `json:"mapAppJobInfo,optional"` | |||
| /****************parmas from shuguang********************/ | |||
| /****************parmas from ac********************/ | |||
| Account string `json:"account,optional"` // | |||
| Acctg_freq string `json:"acctg_freq,optional"` | |||
| @@ -340,7 +340,7 @@ type ( | |||
| } | |||
| ) | |||
| service slurmcore-api { | |||
| service hpcCoreApi { | |||
| @handler listJobHandler | |||
| get /listJob (listJobReq) returns (listJobResp) | |||
| @@ -1,17 +1,18 @@ | |||
| package main | |||
| import ( | |||
| "flag" | |||
| "fmt" | |||
| "PCM/adaptor/PCM-HPC/PCM-HPC-CORE/api/internal/config" | |||
| "PCM/adaptor/PCM-HPC/PCM-HPC-CORE/api/internal/handler" | |||
| "PCM/adaptor/PCM-HPC/PCM-HPC-CORE/api/internal/svc" | |||
| "flag" | |||
| "fmt" | |||
| "github.com/zeromicro/go-zero/core/conf" | |||
| "github.com/zeromicro/go-zero/rest" | |||
| ) | |||
| var configFile = flag.String("f", "adaptor/PCM-HPC/PCM-HPC-CORE/api/etc/slurmcore-api.yaml", "the config file") | |||
| var configFile = flag.String("f", "adaptor/PCM-HPC/PCM-HPC-CORE/api/etc/hpccoreapi.yaml", "the config file") | |||
| func main() { | |||
| flag.Parse() | |||
| @@ -7,7 +7,7 @@ import ( | |||
| type Config struct { | |||
| rest.RestConf | |||
| DataSourceName string | |||
| ShuguangRpcConf zrpc.RpcClientConf | |||
| TianheRpcConf zrpc.RpcClientConf | |||
| DataSourceName string | |||
| ACRpcConf zrpc.RpcClientConf | |||
| THRpcConf zrpc.RpcClientConf | |||
| } | |||
| @@ -2,9 +2,10 @@ | |||
| package handler | |||
| import ( | |||
| "PCM/adaptor/PCM-HPC/PCM-HPC-CORE/api/internal/svc" | |||
| "net/http" | |||
| "PCM/adaptor/PCM-HPC/PCM-HPC-CORE/api/internal/svc" | |||
| "github.com/zeromicro/go-zero/rest" | |||
| ) | |||
| @@ -1,10 +1,10 @@ | |||
| package logic | |||
| import ( | |||
| "PCM/adaptor/PCM-HPC/PCM-AC/rpc/slurmShuguang" | |||
| "PCM/adaptor/PCM-HPC/PCM-AC/rpc/hpcAC" | |||
| "PCM/adaptor/PCM-HPC/PCM-HPC-CORE/api/internal/svc" | |||
| "PCM/adaptor/PCM-HPC/PCM-HPC-CORE/api/internal/types" | |||
| "PCM/adaptor/PCM-HPC/PCM-TH/rpc/slurmTianhe" | |||
| "PCM/adaptor/PCM-HPC/PCM-TH/rpc/hpcTH" | |||
| "PCM/common/tool" | |||
| "context" | |||
| "github.com/jinzhu/copier" | |||
| @@ -29,37 +29,37 @@ func NewListHistoryJobLogic(ctx context.Context, svcCtx *svc.ServiceContext) *Li | |||
| func (l *ListHistoryJobLogic) ListHistoryJob(req *types.ListHistoryJobReq) (resp *types.ListHistoryJobResp, err error) { | |||
| resp = &types.ListHistoryJobResp{} | |||
| shuguangReq := &slurmShuguang.ListHistoryJobReq{} | |||
| acReq := &hpcAC.ListHistoryJobReq{} | |||
| if req.SlurmVersion == "shuguang" { | |||
| shuguangReq.StartTime = req.StartTime | |||
| shuguangReq.EndTime = req.EndTime | |||
| shuguangReq.TimeType = req.TimeType | |||
| shuguangReq.Start = req.Start | |||
| shuguangReq.Limit = req.Limit | |||
| shuguangReq.IsQueryByQueueTime = req.IsQueryByQueueTime | |||
| if req.SlurmVersion == "ac" { | |||
| acReq.StartTime = req.StartTime | |||
| acReq.EndTime = req.EndTime | |||
| acReq.TimeType = req.TimeType | |||
| acReq.Start = req.Start | |||
| acReq.Limit = req.Limit | |||
| acReq.IsQueryByQueueTime = req.IsQueryByQueueTime | |||
| } else { | |||
| shuguangReq.StartTime = "2022-12-01 00:00:00" | |||
| shuguangReq.EndTime = time.Now().Format("2006-01-02 15:04:05") | |||
| shuguangReq.TimeType = "CUSTOM" | |||
| shuguangReq.Start = 0 | |||
| shuguangReq.Limit = 25 | |||
| shuguangReq.IsQueryByQueueTime = 0 | |||
| acReq.StartTime = "2022-12-01 00:00:00" | |||
| acReq.EndTime = time.Now().Format("2006-01-02 15:04:05") | |||
| acReq.TimeType = "CUSTOM" | |||
| acReq.Start = 0 | |||
| acReq.Limit = 25 | |||
| acReq.IsQueryByQueueTime = 0 | |||
| } | |||
| listHistoryJobRespShuguang, err := l.svcCtx.ShuguangRpc.ListHistoryJob(l.ctx, shuguangReq) | |||
| listHistoryJobRespAC, err := l.svcCtx.ACRpc.ListHistoryJob(l.ctx, acReq) | |||
| tianheReq := &slurmTianhe.ListHistoryJobReq{} | |||
| err = copier.CopyWithOption(tianheReq, req, copier.Option{Converters: tool.Converters}) | |||
| listHistoryJobRespTianhe, err := l.svcCtx.TianheRpc.ListHistoryJob(l.ctx, tianheReq) | |||
| thReq := &hpcTH.ListHistoryJobReq{} | |||
| err = copier.CopyWithOption(thReq, req, copier.Option{Converters: tool.Converters}) | |||
| listHistoryJobRespTianhe, err := l.svcCtx.THRpc.ListHistoryJob(l.ctx, thReq) | |||
| for i := 0; i < len(listHistoryJobRespShuguang.HistoryJobs); i++ { | |||
| historyJobShuguang := types.HistoryJob{SlurmVersion: "shuguang"} | |||
| copier.CopyWithOption(&historyJobShuguang, &listHistoryJobRespShuguang.HistoryJobs[i], copier.Option{Converters: tool.Converters}) | |||
| resp.HistoryJobs = append(resp.HistoryJobs, historyJobShuguang) | |||
| for i := 0; i < len(listHistoryJobRespAC.HistoryJobs); i++ { | |||
| historyJobAC := types.HistoryJob{SlurmVersion: "ac"} | |||
| copier.CopyWithOption(&historyJobAC, &listHistoryJobRespAC.HistoryJobs[i], copier.Option{Converters: tool.Converters}) | |||
| resp.HistoryJobs = append(resp.HistoryJobs, historyJobAC) | |||
| } | |||
| for i := 0; i < len(listHistoryJobRespTianhe.HistoryJobs); i++ { | |||
| historyJobTianhe := types.HistoryJob{SlurmVersion: "tianhe"} | |||
| historyJobTianhe := types.HistoryJob{SlurmVersion: "th"} | |||
| copier.CopyWithOption(&historyJobTianhe, &listHistoryJobRespTianhe.HistoryJobs[i], copier.Option{Converters: tool.Converters}) | |||
| resp.HistoryJobs = append(resp.HistoryJobs, historyJobTianhe) | |||
| } | |||
| @@ -1,10 +1,10 @@ | |||
| package logic | |||
| import ( | |||
| "PCM/adaptor/PCM-HPC/PCM-AC/rpc/slurmShuguang" | |||
| "PCM/adaptor/PCM-HPC/PCM-AC/rpc/hpcAC" | |||
| "PCM/adaptor/PCM-HPC/PCM-HPC-CORE/api/internal/svc" | |||
| "PCM/adaptor/PCM-HPC/PCM-HPC-CORE/api/internal/types" | |||
| "PCM/adaptor/PCM-HPC/PCM-TH/rpc/slurmTianhe" | |||
| "PCM/adaptor/PCM-HPC/PCM-TH/rpc/hpcTH" | |||
| "PCM/common/tool" | |||
| "context" | |||
| "github.com/jinzhu/copier" | |||
| @@ -29,24 +29,24 @@ func (l *ListJobLogic) ListJob(req *types.ListJobReq) (resp *types.ListJobResp, | |||
| resp = &types.ListJobResp{} | |||
| shuguangReq := &slurmShuguang.ListJobReq{} | |||
| err = copier.CopyWithOption(shuguangReq, req, copier.Option{Converters: tool.Converters}) | |||
| listJobRespShuguang, err := l.svcCtx.ShuguangRpc.ListJob(l.ctx, shuguangReq) | |||
| acReq := &hpcAC.ListJobReq{} | |||
| err = copier.CopyWithOption(acReq, req, copier.Option{Converters: tool.Converters}) | |||
| listJobRespAC, err := l.svcCtx.ACRpc.ListJob(l.ctx, acReq) | |||
| for i := 0; i < len(listJobRespShuguang.Jobs); i++ { | |||
| jobShuguang := types.Job{SlurmVersion: "shuguang"} | |||
| copier.CopyWithOption(&jobShuguang, &listJobRespShuguang.Jobs[i], copier.Option{Converters: tool.Converters}) | |||
| resp.Jobs = append(resp.Jobs, jobShuguang) | |||
| for i := 0; i < len(listJobRespAC.Jobs); i++ { | |||
| jobAC := types.Job{SlurmVersion: "ac"} | |||
| copier.CopyWithOption(&jobAC, &listJobRespAC.Jobs[i], copier.Option{Converters: tool.Converters}) | |||
| resp.Jobs = append(resp.Jobs, jobAC) | |||
| } | |||
| tianheReq := &slurmTianhe.ListJobReq{} | |||
| tianheReq := &hpcTH.ListJobReq{} | |||
| err = copier.CopyWithOption(tianheReq, req, copier.Option{Converters: tool.Converters}) | |||
| listJobRespTianhe, err := l.svcCtx.TianheRpc.ListJob(l.ctx, tianheReq) | |||
| listJobRespTH, err := l.svcCtx.THRpc.ListJob(l.ctx, tianheReq) | |||
| for i := 0; i < len(listJobRespTianhe.Jobs); i++ { | |||
| jobTianhe := types.Job{SlurmVersion: "tianhe"} | |||
| copier.CopyWithOption(&jobTianhe, &listJobRespTianhe.Jobs[i], copier.Option{Converters: tool.Converters}) | |||
| resp.Jobs = append(resp.Jobs, jobTianhe) | |||
| for i := 0; i < len(listJobRespTH.Jobs); i++ { | |||
| jobTH := types.Job{SlurmVersion: "th"} | |||
| copier.CopyWithOption(&jobTH, &listJobRespTH.Jobs[i], copier.Option{Converters: tool.Converters}) | |||
| resp.Jobs = append(resp.Jobs, jobTH) | |||
| } | |||
| resp.Code = 200 | |||
| @@ -1,10 +1,10 @@ | |||
| package logic | |||
| import ( | |||
| "PCM/adaptor/PCM-HPC/PCM-AC/rpc/slurmShuguang" | |||
| "PCM/adaptor/PCM-HPC/PCM-AC/rpc/hpcAC" | |||
| "PCM/adaptor/PCM-HPC/PCM-HPC-CORE/api/internal/svc" | |||
| "PCM/adaptor/PCM-HPC/PCM-HPC-CORE/api/internal/types" | |||
| "PCM/adaptor/PCM-HPC/PCM-TH/rpc/slurmTianhe" | |||
| "PCM/adaptor/PCM-HPC/PCM-TH/rpc/hpcTH" | |||
| "PCM/common/tool" | |||
| "PCM/common/xerr" | |||
| "context" | |||
| @@ -35,27 +35,27 @@ func (l *SubmitJobLogic) SubmitJob(req *types.SubmitJobReq) (resp *types.SubmitJ | |||
| version := req.SlurmVersion | |||
| switch version { | |||
| case "shuguang": | |||
| shuguangReq := &slurmShuguang.SubmitJobReq{} | |||
| err = copier.CopyWithOption(shuguangReq, req, copier.Option{Converters: tool.Converters}) | |||
| shuguangResp, err := l.svcCtx.ShuguangRpc.SubmitJob(l.ctx, shuguangReq) | |||
| case "ac": | |||
| acReq := &hpcAC.SubmitJobReq{} | |||
| err = copier.CopyWithOption(acReq, req, copier.Option{Converters: tool.Converters}) | |||
| acResp, err := l.svcCtx.ACRpc.SubmitJob(l.ctx, acReq) | |||
| if err != nil { | |||
| return nil, errors.Wrapf(xerr.NewErrMsg("Failed to submit job to Shuguang"), "Failed to submit job to Shuguang err : %v ,req:%+v", err, req) | |||
| return nil, errors.Wrapf(xerr.NewErrMsg("Failed to submit job to AC"), "Failed to submit job to Shuguang err : %v ,req:%+v", err, req) | |||
| } | |||
| if shuguangResp.Data == "" { | |||
| return nil, errors.Wrapf(xerr.NewErrMsg("Failed to submit job to Shuguang, job id is empty"), "Failed to submit job to Shuguang err : %v", err) | |||
| if acResp.Data == "" { | |||
| return nil, errors.Wrapf(xerr.NewErrMsg("Failed to submit job to AC, job id is empty"), "Failed to submit job to Shuguang err : %v", err) | |||
| } | |||
| coreResp.Msg = shuguangResp.Msg | |||
| coreResp.Code = shuguangResp.Code | |||
| coreResp.Data = shuguangResp.Data | |||
| coreResp.Msg = acResp.Msg | |||
| coreResp.Code = acResp.Code | |||
| coreResp.Data = acResp.Data | |||
| case "tianhe": | |||
| tianheReq := &slurmTianhe.SubmitJobReq{} | |||
| err = copier.CopyWithOption(tianheReq, req, copier.Option{Converters: tool.Converters}) | |||
| tianheResp, err := l.svcCtx.TianheRpc.SubmitJob(l.ctx, tianheReq) | |||
| case "th": | |||
| thReq := &hpcTH.SubmitJobReq{} | |||
| err = copier.CopyWithOption(thReq, req, copier.Option{Converters: tool.Converters}) | |||
| tianheResp, err := l.svcCtx.THRpc.SubmitJob(l.ctx, thReq) | |||
| if err != nil { | |||
| return nil, errors.Wrapf(xerr.NewErrMsg("Failed to submit job to Tianhe"), "Failed to submit job to Tianhe err : %v ,req:%+v", err, req) | |||
| @@ -1,9 +1,9 @@ | |||
| package svc | |||
| import ( | |||
| "PCM/adaptor/PCM-HPC/PCM-AC/rpc/slurmshuguangclient" | |||
| "PCM/adaptor/PCM-HPC/PCM-AC/rpc/hpcacclient" | |||
| "PCM/adaptor/PCM-HPC/PCM-HPC-CORE/api/internal/config" | |||
| "PCM/adaptor/PCM-HPC/PCM-TH/rpc/slurmtianheclient" | |||
| "PCM/adaptor/PCM-HPC/PCM-TH/rpc/hpcthclient" | |||
| "github.com/zeromicro/go-zero/zrpc" | |||
| "gorm.io/driver/mysql" | |||
| "gorm.io/gorm" | |||
| @@ -11,10 +11,10 @@ import ( | |||
| ) | |||
| type ServiceContext struct { | |||
| Config config.Config | |||
| DbEngin *gorm.DB | |||
| ShuguangRpc slurmshuguangclient.SlurmShuguang | |||
| TianheRpc slurmtianheclient.SlurmTianhe | |||
| Config config.Config | |||
| DbEngin *gorm.DB | |||
| ACRpc hpcacclient.HpcAC | |||
| THRpc hpcthclient.HpcTH | |||
| } | |||
| func NewServiceContext(c config.Config) *ServiceContext { | |||
| @@ -28,9 +28,9 @@ func NewServiceContext(c config.Config) *ServiceContext { | |||
| panic(err) | |||
| } | |||
| return &ServiceContext{ | |||
| Config: c, | |||
| DbEngin: db, | |||
| ShuguangRpc: slurmshuguangclient.NewSlurmShuguang(zrpc.MustNewClient(c.ShuguangRpcConf)), | |||
| TianheRpc: slurmtianheclient.NewSlurmTianhe(zrpc.MustNewClient(c.TianheRpcConf)), | |||
| Config: c, | |||
| DbEngin: db, | |||
| ACRpc: hpcacclient.NewHpcAC(zrpc.MustNewClient(c.ACRpcConf)), | |||
| THRpc: hpcthclient.NewHpcTH(zrpc.MustNewClient(c.THRpcConf)), | |||
| } | |||
| } | |||
| @@ -20,14 +20,14 @@ type Job struct { | |||
| DerivedEc uint32 `json:"derivedEc"` | |||
| EligibleTime int64 `json:"eligibleTime"` | |||
| EndTime int64 `json:"endTime"` | |||
| ExcNodes string `json:"excNodes"` //NodeUsed in shuguang | |||
| ExcNodes string `json:"excNodes"` //NodeUsed in ac | |||
| ExcNodeInx int32 `json:"excNodeInx"` | |||
| ExitCode uint32 `json:"exitCode"` | |||
| Features string `json:"features"` | |||
| Gres string `json:"gres"` | |||
| GroupId uint32 `json:"groupId"` | |||
| JobId uint32 `json:"jobId"` //JobId in shuguang | |||
| JobState uint32 `json:"jobState"` //JobStatus in shuguang | |||
| JobId uint32 `json:"jobId"` //JobId in ac | |||
| JobState uint32 `json:"jobState"` //JobStatus in ac | |||
| Licenses string `json:"licenses"` | |||
| MaxCpus uint32 `json:"maxCpus"` | |||
| MaxNodes uint32 `json:"maxNodes"` | |||
| @@ -36,7 +36,7 @@ type Job struct { | |||
| SocketsPerNode uint32 `json:"socketsPerNode"` | |||
| CoresPerSocket uint32 `json:"coresPerSocket"` | |||
| ThreadsPerCore uint32 `json:"threadsPerCore"` | |||
| Name string `json:"name"` //JobName in shuguang | |||
| Name string `json:"name"` //JobName in ac | |||
| Network string `json:"network"` | |||
| Nodes string `json:"nodes"` | |||
| Nice uint32 `json:"nice"` | |||
| @@ -46,8 +46,8 @@ type Job struct { | |||
| NtasksPerSocket uint32 `json:"ntasksPerSocket"` | |||
| NtasksPerBoard uint32 `json:"ntasksPerBoard"` | |||
| NumNodes uint32 `json:"numNodes"` | |||
| NumCpus uint32 `json:"numCpus"` //ProcNumUsed in shuguang | |||
| Partition string `json:"partition"` //Queue in shuguang | |||
| NumCpus uint32 `json:"numCpus"` //ProcNumUsed in ac | |||
| Partition string `json:"partition"` //Queue in ac | |||
| PnMinMemory uint32 `json:"pnMinMemory"` | |||
| PnMinCpus uint32 `json:"pnMinCpus"` | |||
| PnMinTmpDisk uint32 `json:"pnMinTmpDisk"` | |||
| @@ -64,18 +64,18 @@ type Job struct { | |||
| ResvName string `json:"resvName"` | |||
| Shared uint32 `json:"shared"` | |||
| ShowFlags uint32 `json:"showFlags"` | |||
| StartTime int64 `json:"startTime"` //JobStartTime in shuguang | |||
| StartTime int64 `json:"startTime"` //JobStartTime in ac | |||
| StateDesc string `json:"stateDesc"` | |||
| StateReason uint32 `json:"stateReason"` | |||
| SubmitTime int64 `json:"submitTime"` | |||
| SuspendTime int64 `json:"suspendTime"` | |||
| TimeLimit uint32 `json:"timeLimit"` | |||
| TimeMin uint32 `json:"timeMin"` | |||
| UserId uint32 `json:"userId"` //User in shuguang | |||
| UserId uint32 `json:"userId"` //User in ac | |||
| PreemptTime int64 `json:"preemptTime"` | |||
| Wait4Switch uint32 `json:"wait4Switch"` | |||
| Wckey string `json:"wckey"` | |||
| WorkDir string `json:"workDir"` //WorkDir in shuguang | |||
| WorkDir string `json:"workDir"` //WorkDir in ac | |||
| JobRunTime string `json:"jobRunTime"` | |||
| JobmanagerId string `json:"jobmanagerId"` | |||
| JobmanagerName string `json:"jobmanagerName"` | |||
| @@ -99,7 +99,7 @@ type ListJobResp struct { | |||
| type HistoryJob struct { | |||
| SlurmVersion string `json:"slurmVersion"` | |||
| AllocCPU uint32 `json:"allocCPU"` | |||
| AllocNodes uint32 `json:"allocNodes"` //Nodect 分配的节点数 in shuguang | |||
| AllocNodes uint32 `json:"allocNodes"` //Nodect 分配的节点数 in ac | |||
| Account string `json:"account"` | |||
| AssocId uint32 `json:"assocId"` | |||
| BlockId string `json:"blockId"` | |||
| @@ -108,14 +108,14 @@ type HistoryJob struct { | |||
| DerivedEs string `json:"derivedEs"` | |||
| Elapsed uint32 `json:"elapsed"` | |||
| Eligible int64 `json:"eligible"` | |||
| End int64 `json:"end"` //JobEndTime 作业结束时间 in shuguang | |||
| ExitCode uint32 `json:"exitCode"` //JobExitStatus 作业退出码 in shuguang | |||
| End int64 `json:"end"` //JobEndTime 作业结束时间 in ac | |||
| ExitCode uint32 `json:"exitCode"` //JobExitStatus 作业退出码 in ac | |||
| Gid uint32 `json:"gid"` | |||
| JobId uint32 `json:"jobId"` //JobId in shuguang | |||
| JobName string `json:"jobName"` //JobName in shuguang | |||
| JobId uint32 `json:"jobId"` //JobId in ac | |||
| JobName string `json:"jobName"` //JobName in ac | |||
| Lft uint32 `json:"lft"` | |||
| Partition string `json:"partition"` //Queue 队列名 in shuguang | |||
| Nodes string `json:"nodes"` //JobExecHost 作业执行节点 in shuguang | |||
| Partition string `json:"partition"` //Queue 队列名 in ac | |||
| Nodes string `json:"nodes"` //JobExecHost 作业执行节点 in ac | |||
| Priority uint32 `json:"priority"` | |||
| Qosid uint32 `json:"qosid"` | |||
| ReqCpus uint32 `json:"reqCpus"` | |||
| @@ -123,8 +123,8 @@ type HistoryJob struct { | |||
| Requid uint32 `json:"requid"` | |||
| Resvid uint32 `json:"resvid"` | |||
| ShowFull uint32 `json:"showFull"` | |||
| Start int64 `json:"start"` //JobStartTime 作业启动时间 in shuguang | |||
| State uint32 `json:"state"` //JobState 作业状态 in shuguang | |||
| Start int64 `json:"start"` //JobStartTime 作业启动时间 in ac | |||
| State uint32 `json:"state"` //JobState 作业状态 in ac | |||
| Submit int64 `json:"submit"` | |||
| Suspended uint32 `json:"suspended"` | |||
| SysCpuSec uint32 `json:"sysCpuSec"` | |||
| @@ -134,12 +134,12 @@ type HistoryJob struct { | |||
| TotCpuUsec uint32 `json:"totCpuUsec"` | |||
| TrackSteps uint32 `json:"trackSteps"` | |||
| Uid uint32 `json:"uid"` | |||
| User string `json:"user"` //UserName 用户名 in shuguang | |||
| User string `json:"user"` //UserName 用户名 in ac | |||
| UserCpuSec uint32 `json:"userCpuSec"` | |||
| UserCpuUsec uint32 `json:"userCpuUsec"` | |||
| Wckey string `json:"wckey"` | |||
| Wckeyid uint32 `json:"wckeyid"` | |||
| WorkDir string `json:"workDir"` //Workdir 工作空间 in shuguang | |||
| WorkDir string `json:"workDir"` //Workdir 工作空间 in ac | |||
| AcctTime string `json:"acctTime"` // 记账时间 | |||
| AppType string `json:"appType"` // 作业应用类型 | |||
| JobQueueTime string `json:"jobQueueTime"` //作业入队列时间 | |||
| @@ -1,3 +1,2 @@ | |||
| Name: slurmtianhe.rpc | |||
| Name: hpcth.rpc | |||
| ListenOn: 0.0.0.0:2002 | |||
| @@ -0,0 +1,183 @@ | |||
| // Code generated by protoc-gen-go-grpc. DO NOT EDIT. | |||
| // versions: | |||
| // - protoc-gen-go-grpc v1.2.0 | |||
| // - protoc v3.19.4 | |||
| // source: hpcTH.proto | |||
| package hpcTH | |||
| 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 | |||
| // HpcTHClient is the client API for HpcTH 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 HpcTHClient interface { | |||
| // ListJob list all jobs | |||
| ListJob(ctx context.Context, in *ListJobReq, opts ...grpc.CallOption) (*ListJobResp, error) | |||
| // ListHistoryJob list all history jobs | |||
| ListHistoryJob(ctx context.Context, in *ListHistoryJobReq, opts ...grpc.CallOption) (*ListHistoryJobResp, error) | |||
| // Submit job | |||
| SubmitJob(ctx context.Context, in *SubmitJobReq, opts ...grpc.CallOption) (*SubmitJobResp, error) | |||
| } | |||
| type hpcTHClient struct { | |||
| cc grpc.ClientConnInterface | |||
| } | |||
| func NewHpcTHClient(cc grpc.ClientConnInterface) HpcTHClient { | |||
| return &hpcTHClient{cc} | |||
| } | |||
| func (c *hpcTHClient) ListJob(ctx context.Context, in *ListJobReq, opts ...grpc.CallOption) (*ListJobResp, error) { | |||
| out := new(ListJobResp) | |||
| err := c.cc.Invoke(ctx, "/hpcTH.hpcTH/ListJob", in, out, opts...) | |||
| if err != nil { | |||
| return nil, err | |||
| } | |||
| return out, nil | |||
| } | |||
| func (c *hpcTHClient) ListHistoryJob(ctx context.Context, in *ListHistoryJobReq, opts ...grpc.CallOption) (*ListHistoryJobResp, error) { | |||
| out := new(ListHistoryJobResp) | |||
| err := c.cc.Invoke(ctx, "/hpcTH.hpcTH/ListHistoryJob", in, out, opts...) | |||
| if err != nil { | |||
| return nil, err | |||
| } | |||
| return out, nil | |||
| } | |||
| func (c *hpcTHClient) SubmitJob(ctx context.Context, in *SubmitJobReq, opts ...grpc.CallOption) (*SubmitJobResp, error) { | |||
| out := new(SubmitJobResp) | |||
| err := c.cc.Invoke(ctx, "/hpcTH.hpcTH/SubmitJob", in, out, opts...) | |||
| if err != nil { | |||
| return nil, err | |||
| } | |||
| return out, nil | |||
| } | |||
| // HpcTHServer is the server API for HpcTH service. | |||
| // All implementations must embed UnimplementedHpcTHServer | |||
| // for forward compatibility | |||
| type HpcTHServer interface { | |||
| // ListJob list all jobs | |||
| ListJob(context.Context, *ListJobReq) (*ListJobResp, error) | |||
| // ListHistoryJob list all history jobs | |||
| ListHistoryJob(context.Context, *ListHistoryJobReq) (*ListHistoryJobResp, error) | |||
| // Submit job | |||
| SubmitJob(context.Context, *SubmitJobReq) (*SubmitJobResp, error) | |||
| mustEmbedUnimplementedHpcTHServer() | |||
| } | |||
| // UnimplementedHpcTHServer must be embedded to have forward compatible implementations. | |||
| type UnimplementedHpcTHServer struct { | |||
| } | |||
| func (UnimplementedHpcTHServer) ListJob(context.Context, *ListJobReq) (*ListJobResp, error) { | |||
| return nil, status.Errorf(codes.Unimplemented, "method ListJob not implemented") | |||
| } | |||
| func (UnimplementedHpcTHServer) ListHistoryJob(context.Context, *ListHistoryJobReq) (*ListHistoryJobResp, error) { | |||
| return nil, status.Errorf(codes.Unimplemented, "method ListHistoryJob not implemented") | |||
| } | |||
| func (UnimplementedHpcTHServer) SubmitJob(context.Context, *SubmitJobReq) (*SubmitJobResp, error) { | |||
| return nil, status.Errorf(codes.Unimplemented, "method SubmitJob not implemented") | |||
| } | |||
| func (UnimplementedHpcTHServer) mustEmbedUnimplementedHpcTHServer() {} | |||
| // UnsafeHpcTHServer may be embedded to opt out of forward compatibility for this service. | |||
| // Use of this interface is not recommended, as added methods to HpcTHServer will | |||
| // result in compilation errors. | |||
| type UnsafeHpcTHServer interface { | |||
| mustEmbedUnimplementedHpcTHServer() | |||
| } | |||
| func RegisterHpcTHServer(s grpc.ServiceRegistrar, srv HpcTHServer) { | |||
| s.RegisterService(&HpcTH_ServiceDesc, srv) | |||
| } | |||
| func _HpcTH_ListJob_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { | |||
| in := new(ListJobReq) | |||
| if err := dec(in); err != nil { | |||
| return nil, err | |||
| } | |||
| if interceptor == nil { | |||
| return srv.(HpcTHServer).ListJob(ctx, in) | |||
| } | |||
| info := &grpc.UnaryServerInfo{ | |||
| Server: srv, | |||
| FullMethod: "/hpcTH.hpcTH/ListJob", | |||
| } | |||
| handler := func(ctx context.Context, req interface{}) (interface{}, error) { | |||
| return srv.(HpcTHServer).ListJob(ctx, req.(*ListJobReq)) | |||
| } | |||
| return interceptor(ctx, in, info, handler) | |||
| } | |||
| func _HpcTH_ListHistoryJob_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { | |||
| in := new(ListHistoryJobReq) | |||
| if err := dec(in); err != nil { | |||
| return nil, err | |||
| } | |||
| if interceptor == nil { | |||
| return srv.(HpcTHServer).ListHistoryJob(ctx, in) | |||
| } | |||
| info := &grpc.UnaryServerInfo{ | |||
| Server: srv, | |||
| FullMethod: "/hpcTH.hpcTH/ListHistoryJob", | |||
| } | |||
| handler := func(ctx context.Context, req interface{}) (interface{}, error) { | |||
| return srv.(HpcTHServer).ListHistoryJob(ctx, req.(*ListHistoryJobReq)) | |||
| } | |||
| return interceptor(ctx, in, info, handler) | |||
| } | |||
| func _HpcTH_SubmitJob_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { | |||
| in := new(SubmitJobReq) | |||
| if err := dec(in); err != nil { | |||
| return nil, err | |||
| } | |||
| if interceptor == nil { | |||
| return srv.(HpcTHServer).SubmitJob(ctx, in) | |||
| } | |||
| info := &grpc.UnaryServerInfo{ | |||
| Server: srv, | |||
| FullMethod: "/hpcTH.hpcTH/SubmitJob", | |||
| } | |||
| handler := func(ctx context.Context, req interface{}) (interface{}, error) { | |||
| return srv.(HpcTHServer).SubmitJob(ctx, req.(*SubmitJobReq)) | |||
| } | |||
| return interceptor(ctx, in, info, handler) | |||
| } | |||
| // HpcTH_ServiceDesc is the grpc.ServiceDesc for HpcTH service. | |||
| // It's only intended for direct use with grpc.RegisterService, | |||
| // and not to be introspected or modified (even as a copy) | |||
| var HpcTH_ServiceDesc = grpc.ServiceDesc{ | |||
| ServiceName: "hpcTH.hpcTH", | |||
| HandlerType: (*HpcTHServer)(nil), | |||
| Methods: []grpc.MethodDesc{ | |||
| { | |||
| MethodName: "ListJob", | |||
| Handler: _HpcTH_ListJob_Handler, | |||
| }, | |||
| { | |||
| MethodName: "ListHistoryJob", | |||
| Handler: _HpcTH_ListHistoryJob_Handler, | |||
| }, | |||
| { | |||
| MethodName: "SubmitJob", | |||
| Handler: _HpcTH_SubmitJob_Handler, | |||
| }, | |||
| }, | |||
| Streams: []grpc.StreamDesc{}, | |||
| Metadata: "hpcTH.proto", | |||
| } | |||
| @@ -1,12 +1,13 @@ | |||
| package main | |||
| import ( | |||
| "flag" | |||
| "fmt" | |||
| "PCM/adaptor/PCM-HPC/PCM-TH/rpc/hpcTH" | |||
| "PCM/adaptor/PCM-HPC/PCM-TH/rpc/internal/config" | |||
| "PCM/adaptor/PCM-HPC/PCM-TH/rpc/internal/server" | |||
| "PCM/adaptor/PCM-HPC/PCM-TH/rpc/internal/svc" | |||
| "PCM/adaptor/PCM-HPC/PCM-TH/rpc/slurmTianhe" | |||
| "flag" | |||
| "fmt" | |||
| "github.com/zeromicro/go-zero/core/conf" | |||
| "github.com/zeromicro/go-zero/core/service" | |||
| @@ -15,7 +16,7 @@ import ( | |||
| "google.golang.org/grpc/reflection" | |||
| ) | |||
| var configFile = flag.String("f", "adaptor/PCM-HPC/PCM-TH/rpc/etc/slurmtianhe.yaml", "the config file") | |||
| var configFile = flag.String("f", "adaptor/PCM-HPC/PCM-TH/rpc/etc/hpcth.yaml", "the config file") | |||
| func main() { | |||
| flag.Parse() | |||
| @@ -25,7 +26,7 @@ func main() { | |||
| ctx := svc.NewServiceContext(c) | |||
| s := zrpc.MustNewServer(c.RpcServerConf, func(grpcServer *grpc.Server) { | |||
| slurmTianhe.RegisterSlurmTianheServer(grpcServer, server.NewSlurmTianheServer(ctx)) | |||
| hpcTH.RegisterHpcTHServer(grpcServer, server.NewHpcTHServer(ctx)) | |||
| if c.Mode == service.DevMode || c.Mode == service.TestMode { | |||
| reflection.Register(grpcServer) | |||
| @@ -0,0 +1,64 @@ | |||
| // Code generated by goctl. DO NOT EDIT. | |||
| // Source: hpcTH.proto | |||
| package hpcthclient | |||
| import ( | |||
| "context" | |||
| "PCM/adaptor/PCM-HPC/PCM-TH/rpc/hpcTH" | |||
| "github.com/zeromicro/go-zero/zrpc" | |||
| "google.golang.org/grpc" | |||
| ) | |||
| type ( | |||
| Argv = hpcTH.Argv | |||
| Environment = hpcTH.Environment | |||
| HistoryJob = hpcTH.HistoryJob | |||
| Job = hpcTH.Job | |||
| ListHistoryJobReq = hpcTH.ListHistoryJobReq | |||
| ListHistoryJobResp = hpcTH.ListHistoryJobResp | |||
| ListJobReq = hpcTH.ListJobReq | |||
| ListJobResp = hpcTH.ListJobResp | |||
| SubmitJobReq = hpcTH.SubmitJobReq | |||
| SubmitJobResp = hpcTH.SubmitJobResp | |||
| SubmitResponseMsg = hpcTH.SubmitResponseMsg | |||
| HpcTH interface { | |||
| // ListJob list all jobs | |||
| ListJob(ctx context.Context, in *ListJobReq, opts ...grpc.CallOption) (*ListJobResp, error) | |||
| // ListHistoryJob list all history jobs | |||
| ListHistoryJob(ctx context.Context, in *ListHistoryJobReq, opts ...grpc.CallOption) (*ListHistoryJobResp, error) | |||
| // Submit job | |||
| SubmitJob(ctx context.Context, in *SubmitJobReq, opts ...grpc.CallOption) (*SubmitJobResp, error) | |||
| } | |||
| defaultHpcTH struct { | |||
| cli zrpc.Client | |||
| } | |||
| ) | |||
| func NewHpcTH(cli zrpc.Client) HpcTH { | |||
| return &defaultHpcTH{ | |||
| cli: cli, | |||
| } | |||
| } | |||
| // ListJob list all jobs | |||
| func (m *defaultHpcTH) ListJob(ctx context.Context, in *ListJobReq, opts ...grpc.CallOption) (*ListJobResp, error) { | |||
| client := hpcTH.NewHpcTHClient(m.cli.Conn()) | |||
| return client.ListJob(ctx, in, opts...) | |||
| } | |||
| // ListHistoryJob list all history jobs | |||
| func (m *defaultHpcTH) ListHistoryJob(ctx context.Context, in *ListHistoryJobReq, opts ...grpc.CallOption) (*ListHistoryJobResp, error) { | |||
| client := hpcTH.NewHpcTHClient(m.cli.Conn()) | |||
| return client.ListHistoryJob(ctx, in, opts...) | |||
| } | |||
| // Submit job | |||
| func (m *defaultHpcTH) SubmitJob(ctx context.Context, in *SubmitJobReq, opts ...grpc.CallOption) (*SubmitJobResp, error) { | |||
| client := hpcTH.NewHpcTHClient(m.cli.Conn()) | |||
| return client.SubmitJob(ctx, in, opts...) | |||
| } | |||
| @@ -68,8 +68,8 @@ int getLength(slurmdb_job_rec_t *job_rec_array) { | |||
| import "C" | |||
| import ( | |||
| "PCM/adaptor/PCM-HPC/PCM-TH/rpc/hpcTH" | |||
| "PCM/adaptor/PCM-HPC/PCM-TH/rpc/internal/svc" | |||
| "PCM/adaptor/PCM-HPC/PCM-TH/rpc/slurmTianhe" | |||
| "context" | |||
| "github.com/zeromicro/go-zero/core/logx" | |||
| @@ -90,9 +90,9 @@ func NewListHistoryJobLogic(ctx context.Context, svcCtx *svc.ServiceContext) *Li | |||
| } | |||
| // ListHistoryJob list all jobs from slurmdb | |||
| func (l *ListHistoryJobLogic) ListHistoryJob(in *slurmTianhe.ListHistoryJobReq) (*slurmTianhe.ListHistoryJobResp, error) { | |||
| func (l *ListHistoryJobLogic) ListHistoryJob(in *hpcTH.ListHistoryJobReq) (*hpcTH.ListHistoryJobResp, error) { | |||
| var dbJobResp slurmTianhe.ListHistoryJobResp | |||
| var dbJobResp hpcTH.ListHistoryJobResp | |||
| jobInfos := C.get_all_slurmdb_job() | |||
| size := uint32(C.getLength(jobInfos)) | |||
| dbJobResp.RecordCount = size | |||
| @@ -107,8 +107,8 @@ func (l *ListHistoryJobLogic) ListHistoryJob(in *slurmTianhe.ListHistoryJobReq) | |||
| return &dbJobResp, nil | |||
| } | |||
| func SlurmdbJobConvertCToGo(cStructJob *C.slurmdb_job_rec_t) slurmTianhe.HistoryJob { | |||
| var goStruct slurmTianhe.HistoryJob | |||
| func SlurmdbJobConvertCToGo(cStructJob *C.slurmdb_job_rec_t) hpcTH.HistoryJob { | |||
| var goStruct hpcTH.HistoryJob | |||
| goStruct.Account = C.GoString(cStructJob.account) | |||
| goStruct.Associd = uint32(cStructJob.associd) | |||
| @@ -75,14 +75,14 @@ struct job_info_msg *get_single_job_info(uint32_t id){ | |||
| */ | |||
| import "C" | |||
| import ( | |||
| "PCM/adaptor/PCM-HPC/PCM-TH/rpc/hpcTH" | |||
| "PCM/adaptor/PCM-HPC/PCM-TH/rpc/internal/svc" | |||
| "PCM/adaptor/PCM-HPC/PCM-TH/rpc/slurmTianhe" | |||
| "context" | |||
| "github.com/zeromicro/go-zero/core/logx" | |||
| ) | |||
| func JobCtoGo(cStruct *C.struct_job_info) slurmTianhe.Job { | |||
| var goStruct slurmTianhe.Job | |||
| func JobCtoGo(cStruct *C.struct_job_info) hpcTH.Job { | |||
| var goStruct hpcTH.Job | |||
| goStruct.Account = C.GoString(cStruct.account) | |||
| goStruct.AllocNode = C.GoString(cStruct.alloc_node) | |||
| @@ -176,9 +176,9 @@ func NewListJobLogic(ctx context.Context, svcCtx *svc.ServiceContext) *ListJobLo | |||
| } | |||
| // ListJob list all jobs | |||
| func (l *ListJobLogic) ListJob(in *slurmTianhe.ListJobReq) (*slurmTianhe.ListJobResp, error) { | |||
| func (l *ListJobLogic) ListJob(in *hpcTH.ListJobReq) (*hpcTH.ListJobResp, error) { | |||
| var jobResp slurmTianhe.ListJobResp | |||
| var jobResp hpcTH.ListJobResp | |||
| cJobBuffer := C.get_job_info() | |||
| if cJobBuffer == nil { | |||
| jobResp.RecordCount = uint32(0) | |||
| @@ -32,8 +32,8 @@ int update_job (struct job_descriptor *msg) { | |||
| import "C" | |||
| import ( | |||
| "PCM/adaptor/PCM-HPC/PCM-TH/rpc/hpcTH" | |||
| "PCM/adaptor/PCM-HPC/PCM-TH/rpc/internal/svc" | |||
| "PCM/adaptor/PCM-HPC/PCM-TH/rpc/slurmTianhe" | |||
| "context" | |||
| "fmt" | |||
| "unsafe" | |||
| @@ -56,7 +56,7 @@ func NewSubmitJobLogic(ctx context.Context, svcCtx *svc.ServiceContext) *SubmitJ | |||
| } | |||
| // Submit job | |||
| func (l *SubmitJobLogic) SubmitJob(in *slurmTianhe.SubmitJobReq) (*slurmTianhe.SubmitJobResp, error) { | |||
| func (l *SubmitJobLogic) SubmitJob(in *hpcTH.SubmitJobReq) (*hpcTH.SubmitJobResp, error) { | |||
| var cStruct C.struct_job_descriptor | |||
| C.slurm_init_job_desc_msg(&cStruct) | |||
| @@ -380,7 +380,7 @@ func (l *SubmitJobLogic) SubmitJob(in *slurmTianhe.SubmitJobReq) (*slurmTianhe.S | |||
| defer C.free_submit_response_msg(cMsg) | |||
| if cMsg == nil { | |||
| goMsg := slurmTianhe.SubmitJobResp{} | |||
| goMsg := hpcTH.SubmitJobResp{} | |||
| goMsg.SubmitResponseMsg[0].JobId = 1<<31 - 1 | |||
| goMsg.SubmitResponseMsg[0].ErrorCode = uint32(C.slurm_get_errno()) | |||
| return &goMsg, nil | |||
| @@ -390,8 +390,8 @@ func (l *SubmitJobLogic) SubmitJob(in *slurmTianhe.SubmitJobReq) (*slurmTianhe.S | |||
| return &goMsg, nil | |||
| } | |||
| func submitResponseMsgConvertCToGo(cStruct *C.struct_submit_response_msg) slurmTianhe.SubmitJobResp { | |||
| var goStruct slurmTianhe.SubmitJobResp | |||
| func submitResponseMsgConvertCToGo(cStruct *C.struct_submit_response_msg) hpcTH.SubmitJobResp { | |||
| var goStruct hpcTH.SubmitJobResp | |||
| goStruct.SubmitResponseMsg[0].JobId = uint32(cStruct.job_id) | |||
| goStruct.SubmitResponseMsg[0].StepId = uint32(cStruct.step_id) | |||
| @@ -0,0 +1,41 @@ | |||
| // Code generated by goctl. DO NOT EDIT. | |||
| // Source: hpcTH.proto | |||
| package server | |||
| import ( | |||
| "context" | |||
| "PCM/adaptor/PCM-HPC/PCM-TH/rpc/hpcTH" | |||
| "PCM/adaptor/PCM-HPC/PCM-TH/rpc/internal/logic" | |||
| "PCM/adaptor/PCM-HPC/PCM-TH/rpc/internal/svc" | |||
| ) | |||
| type HpcTHServer struct { | |||
| svcCtx *svc.ServiceContext | |||
| hpcTH.UnimplementedHpcTHServer | |||
| } | |||
| func NewHpcTHServer(svcCtx *svc.ServiceContext) *HpcTHServer { | |||
| return &HpcTHServer{ | |||
| svcCtx: svcCtx, | |||
| } | |||
| } | |||
| // ListJob list all jobs | |||
| func (s *HpcTHServer) ListJob(ctx context.Context, in *hpcTH.ListJobReq) (*hpcTH.ListJobResp, error) { | |||
| l := logic.NewListJobLogic(ctx, s.svcCtx) | |||
| return l.ListJob(in) | |||
| } | |||
| // ListHistoryJob list all history jobs | |||
| func (s *HpcTHServer) ListHistoryJob(ctx context.Context, in *hpcTH.ListHistoryJobReq) (*hpcTH.ListHistoryJobResp, error) { | |||
| l := logic.NewListHistoryJobLogic(ctx, s.svcCtx) | |||
| return l.ListHistoryJob(in) | |||
| } | |||
| // Submit job | |||
| func (s *HpcTHServer) SubmitJob(ctx context.Context, in *hpcTH.SubmitJobReq) (*hpcTH.SubmitJobResp, error) { | |||
| l := logic.NewSubmitJobLogic(ctx, s.svcCtx) | |||
| return l.SubmitJob(in) | |||
| } | |||
| @@ -1,40 +0,0 @@ | |||
| // Code generated by goctl. DO NOT EDIT. | |||
| // Source: slurmTianhe.proto | |||
| package server | |||
| import ( | |||
| logic2 "PCM/adaptor/PCM-HPC/PCM-TH/rpc/internal/logic" | |||
| "PCM/adaptor/PCM-HPC/PCM-TH/rpc/internal/svc" | |||
| slurmTianhe2 "PCM/adaptor/PCM-HPC/PCM-TH/rpc/slurmTianhe" | |||
| "context" | |||
| ) | |||
| type SlurmTianheServer struct { | |||
| svcCtx *svc.ServiceContext | |||
| slurmTianhe2.UnimplementedSlurmTianheServer | |||
| } | |||
| func NewSlurmTianheServer(svcCtx *svc.ServiceContext) *SlurmTianheServer { | |||
| return &SlurmTianheServer{ | |||
| svcCtx: svcCtx, | |||
| } | |||
| } | |||
| // ListJob list all jobs | |||
| func (s *SlurmTianheServer) ListJob(ctx context.Context, in *slurmTianhe2.ListJobReq) (*slurmTianhe2.ListJobResp, error) { | |||
| l := logic2.NewListJobLogic(ctx, s.svcCtx) | |||
| return l.ListJob(in) | |||
| } | |||
| // ListHistoryJob list all history jobs | |||
| func (s *SlurmTianheServer) ListHistoryJob(ctx context.Context, in *slurmTianhe2.ListHistoryJobReq) (*slurmTianhe2.ListHistoryJobResp, error) { | |||
| l := logic2.NewListHistoryJobLogic(ctx, s.svcCtx) | |||
| return l.ListHistoryJob(in) | |||
| } | |||
| // Submit job | |||
| func (s *SlurmTianheServer) SubmitJob(ctx context.Context, in *slurmTianhe2.SubmitJobReq) (*slurmTianhe2.SubmitJobResp, error) { | |||
| l := logic2.NewSubmitJobLogic(ctx, s.svcCtx) | |||
| return l.SubmitJob(in) | |||
| } | |||
| @@ -1,7 +1,7 @@ | |||
| syntax = "proto3"; | |||
| package slurmTianhe; | |||
| option go_package = "/slurmTianhe"; | |||
| package hpcTH; | |||
| option go_package = "/hpcTH"; | |||
| /******************Job Start*************************/ | |||
| message job{ | |||
| @@ -271,8 +271,8 @@ message Environment{ | |||
| /******************Job(Submit) End*************************/ | |||
| // Slurm Services for Tianhe Branch | |||
| service slurmTianhe { | |||
| // hpc Services for Tianhe | |||
| service hpcTH { | |||
| //ListJob list all jobs | |||
| rpc ListJob(ListJobReq) returns (ListJobResp); | |||
| @@ -1,183 +0,0 @@ | |||
| // Code generated by protoc-gen-go-grpc. DO NOT EDIT. | |||
| // versions: | |||
| // - protoc-gen-go-grpc v1.2.0 | |||
| // - protoc v3.19.4 | |||
| // source: slurmTianhe.proto | |||
| package slurmTianhe | |||
| 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 | |||
| // SlurmTianheClient is the client API for SlurmTianhe 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 SlurmTianheClient interface { | |||
| // ListJob list all jobs | |||
| ListJob(ctx context.Context, in *ListJobReq, opts ...grpc.CallOption) (*ListJobResp, error) | |||
| // ListHistoryJob list all history jobs | |||
| ListHistoryJob(ctx context.Context, in *ListHistoryJobReq, opts ...grpc.CallOption) (*ListHistoryJobResp, error) | |||
| // Submit job | |||
| SubmitJob(ctx context.Context, in *SubmitJobReq, opts ...grpc.CallOption) (*SubmitJobResp, error) | |||
| } | |||
| type slurmTianheClient struct { | |||
| cc grpc.ClientConnInterface | |||
| } | |||
| func NewSlurmTianheClient(cc grpc.ClientConnInterface) SlurmTianheClient { | |||
| return &slurmTianheClient{cc} | |||
| } | |||
| func (c *slurmTianheClient) ListJob(ctx context.Context, in *ListJobReq, opts ...grpc.CallOption) (*ListJobResp, error) { | |||
| out := new(ListJobResp) | |||
| err := c.cc.Invoke(ctx, "/slurmTianhe.slurmTianhe/ListJob", in, out, opts...) | |||
| if err != nil { | |||
| return nil, err | |||
| } | |||
| return out, nil | |||
| } | |||
| func (c *slurmTianheClient) ListHistoryJob(ctx context.Context, in *ListHistoryJobReq, opts ...grpc.CallOption) (*ListHistoryJobResp, error) { | |||
| out := new(ListHistoryJobResp) | |||
| err := c.cc.Invoke(ctx, "/slurmTianhe.slurmTianhe/ListHistoryJob", in, out, opts...) | |||
| if err != nil { | |||
| return nil, err | |||
| } | |||
| return out, nil | |||
| } | |||
| func (c *slurmTianheClient) SubmitJob(ctx context.Context, in *SubmitJobReq, opts ...grpc.CallOption) (*SubmitJobResp, error) { | |||
| out := new(SubmitJobResp) | |||
| err := c.cc.Invoke(ctx, "/slurmTianhe.slurmTianhe/SubmitJob", in, out, opts...) | |||
| if err != nil { | |||
| return nil, err | |||
| } | |||
| return out, nil | |||
| } | |||
| // SlurmTianheServer is the server API for SlurmTianhe service. | |||
| // All implementations must embed UnimplementedSlurmTianheServer | |||
| // for forward compatibility | |||
| type SlurmTianheServer interface { | |||
| // ListJob list all jobs | |||
| ListJob(context.Context, *ListJobReq) (*ListJobResp, error) | |||
| // ListHistoryJob list all history jobs | |||
| ListHistoryJob(context.Context, *ListHistoryJobReq) (*ListHistoryJobResp, error) | |||
| // Submit job | |||
| SubmitJob(context.Context, *SubmitJobReq) (*SubmitJobResp, error) | |||
| mustEmbedUnimplementedSlurmTianheServer() | |||
| } | |||
| // UnimplementedSlurmTianheServer must be embedded to have forward compatible implementations. | |||
| type UnimplementedSlurmTianheServer struct { | |||
| } | |||
| func (UnimplementedSlurmTianheServer) ListJob(context.Context, *ListJobReq) (*ListJobResp, error) { | |||
| return nil, status.Errorf(codes.Unimplemented, "method ListJob not implemented") | |||
| } | |||
| func (UnimplementedSlurmTianheServer) ListHistoryJob(context.Context, *ListHistoryJobReq) (*ListHistoryJobResp, error) { | |||
| return nil, status.Errorf(codes.Unimplemented, "method ListHistoryJob not implemented") | |||
| } | |||
| func (UnimplementedSlurmTianheServer) SubmitJob(context.Context, *SubmitJobReq) (*SubmitJobResp, error) { | |||
| return nil, status.Errorf(codes.Unimplemented, "method SubmitJob not implemented") | |||
| } | |||
| func (UnimplementedSlurmTianheServer) mustEmbedUnimplementedSlurmTianheServer() {} | |||
| // UnsafeSlurmTianheServer may be embedded to opt out of forward compatibility for this service. | |||
| // Use of this interface is not recommended, as added methods to SlurmTianheServer will | |||
| // result in compilation errors. | |||
| type UnsafeSlurmTianheServer interface { | |||
| mustEmbedUnimplementedSlurmTianheServer() | |||
| } | |||
| func RegisterSlurmTianheServer(s grpc.ServiceRegistrar, srv SlurmTianheServer) { | |||
| s.RegisterService(&SlurmTianhe_ServiceDesc, srv) | |||
| } | |||
| func _SlurmTianhe_ListJob_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { | |||
| in := new(ListJobReq) | |||
| if err := dec(in); err != nil { | |||
| return nil, err | |||
| } | |||
| if interceptor == nil { | |||
| return srv.(SlurmTianheServer).ListJob(ctx, in) | |||
| } | |||
| info := &grpc.UnaryServerInfo{ | |||
| Server: srv, | |||
| FullMethod: "/slurmTianhe.slurmTianhe/ListJob", | |||
| } | |||
| handler := func(ctx context.Context, req interface{}) (interface{}, error) { | |||
| return srv.(SlurmTianheServer).ListJob(ctx, req.(*ListJobReq)) | |||
| } | |||
| return interceptor(ctx, in, info, handler) | |||
| } | |||
| func _SlurmTianhe_ListHistoryJob_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { | |||
| in := new(ListHistoryJobReq) | |||
| if err := dec(in); err != nil { | |||
| return nil, err | |||
| } | |||
| if interceptor == nil { | |||
| return srv.(SlurmTianheServer).ListHistoryJob(ctx, in) | |||
| } | |||
| info := &grpc.UnaryServerInfo{ | |||
| Server: srv, | |||
| FullMethod: "/slurmTianhe.slurmTianhe/ListHistoryJob", | |||
| } | |||
| handler := func(ctx context.Context, req interface{}) (interface{}, error) { | |||
| return srv.(SlurmTianheServer).ListHistoryJob(ctx, req.(*ListHistoryJobReq)) | |||
| } | |||
| return interceptor(ctx, in, info, handler) | |||
| } | |||
| func _SlurmTianhe_SubmitJob_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { | |||
| in := new(SubmitJobReq) | |||
| if err := dec(in); err != nil { | |||
| return nil, err | |||
| } | |||
| if interceptor == nil { | |||
| return srv.(SlurmTianheServer).SubmitJob(ctx, in) | |||
| } | |||
| info := &grpc.UnaryServerInfo{ | |||
| Server: srv, | |||
| FullMethod: "/slurmTianhe.slurmTianhe/SubmitJob", | |||
| } | |||
| handler := func(ctx context.Context, req interface{}) (interface{}, error) { | |||
| return srv.(SlurmTianheServer).SubmitJob(ctx, req.(*SubmitJobReq)) | |||
| } | |||
| return interceptor(ctx, in, info, handler) | |||
| } | |||
| // SlurmTianhe_ServiceDesc is the grpc.ServiceDesc for SlurmTianhe service. | |||
| // It's only intended for direct use with grpc.RegisterService, | |||
| // and not to be introspected or modified (even as a copy) | |||
| var SlurmTianhe_ServiceDesc = grpc.ServiceDesc{ | |||
| ServiceName: "slurmTianhe.slurmTianhe", | |||
| HandlerType: (*SlurmTianheServer)(nil), | |||
| Methods: []grpc.MethodDesc{ | |||
| { | |||
| MethodName: "ListJob", | |||
| Handler: _SlurmTianhe_ListJob_Handler, | |||
| }, | |||
| { | |||
| MethodName: "ListHistoryJob", | |||
| Handler: _SlurmTianhe_ListHistoryJob_Handler, | |||
| }, | |||
| { | |||
| MethodName: "SubmitJob", | |||
| Handler: _SlurmTianhe_SubmitJob_Handler, | |||
| }, | |||
| }, | |||
| Streams: []grpc.StreamDesc{}, | |||
| Metadata: "slurmTianhe.proto", | |||
| } | |||
| @@ -1,63 +0,0 @@ | |||
| // Code generated by goctl. DO NOT EDIT. | |||
| // Source: slurmTianhe.proto | |||
| package slurmtianheclient | |||
| import ( | |||
| slurmTianhe2 "PCM/adaptor/PCM-HPC/PCM-TH/rpc/slurmTianhe" | |||
| "context" | |||
| "github.com/zeromicro/go-zero/zrpc" | |||
| "google.golang.org/grpc" | |||
| ) | |||
| type ( | |||
| Argv = slurmTianhe2.Argv | |||
| Environment = slurmTianhe2.Environment | |||
| HistoryJob = slurmTianhe2.HistoryJob | |||
| Job = slurmTianhe2.Job | |||
| ListHistoryJobReq = slurmTianhe2.ListHistoryJobReq | |||
| ListHistoryJobResp = slurmTianhe2.ListHistoryJobResp | |||
| ListJobReq = slurmTianhe2.ListJobReq | |||
| ListJobResp = slurmTianhe2.ListJobResp | |||
| SubmitJobReq = slurmTianhe2.SubmitJobReq | |||
| SubmitJobResp = slurmTianhe2.SubmitJobResp | |||
| SubmitResponseMsg = slurmTianhe2.SubmitResponseMsg | |||
| SlurmTianhe interface { | |||
| // ListJob list all jobs | |||
| ListJob(ctx context.Context, in *ListJobReq, opts ...grpc.CallOption) (*ListJobResp, error) | |||
| // ListHistoryJob list all history jobs | |||
| ListHistoryJob(ctx context.Context, in *ListHistoryJobReq, opts ...grpc.CallOption) (*ListHistoryJobResp, error) | |||
| // Submit job | |||
| SubmitJob(ctx context.Context, in *SubmitJobReq, opts ...grpc.CallOption) (*SubmitJobResp, error) | |||
| } | |||
| defaultSlurmTianhe struct { | |||
| cli zrpc.Client | |||
| } | |||
| ) | |||
| func NewSlurmTianhe(cli zrpc.Client) SlurmTianhe { | |||
| return &defaultSlurmTianhe{ | |||
| cli: cli, | |||
| } | |||
| } | |||
| // ListJob list all jobs | |||
| func (m *defaultSlurmTianhe) ListJob(ctx context.Context, in *ListJobReq, opts ...grpc.CallOption) (*ListJobResp, error) { | |||
| client := slurmTianhe2.NewSlurmTianheClient(m.cli.Conn()) | |||
| return client.ListJob(ctx, in, opts...) | |||
| } | |||
| // ListHistoryJob list all history jobs | |||
| func (m *defaultSlurmTianhe) ListHistoryJob(ctx context.Context, in *ListHistoryJobReq, opts ...grpc.CallOption) (*ListHistoryJobResp, error) { | |||
| client := slurmTianhe2.NewSlurmTianheClient(m.cli.Conn()) | |||
| return client.ListHistoryJob(ctx, in, opts...) | |||
| } | |||
| // Submit job | |||
| func (m *defaultSlurmTianhe) SubmitJob(ctx context.Context, in *SubmitJobReq, opts ...grpc.CallOption) (*SubmitJobResp, error) { | |||
| client := slurmTianhe2.NewSlurmTianheClient(m.cli.Conn()) | |||
| return client.SubmitJob(ctx, in, opts...) | |||
| } | |||