| | |
| | | mediaService.clearAll(); |
| | | } |
| | | |
| | | @Scheduled(cron = "0/5 * * * * ?") |
| | | public void syncMediamtx() { |
| | | log.debug("定时同步MediaMTX任务"); |
| | | List<String> nameList = mediaService.getNameList(); |
| | | List<ArdVtdu> ardVtduList = selectArdVtduList(new ArdVtdu()); |
| | | asyncMediaMTX(ardVtduList, nameList); |
| | | } |
| | | |
| | | /** |
| | | * 查询流媒体管理 |
| | | * |
| | |
| | | diffListToAdd(vtdus, names).forEach(vtdu -> { |
| | | mediaService.addPath(vtdu); |
| | | }); |
| | | } |
| | | |
| | | //匹配rtsp地址 |
| | | private String matchRtsp(String value) { |
| | | Matcher matcher = Pattern.compile("rtsp://[^\\s\"]+").matcher(value); |
| | | if (matcher.find()) { |
| | | return matcher.group(); |
| | | } else { |
| | | return ""; |
| | | } |
| | | } |
| | | } |