| | |
| | | import com.ycl.utils.CheckPointUtil; |
| | | import com.ycl.utils.DateUtils; |
| | | import constant.ApiConstants; |
| | | import constant.CheckConstants; |
| | | import constant.RedisConstant; |
| | | import enumeration.ErrorType; |
| | | import enumeration.general.WorkOrderStatusEnum; |
| | |
| | | item.setNo(item.getDeviceId()); |
| | | } |
| | | }); |
| | | pointService.setDeviceTagByGB(records); |
| | | pointService.setDeviceTagByGB(records, CheckConstants.Rule_Category_Video); |
| | | //存放在mongo中 |
| | | mongoTemplate.insertAll(records); |
| | | // 工单生成 |
| | |
| | | item.setNo(item.getSerialNumber().getShowValue()); |
| | | } |
| | | }); |
| | | pointService.setDeviceTagByGB(records); |
| | | //TODO:优云的一机一档包含了视频、车辆、人脸 是有一种是省厅就算省厅吗 |
| | | pointService.setDeviceTagByGB(records,CheckConstants.Rule_Category_Video); |
| | | pointService.setNew(records); |
| | | //存放在mongo中 |
| | | mongoTemplate.insertAll(records); |
| | |
| | | |
| | | /** |
| | | * 点位在线PING检测 |
| | | * 任务会先执行一次优云同步,然后执行ping检测 |
| | | * online字段来自于优云,pingOnline为主动ping检测的。存入mongo给数据中心查阅 |
| | | */ |
| | | public void pointOnline() throws ExecutionException, InterruptedException { |
| | | log.info("开始检测点位在线"); |
| | |
| | | log.error("请配置离线次数,此次设置为默认值2"); |
| | | } |
| | | // 先查出设备IP集合,剔除掉在线情况是未知的,并且只检测正在考核的设备避免多余工单 |
| | | //TODO:需要把海康和优云的任务的时间调到ping之前 |
| | | //TODO:这里需要存三个标签吗 |
| | | List<TMonitorResult> monitorList = monitorMapper.getDistinctIP(); |
| | | //补充错误时间点 |
| | | Query onlineQuery = new Query(Criteria.where("mongoCreateTime").gte(DateUtils.getDayStart(new Date())).lt(DateUtils.getDayEnd(new Date()))); |
| | |
| | | item.setNo(item.getDeviceId()); |
| | | } |
| | | }); |
| | | pointService.setDeviceTagByGB(records); |
| | | pointService.setDeviceTagByGB(records,CheckConstants.Rule_Category_Video); |
| | | //存放在mongo中 |
| | | mongoTemplate.insertAll(records); |
| | | //更新point表在线状态 |
| | |
| | | } |
| | | }); |
| | | //打标签 |
| | | pointService.setDeviceTagByGB(records); |
| | | pointService.setDeviceTagByGB(records,CheckConstants.Rule_Category_Video); |
| | | //存放在mongo中 |
| | | mongoTemplate.insertAll(records); |
| | | // // 工单生成 |