Service graph: Fix error when service graph metrics are aggregated (#68613)

make service graph work with aggregated metrics
pull/68693/head
Domas 2 years ago committed by GitHub
parent b7a0313cba
commit e1c2eb8c10
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 2
      public/app/plugins/datasource/tempo/datasource.ts

@ -744,7 +744,7 @@ function makePromServiceMapRequest(options: DataQueryRequest<TempoQuery>): DataQ
refId: metric,
// options.targets[0] is not correct here, but not sure what should happen if you have multiple queries for
// service map at the same time anyway
expr: `rate(${metric}${options.targets[0].serviceMapQuery || ''}[$__range])`,
expr: `sum by (client, server) (rate(${metric}${options.targets[0].serviceMapQuery || ''}[$__range]))`,
instant: true,
};
}),

Loading…
Cancel
Save