Submitted by Ruediger Pluem. PR#44595
authorjfclere <jfclere@13f79535-47bb-0310-9956-ffa450edef68>
Mon, 7 Apr 2008 09:29:41 +0000 (09:29 +0000)
committerjfclere <jfclere@13f79535-47bb-0310-9956-ffa450edef68>
Mon, 7 Apr 2008 09:29:41 +0000 (09:29 +0000)
git-svn-id: https://svn.apache.org/repos/asf/tomcat/trunk@645428 13f79535-47bb-0310-9956-ffa450edef68

java/org/apache/catalina/core/StandardThreadExecutor.java

index 49f06c2..bf6fa4e 100644 (file)
@@ -193,6 +193,10 @@ public class StandardThreadExecutor implements Executor {
         return (executor != null) ? executor.getPoolSize() : 0;
     }
 
+    public int getQueueSize() {
+        return (executor != null) ? executor.getQueue().size() : -1;
+    }
+
     // ---------------------------------------------- TaskQueue Inner Class
     class TaskQueue extends LinkedBlockingQueue<Runnable> {
         ThreadPoolExecutor parent = null;
@@ -254,4 +258,4 @@ public class StandardThreadExecutor implements Executor {
     }
 
 
-}
\ No newline at end of file
+}