Commit c04bd3eb by 姚冰

[add] 全天分析事件处理添加

1 parent a6c59d43
...@@ -106,6 +106,7 @@ public class MqttClientMessageListener implements IMqttClientMessageListener { ...@@ -106,6 +106,7 @@ public class MqttClientMessageListener implements IMqttClientMessageListener {
for (RAgentEvent agentEvent : list) { for (RAgentEvent agentEvent : list) {
client.publish(StrUtil.format("/SA/{}/event/push", agentUid), JsonUtil.toJsonByte(agentEvent), MqttQoS.QOS2); client.publish(StrUtil.format("/SA/{}/event/push", agentUid), JsonUtil.toJsonByte(agentEvent), MqttQoS.QOS2);
} }
logger.info("agent:{} 结束下发事件监测", agentUid);
} }
//设备离线上报 //设备离线上报
...@@ -147,6 +148,7 @@ public class MqttClientMessageListener implements IMqttClientMessageListener { ...@@ -147,6 +148,7 @@ public class MqttClientMessageListener implements IMqttClientMessageListener {
//全天分析异常上报 //全天分析异常上报
private void handleWholeDayAnalyze(String payloadStr) { private void handleWholeDayAnalyze(String payloadStr) {
EventRecord eventRecord = JsonUtil.parseObject(payloadStr, EventRecord.class); EventRecord eventRecord = JsonUtil.parseObject(payloadStr, EventRecord.class);
recordService.save(eventRecord);
} }
} }
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!