cziegeler commented on code in PR #6:
URL: 
https://github.com/apache/sling-org-apache-sling-commons-scheduler/pull/6#discussion_r1868638502


##########
src/main/java/org/apache/sling/commons/scheduler/impl/QuartzThreadPool.java:
##########
@@ -21,13 +21,18 @@
 public class QuartzThreadPool implements org.quartz.spi.ThreadPool {
 
     /** Our executor thread pool */
-    private ThreadPool executor;
+    private volatile ThreadPool executor;
+
+    private final Object lock = new Object();
+
+    private volatile int counter;
 
     /**
      * Create a new wrapper implementation for Quartz.
      */
     public QuartzThreadPool(final ThreadPool executor) {
         this.executor = executor;
+        this.counter = executor.getConfiguration().getMaxPoolSize();

Review Comment:
   Looking at the code in Sling commons thread pool, it seems it can :( we 
should maybe just throw an exception in this case. And eventually fix commons 
thread pool to not return negative values (we might need to check other config 
values as well)



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to