mirror of
https://github.com/newnius/YAO-scheduler.git
synced 2025-12-15 08:16:43 +00:00
32 lines
457 B
Go
32 lines
457 B
Go
package main
|
|
|
|
type Scheduler interface {
|
|
Start()
|
|
|
|
Schedule(Job)
|
|
|
|
UpdateProgress(job Job, state State)
|
|
|
|
AcquireResource(Job) []NodeStatus
|
|
|
|
ReleaseResource(Job, NodeStatus)
|
|
|
|
QueryState(jobName string) MsgJobStatus
|
|
|
|
QueryLogs(jobName string, taskName string) MsgLog
|
|
|
|
Stop(jobName string) MsgStop
|
|
|
|
ListJobs() MsgJobList
|
|
|
|
Summary() MsgSummary
|
|
|
|
Enable() bool
|
|
|
|
Disable() bool
|
|
|
|
UpdateParallelism(parallelism int) bool
|
|
|
|
updateGroup(group Group) bool
|
|
}
|