new PerfLogger(LoggerFactory.getLogger(LuceneIndexEditorContext.class.getName() + ".perf"));
static IndexWriterConfig getIndexWriterConfig(IndexDefinition definition, boolean remoteDir) {
Thread thread = Thread.currentThread();
ClassLoader loader = thread.getContextClassLoader();
thread.setContextClassLoader(IndexWriterConfig.class.getClassLoader());
<BUG>try {
IndexWriterConfig config = new IndexWriterConfig(VERSION, definition.getAnalyzer());
</BUG>
if (remoteDir) {
config.setMergeScheduler(new SerialMergeScheduler());

new PerfLogger(LoggerFactory.getLogger(LuceneIndexEditorContext.class.getName() + ".perf"));
static IndexWriterConfig getIndexWriterConfig(IndexDefinition definition, boolean remoteDir) {
Thread thread = Thread.currentThread();
ClassLoader loader = thread.getContextClassLoader();
thread.setContextClassLoader(IndexWriterConfig.class.getClassLoader());
try {
Analyzer definitionAnalyzer = definition.getAnalyzer();
Map<String, Analyzer> analyzers = new HashMap<String, Analyzer>();
analyzers.put(FieldNames.SPELLCHECK, new ShingleAnalyzerWrapper(LuceneIndexConstants.ANALYZER, 3));
Analyzer analyzer = new PerFieldAnalyzerWrapper(definitionAnalyzer, analyzers);
IndexWriterConfig config = new IndexWriterConfig(VERSION, analyzer);
if (remoteDir) {
config.setMergeScheduler(new SerialMergeScheduler());
