查询p端列表信息
Former-commit-id: 4da76886f5de6c1939d5d9011acc37fc237d4043
This commit is contained in:
parent
7313ee2446
commit
ae939a78a0
|
@ -484,3 +484,15 @@ type HashCat {
|
|||
CrackProgress string `json:"crackProgress"` // 进度
|
||||
CrackResult string `json:"crackResult"` // 结果
|
||||
}
|
||||
|
||||
type participantListResp {
|
||||
Participants []Participant `json:"participants"`
|
||||
}
|
||||
type Participant {
|
||||
id int64 `json:"id"`
|
||||
name string `json:"name"`
|
||||
address string `json:"address"`
|
||||
metricsUrl string `json:"metricsUrl"`
|
||||
tenantName string `json:"tenantName"`
|
||||
typeName string `json:"typeName"`
|
||||
}
|
|
@ -23,6 +23,10 @@ info(
|
|||
group : core
|
||||
)
|
||||
service pcm {
|
||||
|
||||
@handler participantListHandler
|
||||
get /core/participantList () returns (participantListResp)
|
||||
|
||||
@handler scheduleTaskByYamlHandler
|
||||
post /core/scheduleTaskByYaml (scheduleTaskByYamlReq) returns ()
|
||||
|
||||
|
|
|
@ -19,6 +19,11 @@ import (
|
|||
func RegisterHandlers(server *rest.Server, serverCtx *svc.ServiceContext) {
|
||||
server.AddRoutes(
|
||||
[]rest.Route{
|
||||
{
|
||||
Method: http.MethodGet,
|
||||
Path: "/core/participantList",
|
||||
Handler: core.ParticipantListHandler(serverCtx),
|
||||
},
|
||||
{
|
||||
Method: http.MethodPost,
|
||||
Path: "/core/scheduleTaskByYaml",
|
||||
|
|
|
@ -454,6 +454,19 @@ type HashCat struct {
|
|||
CrackResult string `json:"crackResult"` // 结果
|
||||
}
|
||||
|
||||
type ParticipantListResp struct {
|
||||
Participants []Participant `json:"participants"`
|
||||
}
|
||||
|
||||
type Participant struct {
|
||||
Id int64 `json:"id"`
|
||||
Name string `json:"name"`
|
||||
Address string `json:"address"`
|
||||
MetricsUrl string `json:"metricsUrl"`
|
||||
TenantName string `json:"tenantName"`
|
||||
TypeName string `json:"typeName"`
|
||||
}
|
||||
|
||||
type Job struct {
|
||||
SlurmVersion string `json:"slurmVersion"`
|
||||
Name string `json:"name"`
|
||||
|
|
Loading…
Reference in New Issue