diff options
Diffstat (limited to 'sources/hv-collector-ct')
-rw-r--r-- | sources/hv-collector-ct/src/test/kotlin/org/onap/dcae/collectors/veshv/tests/fakes/metrics.kt | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/sources/hv-collector-ct/src/test/kotlin/org/onap/dcae/collectors/veshv/tests/fakes/metrics.kt b/sources/hv-collector-ct/src/test/kotlin/org/onap/dcae/collectors/veshv/tests/fakes/metrics.kt index 12555965..4a5474c6 100644 --- a/sources/hv-collector-ct/src/test/kotlin/org/onap/dcae/collectors/veshv/tests/fakes/metrics.kt +++ b/sources/hv-collector-ct/src/test/kotlin/org/onap/dcae/collectors/veshv/tests/fakes/metrics.kt @@ -42,6 +42,7 @@ class FakeMetrics : Metrics { var lastProcessingTimeMicros: Double = -1.0; private set var lastProcessingTimeWithoutRoutingMicros: Double = -1.0; private set var lastToCollectorTravelTime: Double = -1.0; private set + var lastTotalLatencyWithoutRouting: Double = -1.0; private set var messagesSentCount: Int = 0; private set var clientRejectionCause = mutableMapOf<ClientRejectionCause, Int>(); private set @@ -63,6 +64,7 @@ class FakeMetrics : Metrics { override fun notifyMessageReadyForRouting(msg: VesMessage) { lastProcessingTimeWithoutRoutingMicros = Duration.between(msg.wtpFrame.receivedAt, Instant.now()).toNanos() / 1000.0 + lastTotalLatencyWithoutRouting = Duration.between(TimeUtils.epochMicroToInstant(msg.header.lastEpochMicrosec), Instant.now()).toNanos() / 1000.0 } override fun notifyMessageSent(msg: RoutedMessage) { |