From 927088803397e7aa275c23a1cc311aa2fbdb9e1c Mon Sep 17 00:00:00 2001 From: bcxc <1003410156@qq.com> Date: Thu, 5 Sep 2024 11:18:37 +0800 Subject: [PATCH] [bugfix] Fixed influxdb the issue that max and min were displayed in the performance metrics page, and the minimum value was taken for max and the maximum value for min --- .../warehouse/store/history/influxdb/InfluxdbDataStorage.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/warehouse/src/main/java/org/apache/hertzbeat/warehouse/store/history/influxdb/InfluxdbDataStorage.java b/warehouse/src/main/java/org/apache/hertzbeat/warehouse/store/history/influxdb/InfluxdbDataStorage.java index 85a21f3f0f4..93601035a54 100644 --- a/warehouse/src/main/java/org/apache/hertzbeat/warehouse/store/history/influxdb/InfluxdbDataStorage.java +++ b/warehouse/src/main/java/org/apache/hertzbeat/warehouse/store/history/influxdb/InfluxdbDataStorage.java @@ -270,12 +270,12 @@ public Map> getHistoryIntervalMetricData(Long monitorId, Str continue; } if (value.get(3) != null) { - valueBuilder.min(this.parseDoubleValue(value.get(3).toString())); + valueBuilder.max(this.parseDoubleValue(value.get(3).toString())); } else { continue; } if (value.get(4) != null) { - valueBuilder.max(this.parseDoubleValue(value.get(4).toString())); + valueBuilder.min(this.parseDoubleValue(value.get(4).toString())); } else { continue; }