cpoerschke commented on code in PR #2508: URL: https://github.com/apache/solr/pull/2508#discussion_r1631463199
########## solr/core/src/java/org/apache/solr/core/CoreContainer.java: ########## @@ -444,7 +444,7 @@ public CoreContainer(NodeConfig config, CoresLocator locator, boolean asyncSolrC this.allowListUrlChecker = AllowListUrlChecker.create(config); this.collectorExecutor = - ExecutorUtil.newMDCAwareCachedThreadPool( + ExecutorUtil.newMDCAwareFixedThreadPool( cfg.getIndexSearcherExecutorThreads(), // thread count cfg.getIndexSearcherExecutorThreads() * 1000, // queue size new SolrNamedThreadFactory("searcherCollector")); Review Comment: https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/util/concurrent/ThreadPoolExecutor.html documentation says _"If corePoolSize or more threads are running, the Executor always prefers queuing a request rather than adding a new thread."_ and _"If a request cannot be queued, a new thread is created unless this would exceed maximumPoolSize, in which case, the task will be rejected."_ I think this means that if the queue size is generous (relative to the use of the thread pool) then queuing will always be possible and search will remain single-threaded. -- 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: issues-unsubscr...@solr.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: issues-unsubscr...@solr.apache.org For additional commands, e-mail: issues-h...@solr.apache.org