From 4e13489366b31b3641ca37e9c41ec5f4ae41958c Mon Sep 17 00:00:00 2001 From: mk1990 <153958232@qq.com> Date: 星期三, 25 五月 2022 13:39:34 +0800 Subject: [PATCH] 解决设备第一次注册获取不到设备信息和通道信息的问题 --- src/main/java/com/genersoft/iot/vmp/gb28181/bean/SubscribeHolder.java | 5 +++-- 1 files changed, 3 insertions(+), 2 deletions(-) diff --git a/src/main/java/com/genersoft/iot/vmp/gb28181/bean/SubscribeHolder.java b/src/main/java/com/genersoft/iot/vmp/gb28181/bean/SubscribeHolder.java index 981fe1e..f191c00 100644 --- a/src/main/java/com/genersoft/iot/vmp/gb28181/bean/SubscribeHolder.java +++ b/src/main/java/com/genersoft/iot/vmp/gb28181/bean/SubscribeHolder.java @@ -59,12 +59,13 @@ mobilePositionMap.put(platformId, subscribeInfo); String key = VideoManagerConstants.SIP_SUBSCRIBE_PREFIX + "MobilePosition_" + platformId; // 娣诲姞浠诲姟澶勭悊GPS瀹氭椂鎺ㄩ�� - dynamicTask.startCron(key, new MobilePositionSubscribeHandlerTask(redisCatchStorage, sipCommanderForPlatform, storager, platformId, subscribeInfo.getSn(), key, this), subscribeInfo.getGpsInterval()); + dynamicTask.startCron(key, new MobilePositionSubscribeHandlerTask(redisCatchStorage, sipCommanderForPlatform, + storager, platformId, subscribeInfo.getSn(), key, this, dynamicTask), + subscribeInfo.getGpsInterval() * 1000); String taskOverdueKey = taskOverduePrefix + "MobilePosition_" + platformId; dynamicTask.stop(taskOverdueKey); // 娣诲姞浠诲姟澶勭悊璁㈤槄杩囨湡 dynamicTask.startDelay(taskOverdueKey, () -> { - System.out.println("璁㈤槄杩囨湡"); removeMobilePositionSubscribe(subscribeInfo.getId()); }, subscribeInfo.getExpires() * 1000); -- Gitblit v1.8.0