Rename live option in queries (#19658)

This commit is contained in:
David
2019-10-07 14:09:46 +02:00
committed by GitHub
parent aa70abb35d
commit cf7ace6aad
5 changed files with 9 additions and 7 deletions

View File

@@ -797,7 +797,7 @@ describe('ElasticResponse', () => {
interval: '10s',
isLogsQuery: true,
key: 'Q-1561369883389-0.7611823271062786-0',
live: false,
liveStreaming: false,
maxDataPoints: 1620,
query: '',
timeField: '@timestamp',

View File

@@ -216,7 +216,7 @@ export class LokiDatasource extends DataSourceApi<LokiQuery, LokiOptions> {
const subQueries = options.targets
.filter(target => target.expr && !target.hide)
.map(target => {
if (target.live) {
if (target.liveStreaming) {
return this.runLiveQuery(options, target);
}
return this.runQuery(options, target);

View File

@@ -3,7 +3,7 @@ import { Labels } from '@grafana/data';
export interface LokiQuery extends DataQuery {
expr: string;
live?: boolean;
liveStreaming?: boolean;
query?: string;
regexp?: string;
}