Commit 759d9484 authored by 赵啸非's avatar 赵啸非

添加服务追踪

parent fa83a07b
...@@ -245,7 +245,7 @@ public class SyncAppointWaitAndFinTaskImpl implements ITaskExcuteService { ...@@ -245,7 +245,7 @@ public class SyncAppointWaitAndFinTaskImpl implements ITaskExcuteService {
careRecordsQuery.setCreateTimeEnd(DateUtils.getCurrStrDate()); careRecordsQuery.setCreateTimeEnd(DateUtils.getCurrStrDate());
int dayServiceNum = careRecordsService.count(careRecordsQuery, null); int dayServiceNum = careRecordsService.count(careRecordsQuery, null);
if (dayServiceNum > maxServicePersonNum) { if (dayServiceNum > maxServicePersonNum) {
log.info("服务人数超过最大数量!"); log.info("关怀服务人数超过最大数量!");
return true; return true;
} }
return false; return false;
......
package com.mortals.xhx.module.hik.event.service.impl; package com.mortals.xhx.module.hik.event.service.impl;
import com.alibaba.fastjson.JSON;
import com.mortals.xhx.common.code.HikEventTypeEnum; import com.mortals.xhx.common.code.HikEventTypeEnum;
import com.mortals.xhx.module.hik.event.model.req.callback.recognition.EventData; import com.mortals.xhx.module.hik.event.model.req.callback.recognition.EventData;
import com.mortals.xhx.module.hik.event.model.req.callback.EventsItem; import com.mortals.xhx.module.hik.event.model.req.callback.EventsItem;
...@@ -37,7 +38,7 @@ public class StrangerRecoginze extends EventTypeAbstract { ...@@ -37,7 +38,7 @@ public class StrangerRecoginze extends EventTypeAbstract {
@Override @Override
public void saveEventData(EventsItem event) { public void saveEventData(EventsItem event) {
log.info("处理陌生人事件,eventId:{}", event.getEventId()); log.info("处理陌生人事件,event:{}", JSON.toJSONString(event));
EventData eventData = event.getData(); EventData eventData = event.getData();
//识别结果 //识别结果
FaceRecognitionResult faceRecognitionResult = eventData.getFaceRecognitionResult(); FaceRecognitionResult faceRecognitionResult = eventData.getFaceRecognitionResult();
...@@ -45,6 +46,7 @@ public class StrangerRecoginze extends EventTypeAbstract { ...@@ -45,6 +46,7 @@ public class StrangerRecoginze extends EventTypeAbstract {
Snap snap = faceRecognitionResult.getSnap(); Snap snap = faceRecognitionResult.getSnap();
//不论识别结果 保存流量数据 //不论识别结果 保存流量数据
RealtimeDataflowEntity realtimeDataflowEntity = new RealtimeDataflowEntity(); RealtimeDataflowEntity realtimeDataflowEntity = new RealtimeDataflowEntity();
realtimeDataflowEntity.initAttrValue();
realtimeDataflowEntity.setDetectTime(event.getHappenTime()); realtimeDataflowEntity.setDetectTime(event.getHappenTime());
String resIndexCodes = eventData.getResInfo().stream().map(i -> i.getIndexCode()).collect(Collectors.joining(",")); String resIndexCodes = eventData.getResInfo().stream().map(i -> i.getIndexCode()).collect(Collectors.joining(","));
realtimeDataflowEntity.setDevice(resIndexCodes); realtimeDataflowEntity.setDevice(resIndexCodes);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment