summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGeorgios Andreadis <info@gandreadis.com>2020-03-10 15:59:49 +0100
committerGeorgios Andreadis <info@gandreadis.com>2020-03-11 12:48:29 +0100
commit93775374288892812e5397be914e6d32aaa23a09 (patch)
treefcceef51755b31f3f3a65dda4aad60ae73d15923
parent03ec0932771bc194b731c2142f754baebf36ca4f (diff)
Merge hypervisor monitor calls
-rw-r--r--opendc/opendc-compute/src/main/kotlin/com/atlarge/opendc/compute/virt/driver/hypervisor/HypervisorVirtDriver.kt16
1 files changed, 7 insertions, 9 deletions
diff --git a/opendc/opendc-compute/src/main/kotlin/com/atlarge/opendc/compute/virt/driver/hypervisor/HypervisorVirtDriver.kt b/opendc/opendc-compute/src/main/kotlin/com/atlarge/opendc/compute/virt/driver/hypervisor/HypervisorVirtDriver.kt
index 05e1ab90..f63a5484 100644
--- a/opendc/opendc-compute/src/main/kotlin/com/atlarge/opendc/compute/virt/driver/hypervisor/HypervisorVirtDriver.kt
+++ b/opendc/opendc-compute/src/main/kotlin/com/atlarge/opendc/compute/virt/driver/hypervisor/HypervisorVirtDriver.kt
@@ -190,15 +190,13 @@ class HypervisorVirtDriver(
}
}
- for (i in burst.indices) {
- monitor.onSliceFinish(
- end,
- burst[i],
- remainder[i],
- vms.size,
- hostContext.server
- )
- }
+ monitor.onSliceFinish(
+ end,
+ burst.sum(),
+ remainder.sum(),
+ vms.size,
+ hostContext.server
+ )
}
this.call = call
call.invokeOnCompletion { this.call = null }