Package org.apache.solr.common.util
Class ExecutorUtil
- java.lang.Object
- 
- org.apache.solr.common.util.ExecutorUtil
 
- 
 public class ExecutorUtil extends Object 
- 
- 
Nested Class SummaryNested Classes Modifier and Type Class Description static interfaceExecutorUtil.InheritableThreadLocalProviderAny class which wants to carry forward the threadlocal values to the threads run by threadpools must implement this interface and the implementation should be registered herestatic classExecutorUtil.MDCAwareThreadPoolExecutor
 - 
Constructor SummaryConstructors Constructor Description ExecutorUtil()
 - 
Method Summary
 
- 
- 
- 
Method Detail- 
resetThreadLocalProviderspublic static void resetThreadLocalProviders() Resets everything added viaaddThreadLocalProvider(InheritableThreadLocalProvider). Useful to call at the beginning of tests.
 - 
addThreadLocalProviderpublic static void addThreadLocalProvider(ExecutorUtil.InheritableThreadLocalProvider provider) 
 - 
shutdownAndAwaitTerminationpublic static void shutdownAndAwaitTermination(ExecutorService pool) 
 - 
shutdownNowAndAwaitTerminationpublic static void shutdownNowAndAwaitTermination(ExecutorService pool) 
 - 
awaitTerminationpublic static void awaitTermination(ExecutorService pool) 
 - 
newMDCAwareFixedThreadPoolpublic static ExecutorService newMDCAwareFixedThreadPool(int nThreads, ThreadFactory threadFactory) 
 - 
newMDCAwareSingleThreadExecutorpublic static ExecutorService newMDCAwareSingleThreadExecutor(ThreadFactory threadFactory) 
 - 
newMDCAwareCachedThreadPoolpublic static ExecutorService newMDCAwareCachedThreadPool(String name) Create a cached thread pool using a named thread factory
 - 
newMDCAwareCachedThreadPoolpublic static ExecutorService newMDCAwareCachedThreadPool(ThreadFactory threadFactory) 
 - 
newMDCAwareCachedThreadPoolpublic static ExecutorService newMDCAwareCachedThreadPool(int maxThreads, ThreadFactory threadFactory) 
 - 
isSolrServerThreadpublic static boolean isSolrServerThread() 
 - 
setServerThreadFlagpublic static void setServerThreadFlag(Boolean flag) 
 
- 
 
-