From 5253e577db7c4e0b6e8fd2884e84f9fbf588af78 Mon Sep 17 00:00:00 2001 From: masaimu Date: Mon, 3 Jun 2024 11:35:22 +0800 Subject: [PATCH] fix: log sample group by (#861) --- .../server/home/alert/plugin/AlertSaveHistoryHandler.java | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/server/home/home-alert/src/main/java/io/holoinsight/server/home/alert/plugin/AlertSaveHistoryHandler.java b/server/home/home-alert/src/main/java/io/holoinsight/server/home/alert/plugin/AlertSaveHistoryHandler.java index 235bb9707..b922a0f2d 100644 --- a/server/home/home-alert/src/main/java/io/holoinsight/server/home/alert/plugin/AlertSaveHistoryHandler.java +++ b/server/home/home-alert/src/main/java/io/holoinsight/server/home/alert/plugin/AlertSaveHistoryHandler.java @@ -268,9 +268,9 @@ private QueryProto.Datasource buildSampleDatasource(DataSource dataSource, Trigg long end = TimeRangeUtil.getEndTimestamp(alarmTime, dataSource); String metric = dataSource.getMetric() + "_logsamples"; - QueryProto.Datasource.Builder builder = QueryProto.Datasource.newBuilder().setStart(start) - .setEnd(end).setMetric(metric).addAllFilters(filterConvert(dataSource.getFilters())) - .setAggregator("sample").addAllGroupBy(Collections.singletonList("app")); + QueryProto.Datasource.Builder builder = + QueryProto.Datasource.newBuilder().setStart(start).setEnd(end).setMetric(metric) + .addAllFilters(filterConvert(dataSource.getFilters())).setAggregator("sample"); return builder.build(); }