From e78f475ceab73e40f6c97890ffb54dd5f9e72ce8 Mon Sep 17 00:00:00 2001 From: Joshua Li Date: Thu, 7 Apr 2022 11:26:10 -0700 Subject: [PATCH] Bug fix for invalid service map Signed-off-by: Joshua Li --- .../components/trace_analytics/components/traces/trace_view.tsx | 1 + 1 file changed, 1 insertion(+) diff --git a/dashboards-observability/public/components/trace_analytics/components/traces/trace_view.tsx b/dashboards-observability/public/components/trace_analytics/components/traces/trace_view.tsx index b681d8aae..e839a87ec 100644 --- a/dashboards-observability/public/components/trace_analytics/components/traces/trace_view.tsx +++ b/dashboards-observability/public/components/trace_analytics/components/traces/trace_view.tsx @@ -170,6 +170,7 @@ export function TraceView(props: TraceViewProps) { }); const filteredServiceMap: ServiceObject = {}; Object.entries(services).forEach(([serviceName, service]: [string, any]) => { + if (!serviceMap[serviceName]) return; filteredServiceMap[serviceName] = serviceMap[serviceName]; filteredServiceMap[serviceName].latency = _.round(service.latency / service.throughput, 2); filteredServiceMap[serviceName].error_rate = _.round(