This is an automated email from the ASF dual-hosted git repository.

markt pushed a commit to branch 10.1.x
in repository https://gitbox.apache.org/repos/asf/tomcat.git

commit d22fc4efaa0d8831b730ca573d3406f82c780be6
Author: Matthew Painter <mj...@users.noreply.github.com>
AuthorDate: Thu Apr 27 14:45:13 2023 +0100

    Don't allow idle threads to live forever
---
 java/org/apache/tomcat/websocket/AsyncChannelGroupUtil.java | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/java/org/apache/tomcat/websocket/AsyncChannelGroupUtil.java 
b/java/org/apache/tomcat/websocket/AsyncChannelGroupUtil.java
index f2510a84b7..492fdc53bf 100644
--- a/java/org/apache/tomcat/websocket/AsyncChannelGroupUtil.java
+++ b/java/org/apache/tomcat/websocket/AsyncChannelGroupUtil.java
@@ -81,8 +81,8 @@ public class AsyncChannelGroupUtil {
             // These are the same settings as the default
             // AsynchronousChannelGroup
             int initialSize = Runtime.getRuntime().availableProcessors();
-            ExecutorService executorService = new ThreadPoolExecutor(0, 
Integer.MAX_VALUE, Long.MAX_VALUE,
-                    TimeUnit.MILLISECONDS, new SynchronousQueue<>(), new 
AsyncIOThreadFactory());
+            ExecutorService executorService = new ThreadPoolExecutor(0, 
Integer.MAX_VALUE, 60,
+                    TimeUnit.SECONDS, new SynchronousQueue<>(), new 
AsyncIOThreadFactory());
 
             try {
                 return 
AsynchronousChannelGroup.withCachedThreadPool(executorService, initialSize);


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
For additional commands, e-mail: dev-h...@tomcat.apache.org

Reply via email to