mirror of https://github.com/apache/lucene.git
SOLR-7280: refactored to incorporate Mike's suggestions. Default thread count for cloud is limited to 8 now. In our internal teting 8 has given us the best stability during restarts
This commit is contained in:
parent
fcd2cc57d5
commit
89a1fe661e
|
@ -81,8 +81,6 @@ import static org.apache.solr.common.params.CommonParams.CONFIGSETS_HANDLER_PATH
|
||||||
import static org.apache.solr.common.params.CommonParams.CORES_HANDLER_PATH;
|
import static org.apache.solr.common.params.CommonParams.CORES_HANDLER_PATH;
|
||||||
import static org.apache.solr.common.params.CommonParams.INFO_HANDLER_PATH;
|
import static org.apache.solr.common.params.CommonParams.INFO_HANDLER_PATH;
|
||||||
import static org.apache.solr.common.params.CommonParams.ZK_PATH;
|
import static org.apache.solr.common.params.CommonParams.ZK_PATH;
|
||||||
import static org.apache.solr.core.NodeConfig.NodeConfigBuilder.DEFAULT_CORE_LOAD_THREADS;
|
|
||||||
import static org.apache.solr.core.NodeConfig.NodeConfigBuilder.DEFAULT_CORE_LOAD_THREADS_IN_CLOUD;
|
|
||||||
import static org.apache.solr.security.AuthenticationPlugin.AUTHENTICATION_PLUGIN_PROP;
|
import static org.apache.solr.security.AuthenticationPlugin.AUTHENTICATION_PLUGIN_PROP;
|
||||||
|
|
||||||
|
|
||||||
|
@ -466,7 +464,7 @@ public class CoreContainer {
|
||||||
|
|
||||||
// setup executor to load cores in parallel
|
// setup executor to load cores in parallel
|
||||||
ExecutorService coreLoadExecutor = ExecutorUtil.newMDCAwareFixedThreadPool(
|
ExecutorService coreLoadExecutor = ExecutorUtil.newMDCAwareFixedThreadPool(
|
||||||
cfg.getCoreLoadThreadCount(isZooKeeperAware() ? DEFAULT_CORE_LOAD_THREADS_IN_CLOUD : DEFAULT_CORE_LOAD_THREADS),
|
cfg.getCoreLoadThreadCount(isZooKeeperAware()),
|
||||||
new DefaultSolrThreadFactory("coreLoadExecutor") );
|
new DefaultSolrThreadFactory("coreLoadExecutor") );
|
||||||
final List<Future<SolrCore>> futures = new ArrayList<>();
|
final List<Future<SolrCore>> futures = new ArrayList<>();
|
||||||
try {
|
try {
|
||||||
|
|
Loading…
Reference in New Issue