From 9506bef6cb3f204931794479a83ae35f4559049c Mon Sep 17 00:00:00 2001 From: 648540858 <648540858@qq.com> Date: Mon, 21 Oct 2024 12:36:37 +0800 Subject: [PATCH] =?UTF-8?q?=E7=A7=BB=E9=99=A4=E6=9C=AA=E4=BD=BF=E7=94=A8?= =?UTF-8?q?=E7=9A=84=E6=96=B9=E6=B3=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../iot/vmp/storager/IRedisCatchStorage.java | 4 ---- .../storager/impl/RedisCatchStorageImpl.java | 22 ------------------- 2 files changed, 26 deletions(-) diff --git a/src/main/java/com/genersoft/iot/vmp/storager/IRedisCatchStorage.java b/src/main/java/com/genersoft/iot/vmp/storager/IRedisCatchStorage.java index 6d705101..e1d6b6f7 100755 --- a/src/main/java/com/genersoft/iot/vmp/storager/IRedisCatchStorage.java +++ b/src/main/java/com/genersoft/iot/vmp/storager/IRedisCatchStorage.java @@ -100,10 +100,6 @@ public interface IRedisCatchStorage { GPSMsgInfo getGpsMsgInfo(String gbId); List getAllGpsMsgInfo(); - Long getSN(String method); - - void resetAllSN(); - MediaInfo getStreamInfo(String app, String streamId, String mediaServerId); MediaInfo getProxyStream(String app, String streamId); diff --git a/src/main/java/com/genersoft/iot/vmp/storager/impl/RedisCatchStorageImpl.java b/src/main/java/com/genersoft/iot/vmp/storager/impl/RedisCatchStorageImpl.java index 81c8b3da..d51e1174 100755 --- a/src/main/java/com/genersoft/iot/vmp/storager/impl/RedisCatchStorageImpl.java +++ b/src/main/java/com/genersoft/iot/vmp/storager/impl/RedisCatchStorageImpl.java @@ -66,34 +66,12 @@ public class RedisCatchStorageImpl implements IRedisCatchStorage { return result; } - @Override - public Long getSN(String method) { - String key = VideoManagerConstants.SIP_SN_PREFIX + userSetting.getServerId() + "_" + method; - - Long result = redisTemplate.opsForValue().increment(key, 1L); - if (result != null && result > Integer.MAX_VALUE) { - redisTemplate.opsForValue().set(key, 1); - result = 1L; - } - return result; - } - @Override public void resetAllCSEQ() { String key = VideoManagerConstants.SIP_CSEQ_PREFIX + userSetting.getServerId(); redisTemplate.opsForValue().set(key, 1); } - @Override - public void resetAllSN() { - String scanKey = VideoManagerConstants.SIP_SN_PREFIX + userSetting.getServerId() + "_*"; - List keys = RedisUtil.scan(redisTemplate, scanKey); - for (Object o : keys) { - String key = (String) o; - redisTemplate.opsForValue().set(key, 1); - } - } - @Override public void updatePlatformCatchInfo(PlatformCatch parentPlatformCatch) { String key = VideoManagerConstants.PLATFORM_CATCH_PREFIX + userSetting.getServerId() + "_" + parentPlatformCatch.getId();