From 69b1ccdfeee1290b789d4033d9d7048fb437b9c0 Mon Sep 17 00:00:00 2001 From: yarnom Date: Tue, 28 Oct 2025 15:34:47 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E9=99=8D=E4=BD=8Elogger=E7=AD=89?= =?UTF-8?q?=E7=BA=A7?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../sideslope/rtkcluster/RtkClusterService.java | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/sec-beidou-rtcm/src/main/java/com/imdroid/sideslope/rtkcluster/RtkClusterService.java b/sec-beidou-rtcm/src/main/java/com/imdroid/sideslope/rtkcluster/RtkClusterService.java index afcd96dc..6e4b833d 100644 --- a/sec-beidou-rtcm/src/main/java/com/imdroid/sideslope/rtkcluster/RtkClusterService.java +++ b/sec-beidou-rtcm/src/main/java/com/imdroid/sideslope/rtkcluster/RtkClusterService.java @@ -216,13 +216,13 @@ public class RtkClusterService implements ApplicationRunner { // OUT connection (NMEA etc.) closeQuietly(outConn); outConn = s; - LOGGER.info("Endpoint {} OUT connected", port); + LOGGER.debug("Endpoint {} OUT connected", port); pumpOut(outConn, probe, n); } else { // IN connection (RTCM sink) closeQuietly(inConn); inConn = s; - LOGGER.info("Endpoint {} IN connected", port); + LOGGER.debug("Endpoint {} IN connected", port); } } catch (IOException e) { LOGGER.warn("classifyConnection error: {}", e.getMessage()); @@ -247,16 +247,16 @@ public class RtkClusterService implements ApplicationRunner { int read; // deliver first classified bytes if any if (firstLen > 0) { - String preview = new String(firstBuf, 0, Math.min(firstLen, 64), StandardCharsets.US_ASCII).replaceAll("\n", "\\n"); - LOGGER.info("[OUT:{}] {} bytes: {}...", port, firstLen, preview); + String preview = new String(firstBuf, 0, firstLen, StandardCharsets.US_ASCII).replaceAll("\n", "\\n"); + LOGGER.info("[OUT:{}] {}", port, preview); } while ((read = in.read(buf)) != -1) { // For now, just log a short preview - String preview = new String(buf, 0, Math.min(read, 64), StandardCharsets.US_ASCII).replaceAll("\n", "\\n"); - LOGGER.info("[OUT:{}] {} bytes: {}...", port, read, preview); + String preview = new String(buf, 0, read, StandardCharsets.US_ASCII).replaceAll("\n", "\\n"); + LOGGER.info("[OUT:{}] {}", port, preview); } } catch (IOException e) { - LOGGER.info("OUT connection closed on {}: {}", port, e.getMessage()); + LOGGER.debug("OUT connection closed on {}: {}", port, e.getMessage()); } finally { if (outConn == s) outConn = null; closeQuietly(s);