diff options
| author | Fabian Mastenbroek <mail.fabianm@gmail.com> | 2020-03-16 22:37:06 +0100 |
|---|---|---|
| committer | Fabian Mastenbroek <mail.fabianm@gmail.com> | 2020-03-16 22:37:06 +0100 |
| commit | df088c89b43c4bcb5051c42906e91258ccd69ce5 (patch) | |
| tree | 907481fe3e2d2d7935ee7b4b6ffe14ed1ca012cb /opendc/opendc-format/src | |
| parent | 7c2f254aacd17ee0e77a0b09a464baa8044b6c3a (diff) | |
| parent | 1e95d668eb21eece59a402f500a9e38ec51af596 (diff) | |
Merge branch '2.x-perf-interf-extension' into '2.x'
Extend performance interference model to support minimum server load
See merge request opendc/opendc-simulator!43
Diffstat (limited to 'opendc/opendc-format/src')
4 files changed, 5 insertions, 4 deletions
diff --git a/opendc/opendc-format/src/main/kotlin/com/atlarge/opendc/format/trace/sc20/PerformanceInterferenceEntry.kt b/opendc/opendc-format/src/main/kotlin/com/atlarge/opendc/format/trace/sc20/PerformanceInterferenceEntry.kt index 1eeecb25..ade47e1b 100644 --- a/opendc/opendc-format/src/main/kotlin/com/atlarge/opendc/format/trace/sc20/PerformanceInterferenceEntry.kt +++ b/opendc/opendc-format/src/main/kotlin/com/atlarge/opendc/format/trace/sc20/PerformanceInterferenceEntry.kt @@ -2,5 +2,6 @@ package com.atlarge.opendc.format.trace.sc20 internal data class PerformanceInterferenceEntry( val vms: List<String>, + val minServerLoad: Double, val performanceScore: Double ) diff --git a/opendc/opendc-format/src/main/kotlin/com/atlarge/opendc/format/trace/sc20/Sc20PerformanceInterferenceReader.kt b/opendc/opendc-format/src/main/kotlin/com/atlarge/opendc/format/trace/sc20/Sc20PerformanceInterferenceReader.kt index b2d60bb9..daa1fdf8 100644 --- a/opendc/opendc-format/src/main/kotlin/com/atlarge/opendc/format/trace/sc20/Sc20PerformanceInterferenceReader.kt +++ b/opendc/opendc-format/src/main/kotlin/com/atlarge/opendc/format/trace/sc20/Sc20PerformanceInterferenceReader.kt @@ -31,7 +31,6 @@ import com.fasterxml.jackson.databind.ObjectMapper import com.fasterxml.jackson.module.kotlin.jacksonObjectMapper import com.fasterxml.jackson.module.kotlin.readValue import java.io.InputStream -import java.util.UUID /** * A parser for the JSON performance interference setup files used for the SC20 paper. @@ -50,7 +49,8 @@ class Sc20PerformanceInterferenceReader(input: InputStream, mapper: ObjectMapper return PerformanceInterferenceModel( performanceInterferenceModel.map { item -> PerformanceInterferenceModelItem( - item.vms.map { name -> UUID(0L, name.toLong()) }.toSet(), + item.vms.toSet(), + item.minServerLoad, item.performanceScore ) }.toSet() diff --git a/opendc/opendc-format/src/main/kotlin/com/atlarge/opendc/format/trace/sc20/Sc20TraceReader.kt b/opendc/opendc-format/src/main/kotlin/com/atlarge/opendc/format/trace/sc20/Sc20TraceReader.kt index 3c974e44..78a58671 100644 --- a/opendc/opendc-format/src/main/kotlin/com/atlarge/opendc/format/trace/sc20/Sc20TraceReader.kt +++ b/opendc/opendc-format/src/main/kotlin/com/atlarge/opendc/format/trace/sc20/Sc20TraceReader.kt @@ -125,7 +125,7 @@ class Sc20TraceReader( val uuid = UUID.randomUUID() val relevantPerformanceInterferenceModelItems = PerformanceInterferenceModel( - performanceInterferenceModel.items.filter { it.workloadIds.contains(uuid) }.toSet() + performanceInterferenceModel.items.filter { it.workloadNames.contains(vmId) }.toSet() ) val vmWorkload = VmWorkload( diff --git a/opendc/opendc-format/src/main/kotlin/com/atlarge/opendc/format/trace/vm/VmTraceReader.kt b/opendc/opendc-format/src/main/kotlin/com/atlarge/opendc/format/trace/vm/VmTraceReader.kt index d001687c..6b8843aa 100644 --- a/opendc/opendc-format/src/main/kotlin/com/atlarge/opendc/format/trace/vm/VmTraceReader.kt +++ b/opendc/opendc-format/src/main/kotlin/com/atlarge/opendc/format/trace/vm/VmTraceReader.kt @@ -123,7 +123,7 @@ class VmTraceReader( val uuid = UUID(0L, vmId) val relevantPerformanceInterferenceModelItems = PerformanceInterferenceModel( - performanceInterferenceModel.items.filter { it.workloadIds.contains(uuid) }.toSet() + performanceInterferenceModel.items.filter { it.workloadNames.contains(vmId.toString()) }.toSet() ) val vmWorkload = VmWorkload( |
