forked from github/dataease
Merge pull request #12032 from dataease/pr@dev-v2@perf_threshold_npe
fix(X-Pack): 阈值告警-可能存在的NPE
This commit is contained in:
commit
4787d2857b
@ -219,7 +219,7 @@ public class ChartViewThresholdManage {
|
||||
if (ObjectUtils.isEmpty(fieldDTO)) continue;
|
||||
String fieldDTOName = fieldDTO.getName();
|
||||
String dataeaseName = fieldDTO.getDataeaseName();
|
||||
List<String> valueList = rows.stream().map(row -> row.get(dataeaseName).toString()).collect(Collectors.toList());
|
||||
List<String> valueList = rows.stream().map(row -> ObjectUtils.isEmpty(row.get(dataeaseName)) ? null : row.get(dataeaseName).toString()).collect(Collectors.toList());
|
||||
String replacement = fieldDTOName + ": " + JsonUtil.toJSONString(valueList);
|
||||
// 替换文本
|
||||
matcher.appendReplacement(sb, replacement);
|
||||
|
2
de-xpack
2
de-xpack
@ -1 +1 @@
|
||||
Subproject commit 08153f88e0d2cf6bc560a63ab84afdb8339dc6c1
|
||||
Subproject commit f0301c703bfff22a05b3e38ac49200dae49ac1e9
|
Loading…
Reference in New Issue
Block a user