Browse Source

新增报警过滤规则

feature_hph_检查规则配置过滤
1049970895@qniao.cn 2 years ago
parent
commit
8fc6c4e3c0
1 changed files with 3 additions and 2 deletions
  1. 5
      ai-root-cloud-statistics/src/main/java/com/qniao/rootcloudstatistics/RootCloudIotDataFormatterJob.java

5
ai-root-cloud-statistics/src/main/java/com/qniao/rootcloudstatistics/RootCloudIotDataFormatterJob.java

@ -232,7 +232,8 @@ public class RootCloudIotDataFormatterJob {
// 通过时间范围对数据进行过滤
// 查询redis缓存是否存在该摄像头的休眠时间范围
String redisValue = jedis.hget(redisKey, value.getCameraId().toString());
// todo 待放开
/*String redisValue = jedis.hget(redisKey, value.getCameraId().toString());
if (StringUtils.isNotBlank(redisValue)) {
JSONObject jsonObject = JSONUtil.parseObj(redisValue);
String startLocalTime = jsonObject.getStr(START_LOCAL_TIME);
@ -251,7 +252,7 @@ public class RootCloudIotDataFormatterJob {
String[] endLocalTimeSplit = endLocalTime.split(":");
if (checkLocalTime(value, startLocalTime, startLocalTimeSplit, endLocalTime, endLocalTimeSplit)) return;
}
}
}*/
String query = "select * from qn_ai_alarm where id = ?";
AIWarningDataReceivedEvent.Alarm image = value.getAlarmList().get(0);
Entity alarm = Db.use().queryOne(query, image.getAlarmId());

Loading…
Cancel
Save