Encapsulate lucene index dir name structure inside LuceneVersionManager.getDir

Instead of expecting every caller to know the folder name structure
<name>_<version> and care to pass the underscore as part of the prefix
parameter, let the getDir method insert the underscore.

Change-Id: I702450b67d78af0e0c5d2808908aaacc27d59586
This commit is contained in:
Saša Živkov
2017-05-26 11:43:11 +02:00
committed by David Pursehouse
parent bee7de7ee4
commit b37af76beb
4 changed files with 7 additions and 7 deletions

View File

@@ -80,7 +80,7 @@ public class LuceneGroupIndex extends AbstractLuceneIndex<AccountGroup.UUID, Acc
if (LuceneIndexModule.isInMemoryTest(cfg)) {
return new RAMDirectory();
}
Path indexDir = LuceneVersionManager.getDir(sitePaths, GROUPS + "_", schema);
Path indexDir = LuceneVersionManager.getDir(sitePaths, GROUPS, schema);
return FSDirectory.open(indexDir);
}