From 96b9fc1be4054a6df8539c4ae4523ae61d148480 Mon Sep 17 00:00:00 2001 From: yifeizhuang Date: Thu, 25 Aug 2022 10:47:38 -0700 Subject: [PATCH] fix --- .../main/java/io/grpc/internal/MaxConnectionIdleManager.java | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/core/src/main/java/io/grpc/internal/MaxConnectionIdleManager.java b/core/src/main/java/io/grpc/internal/MaxConnectionIdleManager.java index a6e2a13913..4d4a36dda0 100644 --- a/core/src/main/java/io/grpc/internal/MaxConnectionIdleManager.java +++ b/core/src/main/java/io/grpc/internal/MaxConnectionIdleManager.java @@ -20,13 +20,12 @@ import com.google.common.annotations.VisibleForTesting; import java.util.concurrent.ScheduledExecutorService; import java.util.concurrent.ScheduledFuture; import java.util.concurrent.TimeUnit; - import javax.annotation.CheckForNull; /** * Monitors connection idle time; shutdowns the connection if the max connection idle is reached. */ -public class MaxConnectionIdleManager { +public final class MaxConnectionIdleManager { private static final Ticker systemTicker = new Ticker() { @Override public long nanoTime() { @@ -61,7 +60,6 @@ public class MaxConnectionIdleManager { * @param closeJob Closes the connection by sending GO_AWAY with status code NO_ERROR and ASCII * debug data max_idle and then doing the graceful connection termination. */ - @VisibleForTesting public void start(final Runnable closeJob, final ScheduledExecutorService scheduler) { this.scheduler = scheduler; nextIdleMonitorTime = ticker.nanoTime() + maxConnectionIdleInNanos;