Skip to content

Commit

Permalink
logs: histogram: handle backend-mode queries (grafana#50535)
Browse files Browse the repository at this point in the history
  • Loading branch information
gabor authored Jun 13, 2022
1 parent 88279dd commit a0e5a4e
Showing 1 changed file with 11 additions and 1 deletion.
12 changes: 11 additions & 1 deletion public/app/core/logs_model.ts
Original file line number Diff line number Diff line change
Expand Up @@ -702,7 +702,17 @@ export function queryLogsVolume<T extends DataQuery>(
observer.complete();
},
next: (dataQueryResponse: DataQueryResponse) => {
rawLogsVolume = rawLogsVolume.concat(dataQueryResponse.data.map(toDataFrame));
const { error } = dataQueryResponse;
if (error !== undefined) {
observer.next({
state: LoadingState.Error,
error,
data: [],
});
observer.error(error);
} else {
rawLogsVolume = rawLogsVolume.concat(dataQueryResponse.data.map(toDataFrame));
}
},
error: (error) => {
observer.next({
Expand Down

0 comments on commit a0e5a4e

Please sign in to comment.