You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@metron.apache.org by sa...@apache.org on 2019/12/13 21:13:15 UTC
[metron] branch master updated: METRON-2276 [UI] Performance:
Switching back from manual filtering fires a " full query"
(ruffle1986 via sardell) closes apache/metron#1527
This is an automated email from the ASF dual-hosted git repository.
sardell pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/metron.git
The following commit(s) were added to refs/heads/master by this push:
new 0da31ba METRON-2276 [UI] Performance: Switching back from manual filtering fires a "full query" (ruffle1986 via sardell) closes apache/metron#1527
0da31ba is described below
commit 0da31ba17a522b5afb5186d819e70999c4702e77
Author: ruffle1986 <ft...@gmail.com>
AuthorDate: Fri Dec 13 16:12:49 2019 -0500
METRON-2276 [UI] Performance: Switching back from manual filtering fires a "full query" (ruffle1986 via sardell) closes apache/metron#1527
---
.../src/app/alerts/alerts-list/alerts-list.component.html | 9 ++++++++-
.../src/app/alerts/alerts-list/alerts-list.component.ts | 7 ++++---
2 files changed, 12 insertions(+), 4 deletions(-)
diff --git a/metron-interface/metron-alerts/src/app/alerts/alerts-list/alerts-list.component.html b/metron-interface/metron-alerts/src/app/alerts/alerts-list/alerts-list.component.html
index a078e8f..3fbeefe 100755
--- a/metron-interface/metron-alerts/src/app/alerts/alerts-list/alerts-list.component.html
+++ b/metron-interface/metron-alerts/src/app/alerts/alerts-list/alerts-list.component.html
@@ -20,7 +20,14 @@
<span class="input-group-prepend">
<button class="btn btn-secondary btn-saved-searches" type="button" (click)="showSavedSearches()">Searches</button>
</span>
- <div appAceEditor *ngIf="!isQueryBuilderModeManual()" class="flex-fill" placeholder="Search Alerts" [text]="queryBuilder.displayQuery" (textChanged)="onSearch($event)"> </div>
+ <div
+ appAceEditor
+ *ngIf="!isQueryBuilderModeManual()"
+ class="flex-fill"
+ placeholder="Search Alerts"
+ [text]="queryBuilder.displayQuery"
+ (textChanged)="onBuilderQueryChanged($event)"
+ > </div>
<div class="flex-fill" *ngIf="isQueryBuilderModeManual()">
<input #manualQuery type="text"
class="manual-query-input"
diff --git a/metron-interface/metron-alerts/src/app/alerts/alerts-list/alerts-list.component.ts b/metron-interface/metron-alerts/src/app/alerts/alerts-list/alerts-list.component.ts
index 9e7f0b8..66c0f0f 100755
--- a/metron-interface/metron-alerts/src/app/alerts/alerts-list/alerts-list.component.ts
+++ b/metron-interface/metron-alerts/src/app/alerts/alerts-list/alerts-list.component.ts
@@ -545,9 +545,6 @@ export class AlertsListComponent implements OnInit, OnDestroy {
this.queryBuilder.setFilteringMode(FilteringMode.MANUAL);
} else {
this.queryBuilder.setFilteringMode(FilteringMode.BUILDER);
- // FIXME: this could lead to a large blocking load depending on the response time
- this.queryBuilder.clearSearch();
- this.search();
}
}
@@ -555,4 +552,8 @@ export class AlertsListComponent implements OnInit, OnDestroy {
return this.queryBuilder.query;
}
+ onBuilderQueryChanged(query: string) {
+ this.staleDataState = true;
+ }
+
}