From 0d0b31f71552ed592db21657b056e17460256830 Mon Sep 17 00:00:00 2001 From: 648540858 <648540858@qq.com> Date: Fri, 19 Apr 2024 10:27:24 +0800 Subject: [PATCH] =?UTF-8?q?=E4=B8=B4=E6=97=B6=E6=8F=90=E4=BA=A4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../com/genersoft/iot/vmp/conf/redis/RedisRpcConfig.java | 5 +++++ .../genersoft/iot/vmp/media/zlm/ZlmHttpHookSubscribe.java | 4 ++++ 2 files changed, 9 insertions(+) diff --git a/src/main/java/com/genersoft/iot/vmp/conf/redis/RedisRpcConfig.java b/src/main/java/com/genersoft/iot/vmp/conf/redis/RedisRpcConfig.java index 9746c2e1..e49b01de 100644 --- a/src/main/java/com/genersoft/iot/vmp/conf/redis/RedisRpcConfig.java +++ b/src/main/java/com/genersoft/iot/vmp/conf/redis/RedisRpcConfig.java @@ -6,6 +6,7 @@ import com.genersoft.iot.vmp.conf.UserSetting; import com.genersoft.iot.vmp.conf.redis.bean.RedisRpcMessage; import com.genersoft.iot.vmp.conf.redis.bean.RedisRpcRequest; import com.genersoft.iot.vmp.conf.redis.bean.RedisRpcResponse; +import com.genersoft.iot.vmp.media.zlm.ZlmHttpHookSubscribe; import com.genersoft.iot.vmp.service.redisMsg.control.RedisRpcController; import org.slf4j.Logger; import org.slf4j.LoggerFactory; @@ -45,6 +46,9 @@ public class RedisRpcConfig implements MessageListener { @Autowired private RedisTemplate redisTemplate; + @Autowired + private ZlmHttpHookSubscribe hookSubscribe; + private ConcurrentLinkedQueue taskQueue = new ConcurrentLinkedQueue<>(); @Qualifier("taskExecutor") @@ -216,5 +220,6 @@ public class RedisRpcConfig implements MessageListener { public void execute(){ System.out.println("callbacks的长度: " + callbacks.size()); System.out.println("队列的长度: " + topicSubscribers.size()); + System.out.println("HOOK监听的长度: " + hookSubscribe.size()); } } diff --git a/src/main/java/com/genersoft/iot/vmp/media/zlm/ZlmHttpHookSubscribe.java b/src/main/java/com/genersoft/iot/vmp/media/zlm/ZlmHttpHookSubscribe.java index 5e46f55c..6feeb139 100755 --- a/src/main/java/com/genersoft/iot/vmp/media/zlm/ZlmHttpHookSubscribe.java +++ b/src/main/java/com/genersoft/iot/vmp/media/zlm/ZlmHttpHookSubscribe.java @@ -158,4 +158,8 @@ public class ZlmHttpHookSubscribe { } } } + + public int size(){ + return allSubscribes.size(); + } }