refresher.init();
BlurFilterCache filterCache = getFilterCache(configuration);
BlurIndexWarmup indexWarmup = getIndexWarmup(configuration);
final DistributedIndexServer indexServer = new DistributedIndexServer();
indexServer.setBlockCacheDirectoryFactory(blockCacheDirectoryFactory);
indexServer.setClusterStatus(clusterStatus);
indexServer.setClusterName(configuration.get(BLUR_CLUSTER_NAME, BLUR_CLUSTER));
indexServer.setConfiguration(config);
indexServer.setNodeName(nodeName);
indexServer.setShardOpenerThreadCount(configuration.getInt(BLUR_SHARD_OPENER_THREAD_COUNT, 16));
indexServer.setWarmupThreads(configuration.getInt(BLUR_SHARD_WARMUP_THREAD_COUNT, 16));
indexServer.setInternalSearchThreads(configuration.getInt(BLUR_SHARD_INTERNAL_SEARCH_THREAD_COUNT, 16));
indexServer.setZookeeper(zooKeeper);
indexServer.setFilterCache(filterCache);
indexServer.setSafeModeDelay(configuration.getLong(BLUR_SHARD_SAFEMODEDELAY, 60000));
indexServer.setWarmup(indexWarmup);
indexServer.init();
final IndexManager indexManager = new IndexManager();
indexManager.setIndexServer(indexServer);
indexManager.setMaxClauseCount(configuration.getInt(BLUR_MAX_CLAUSE_COUNT, 1024));
indexManager.setThreadCount(configuration.getInt(BLUR_INDEXMANAGER_SEARCH_THREAD_COUNT, 32));