Index: ProportionalCapacityPreemptionPolicy.java =================================================================== --- ProportionalCapacityPreemptionPolicy.java (revision 1592549) +++ ProportionalCapacityPreemptionPolicy.java (working copy) @@ -183,6 +183,11 @@ private void containerBasedPreemptOrKill(CSQueue root, Resource clusterResources) { + // if we are in observeOnly mode return before any action is taken + if (observeOnly) { + return; + } + // extract a summary of the queues from scheduler TempQueue tRoot; synchronized (scheduler) { @@ -204,11 +209,6 @@ logToCSV(queues); - // if we are in observeOnly mode return before any action is taken - if (observeOnly) { - return; - } - // preempt (or kill) the selected containers for (Map.Entry> e : toPreempt.entrySet()) {