From 61c24f6b0417fea3bffa4b78a75787b899d97589 Mon Sep 17 00:00:00 2001 From: shikong <919411476@qq.com> Date: Sat, 10 Feb 2024 01:13:34 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=20=E5=AE=9E=E6=97=B6?= =?UTF-8?q?=E6=B5=81=E9=87=8D=E5=A4=8D=E8=AF=B7=E6=B1=82=E5=88=99=E5=85=B3?= =?UTF-8?q?=E9=97=AD=E4=B8=8A=E4=B8=80=E6=AC=A1=E8=AF=B7=E6=B1=82=E7=9A=84?= =?UTF-8?q?=E5=AE=9E=E6=97=B6=E6=B5=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../gb28181/mocking/service/device/DeviceProxyService.java | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/gb28181-mocking-service/src/main/java/cn/skcks/docking/gb28181/mocking/service/device/DeviceProxyService.java b/gb28181-mocking-service/src/main/java/cn/skcks/docking/gb28181/mocking/service/device/DeviceProxyService.java index 689e276..ebc3bd5 100644 --- a/gb28181-mocking-service/src/main/java/cn/skcks/docking/gb28181/mocking/service/device/DeviceProxyService.java +++ b/gb28181-mocking-service/src/main/java/cn/skcks/docking/gb28181/mocking/service/device/DeviceProxyService.java @@ -415,7 +415,10 @@ public class DeviceProxyService { @SneakyThrows public void pullLiveStream2Rtp(SIPRequest request,Runnable sendOkResponse,String callId, MockingDevice device, String rtpAddr, int rtpPort, String ssrc){ - String liveCache = CacheUtil.getKey("INVITE", "LIVE", device.getGbDeviceId()); + String liveCacheKey = CacheUtil.getKey("INVITE", "LIVE", device.getGbDeviceId()); + String liveCache = RedisUtil.StringOps.get(liveCacheKey); + RedisUtil.KeyOps.delete(liveCache); + // 关闭已存在的实时流 bye 订阅(如果存在) subscribe.getByeSubscribe().delPublisher(liveCache);