mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-08-07 17:49:17 +00:00
Merged HEAD-BUG-FIX (5.0/Cloud) to HEAD (5.0/Cloud)
77193: Merged PLATFORM1 (5.0/Cloud) to HEAD-BUG-FIX (5.0/Cloud) 74588: Revert of R 74318 ACE-1996 git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@78049 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
@@ -113,18 +113,20 @@ public class DictionaryLoadDAOTest
|
||||
|
||||
private void initDictionaryCaches(DictionaryDAOImpl dictionaryDAO, TenantService tenantService) throws Exception
|
||||
{
|
||||
CompiledModelsCache compiledModelsCache = new CompiledModelsCache();
|
||||
compiledModelsCache.setDictionaryDAO(dictionaryDAO);
|
||||
compiledModelsCache.setTenantService(tenantService);
|
||||
compiledModelsCache.setRegistry(new DefaultAsynchronouslyRefreshedCacheRegistry());
|
||||
TraceableThreadFactory threadFactory = new TraceableThreadFactory();
|
||||
threadFactory.setThreadDaemon(true);
|
||||
threadFactory.setThreadPriority(Thread.NORM_PRIORITY);
|
||||
dictionaryDAO.setDictionaryRegistryCache(new MemoryCache<String, DictionaryRegistry>());
|
||||
|
||||
ThreadPoolExecutor threadPoolExecutor = new DynamicallySizedThreadPoolExecutor(20, 20, 90, TimeUnit.SECONDS, new LinkedBlockingQueue<Runnable>(), threadFactory,
|
||||
new ThreadPoolExecutor.CallerRunsPolicy());
|
||||
compiledModelsCache.setThreadPoolExecutor(threadPoolExecutor);
|
||||
dictionaryDAO.setDictionaryRegistryCache(compiledModelsCache);
|
||||
// CompiledModelsCache compiledModelsCache = new CompiledModelsCache();
|
||||
// compiledModelsCache.setDictionaryDAO(dictionaryDAO);
|
||||
// compiledModelsCache.setTenantService(tenantService);
|
||||
// compiledModelsCache.setRegistry(new DefaultAsynchronouslyRefreshedCacheRegistry());
|
||||
// TraceableThreadFactory threadFactory = new TraceableThreadFactory();
|
||||
// threadFactory.setThreadDaemon(true);
|
||||
// threadFactory.setThreadPriority(Thread.NORM_PRIORITY);
|
||||
//
|
||||
// ThreadPoolExecutor threadPoolExecutor = new DynamicallySizedThreadPoolExecutor(20, 20, 90, TimeUnit.SECONDS, new LinkedBlockingQueue<Runnable>(), threadFactory,
|
||||
// new ThreadPoolExecutor.CallerRunsPolicy());
|
||||
// compiledModelsCache.setThreadPoolExecutor(threadPoolExecutor);
|
||||
// dictionaryDAO.setDictionaryRegistryCache(compiledModelsCache);
|
||||
dictionaryDAO.init();
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user