mirror of
https://github.com/grafana/grafana.git
synced 2026-07-29 15:59:50 -05:00
Store prev response uids in usedUids
This commit is contained in:
@@ -130,8 +130,11 @@ export function appendResponseToBufferedData(response: LokiTailResponse, data: M
|
|||||||
const labelsField = data.fields[3];
|
const labelsField = data.fields[3];
|
||||||
const idField = data.fields[4];
|
const idField = data.fields[4];
|
||||||
|
|
||||||
// We need to store and track all used uids to ensure that uids are unique
|
// We need to store and track all used uids (from current response, but also data) to ensure that uids are unique
|
||||||
const usedUids: { string?: number } = {};
|
const usedUids: { string?: number } = idField.values.toArray().reduce((obj, uid) => {
|
||||||
|
obj[uid] = 0;
|
||||||
|
return obj;
|
||||||
|
}, {});
|
||||||
|
|
||||||
for (const stream of streams) {
|
for (const stream of streams) {
|
||||||
// Find unique labels
|
// Find unique labels
|
||||||
|
|||||||
Reference in New Issue
Block a user