1
0
mirror of https://github.com/newnius/YAO-scheduler.git synced 2025-12-15 08:16:43 +00:00

update fair

This commit is contained in:
2020-05-28 11:44:15 +08:00
parent c044d43490
commit e0232784df
7 changed files with 45 additions and 8 deletions

View File

@@ -15,7 +15,7 @@ type SchedulerCapacity struct {
nextQueue string
jobs map[string]*JobManager
queues map[string][]Job
queuesMu sync.Mutex
queuesMu sync.Mutex
schedulingJobs map[string]bool
schedulingMu sync.Mutex
@@ -413,3 +413,12 @@ func (scheduler *SchedulerCapacity) UpdateParallelism(parallelism int) bool {
func (scheduler *SchedulerCapacity) updateGroup(group Group) bool {
return true
}
func (scheduler *SchedulerCapacity) DebugDump() map[string]interface{} {
res := map[string]interface{}{}
res["nextQueue"] = scheduler.nextQueue
res["schedulingJobs"] = scheduler.schedulingJobs
res["resourceAllocations"] = scheduler.resourceAllocations
res["allocatingGPU"] = scheduler.allocatingGPU
return res
}