Directory dir = getRunData().getDirectory();
Analyzer analyzer = getRunData().getAnalyzer();
IndexWriter writer = new IndexWriter(dir, analyzer, false);
Config config = getRunData().getConfig();
boolean cmpnd = config.get("compound",true);
int mrgf = config.get("merge.factor",10);
int mxbf = config.get("max.buffered",10);
// must update params for newly opened writer
writer.setMaxBufferedDocs(mxbf);
writer.setMergeFactor(mrgf);
writer.setUseCompoundFile(cmpnd); // this one redundant?
getRunData().setIndexWriter(writer);
return 1;