From b569bd3060a6960d11cc32b75dbcc57e9a93bc3f Mon Sep 17 00:00:00 2001 From: Pradyumna Kaushik Date: Mon, 19 Feb 2018 03:29:56 +0000 Subject: [PATCH] Merged in schedPolSwitchLogging-revert (pull request #7) adding back the call to base#LogSchedPolicySwitch(...). Had removed this addition by mistake when resolving merge conflicts. Approved-by: Akash Kothawale Approved-by: Pradyumna Kaushik --- schedulers/schedPolicy.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/schedulers/schedPolicy.go b/schedulers/schedPolicy.go index 8a64c78..2822330 100644 --- a/schedulers/schedPolicy.go +++ b/schedulers/schedPolicy.go @@ -33,8 +33,9 @@ func (bsps *baseSchedPolicyState) switchIfNecessary(spc SchedPolicyContext) { // Switching to a random scheduling policy. // TODO: Switch based on some criteria. index := rand.Intn(len(SchedPolicies)) - for _, v := range SchedPolicies { + for k, v := range SchedPolicies { if index == 0 { + baseSchedRef.LogSchedPolicySwitch(k, v) spc.SwitchSchedPol(v) // Resetting the number of tasks scheduled. bsps.numTasksScheduled = 0