From 12e805ccc1730c0a185f104dbfce89a617f4bc97 Mon Sep 17 00:00:00 2001 From: cdf <857448963@qq.com> Date: Thu, 16 Jan 2025 19:32:46 +0800 Subject: [PATCH] =?UTF-8?q?=E6=8F=90=E4=BA=A4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../gather/detection/util/socket/cilent/NettyClient.java | 2 +- .../util/socket/cilent/NettySourceClientHandler.java | 2 +- entrance/src/main/resources/application.yml | 6 +++--- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/detection/src/main/java/com/njcn/gather/detection/util/socket/cilent/NettyClient.java b/detection/src/main/java/com/njcn/gather/detection/util/socket/cilent/NettyClient.java index 455fa41a..33a6577f 100644 --- a/detection/src/main/java/com/njcn/gather/detection/util/socket/cilent/NettyClient.java +++ b/detection/src/main/java/com/njcn/gather/detection/util/socket/cilent/NettyClient.java @@ -47,7 +47,7 @@ public class NettyClient { //空闲状态的handler // 添加LineBasedFrameDecoder来按行分割数据 .addLast(new LineBasedFrameDecoder(10240)) - .addLast(new IdleStateHandler(10, 0, 0, TimeUnit.SECONDS)) + .addLast(new IdleStateHandler(0, 10, 0, TimeUnit.SECONDS)) .addLast(new StringDecoder(CharsetUtil.UTF_8)) .addLast(new StringEncoder(CharsetUtil.UTF_8)) .addLast(handler); diff --git a/detection/src/main/java/com/njcn/gather/detection/util/socket/cilent/NettySourceClientHandler.java b/detection/src/main/java/com/njcn/gather/detection/util/socket/cilent/NettySourceClientHandler.java index d43a1581..bb8c488f 100644 --- a/detection/src/main/java/com/njcn/gather/detection/util/socket/cilent/NettySourceClientHandler.java +++ b/detection/src/main/java/com/njcn/gather/detection/util/socket/cilent/NettySourceClientHandler.java @@ -93,7 +93,7 @@ public class NettySourceClientHandler extends SimpleChannelInboundHandler