Browse Source

rpc client初始化

Former-commit-id: 6bf0776d9e
pull/9/head
zhangwei 2 years ago
parent
commit
14014ee229
3 changed files with 8 additions and 9 deletions
  1. +1
    -1
      api/internal/logic/core/scheduletaskbyyamllogic.go
  2. +6
    -0
      pkg/constants/participant.go
  3. +1
    -8
      pkg/constants/task.go

+ 1
- 1
api/internal/logic/core/scheduletaskbyyamllogic.go View File

@@ -35,7 +35,7 @@ func (l *ScheduleTaskByYamlLogic) ScheduleTaskByYaml(req *types.ScheduleTaskByYa
}
// 构建主任务结构体
taskModel := models.Task{
Status: constants.TASK_STATUS_SAVED,
Status: constants.Saved,
Description: req.Description,
Name: req.Name,
YamlString: string(bytes),


+ 6
- 0
pkg/constants/participant.go View File

@@ -0,0 +1,6 @@
package constants

const (
Kubernetes = "Kubernetes"
Slurm = "Slurm"
)

+ 1
- 8
pkg/constants/task.go View File

@@ -2,12 +2,5 @@ package constants

// 任务类型
const (
TASK_TYPE_CLOUD = 1
TASK_TYPE_HPC = 2
TASK_TYPE_AI = 3
)

const (
Kubernetes = "Kubernetes"
Slurm = "Slurm"
Saved = "Saved"
)

Loading…
Cancel
Save