Documentation
¶
Index ¶
Constants ¶
View Source
const ( ActionRun = baseApi + "/run" // 启动任务 ActionKill = baseApi + "/kill" // 终止任务 ActionLog = baseApi + "/log" // 任务日志 ActionBeat = baseApi + "/heartbeat" // 心跳检测 ActionIdleBeat = baseApi + "/busy" // 忙碌检测 )
View Source
const ( Success = 200 NotFount = 404 Error = 500 )
View Source
const HttpDefaultTimeout = 8 * time.Second
View Source
const RouteRegTaskPath = "/register/{clientId}"
View Source
const RouteRegTaskTpl = "/register/%s"
View Source
const RouteSchedulePath = "/schedule/{clientId}"
View Source
const RouteScheduleTpl = "/schedule/%s"
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CallElement ¶
type CallElement struct {
HandleCode int `json:"handleCode"` //200表示正常,500表示失败
HandleMsg string `json:"handleMsg"`
JobId string `json:"jobId"`
InstanceId int `json:"instanceId"`
ExecutorHandler string `json:"ExecutorHandler"`
}
CallElement 执行器执行完任务后,回调任务结果时使用
type RunReq ¶
type RunReq struct {
JobID string `json:"jobId"` // 任务ID
ExecutorHandler string `json:"executorHandler"` // 任务标识
InstanceId int `json:"instanceId"` // 任务实例ID
Time time.Time `json:"time"` // 出发请求的时间
Data map[string]interface{} `json:"data"`
}
RunReq 触发任务请求参数
type ScheduleResponse ¶
Click to show internal directories.
Click to hide internal directories.