From ad3d36e6b7f322c3163851f6dca5fc4d19d75389 Mon Sep 17 00:00:00 2001 From: Erik Sundell Date: Tue, 18 Dec 2018 09:44:51 +0100 Subject: [PATCH] Make sure panel id is unique since some datasources (Graphite) will cancel ongoing requests with the same panel id --- public/app/features/explore/Explore.tsx | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/public/app/features/explore/Explore.tsx b/public/app/features/explore/Explore.tsx index adfe9c7ca76..d2a81864ed1 100644 --- a/public/app/features/explore/Explore.tsx +++ b/public/app/features/explore/Explore.tsx @@ -608,9 +608,11 @@ export class Explore extends React.PureComponent { // Clone range for query request // const queryRange: RawTimeRange = { ...range }; // const { from, to, raw } = this.timeSrv.timeRange(); - // Datasource is using `panelId + query.refId` for cancellation logic. + // Most datasource is using `panelId + query.refId` for cancellation logic. // Using `format` here because it relates to the view panel that the request is for. - const panelId = queryOptions.format; + // However, some datasources don't use `panelId + query.refId`, but only `panelId`. + // Therefore panel id has to be unique. + const panelId = `${queryOptions.format}-${query.key}`; return { interval,