diff options
author | Ola Aunrønning <olaa@verizonmedia.com> | 2022-08-15 15:46:57 +0200 |
---|---|---|
committer | Ola Aunrønning <olaa@verizonmedia.com> | 2022-08-15 15:46:57 +0200 |
commit | a96ebf411cc18c968ddd0368bd639d0d654f8276 (patch) | |
tree | 958e10b4aa4083106b6657d47e066dcf41e70634 /metrics-proxy/src/test | |
parent | f552ae6e444470948533353a0371f2c57e8dcdf2 (diff) |
Add Vespa consumer to host life metric
Diffstat (limited to 'metrics-proxy/src/test')
-rw-r--r-- | metrics-proxy/src/test/java/ai/vespa/metricsproxy/node/NodeMetricGathererTest.java | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/metrics-proxy/src/test/java/ai/vespa/metricsproxy/node/NodeMetricGathererTest.java b/metrics-proxy/src/test/java/ai/vespa/metricsproxy/node/NodeMetricGathererTest.java index c693e9690e8..0de3526b40d 100644 --- a/metrics-proxy/src/test/java/ai/vespa/metricsproxy/node/NodeMetricGathererTest.java +++ b/metrics-proxy/src/test/java/ai/vespa/metricsproxy/node/NodeMetricGathererTest.java @@ -1,6 +1,7 @@ // Copyright Yahoo. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root. package ai.vespa.metricsproxy.node; +import ai.vespa.metricsproxy.metric.model.ConsumerId; import ai.vespa.metricsproxy.metric.model.MetricId; import ai.vespa.metricsproxy.metric.model.MetricsPacket; import com.fasterxml.jackson.databind.JsonNode; @@ -10,6 +11,7 @@ import org.junit.Test; import java.util.ArrayList; import java.util.List; +import java.util.Set; import static org.junit.Assert.assertEquals; @@ -33,6 +35,7 @@ public class NodeMetricGathererTest { assertEquals(123, packet.timestamp); assertEquals(12l, packet.metrics().get(MetricId.toMetricId("uptime"))); assertEquals(1l, packet.metrics().get(MetricId.toMetricId("alive"))); + assertEquals(Set.of(ConsumerId.toConsumerId("Vespa")), packet.consumers()); } private JsonNode generateHostLifePacket() { |