(index-creation) Print whether full or prio is created
Previous state of saying reverse index for both was pretty confusing.
This commit is contained in:
parent
95f74c5ea7
commit
313cc2965c
@ -38,7 +38,9 @@ public class ReverseIndexConstructor {
|
||||
this.tmpDir = tmpDir;
|
||||
}
|
||||
|
||||
public void createReverseIndex(ProcessHeartbeat processHeartbeat, Path sourceBaseDir) throws IOException
|
||||
public void createReverseIndex(ProcessHeartbeat processHeartbeat,
|
||||
String processName,
|
||||
Path sourceBaseDir) throws IOException
|
||||
{
|
||||
var inputs = IndexJournalFileNames.findJournalFiles(sourceBaseDir);
|
||||
if (inputs.isEmpty()) {
|
||||
@ -46,7 +48,7 @@ public class ReverseIndexConstructor {
|
||||
return;
|
||||
}
|
||||
|
||||
try (var heartbeat = processHeartbeat.createProcessTaskHeartbeat(CreateReverseIndexSteps.class, "createReverseIndex")) {
|
||||
try (var heartbeat = processHeartbeat.createProcessTaskHeartbeat(CreateReverseIndexSteps.class, processName)) {
|
||||
|
||||
heartbeat.progress(CreateReverseIndexSteps.CONSTRUCT);
|
||||
|
||||
|
@ -111,7 +111,9 @@ public class IndexConstructorMain {
|
||||
new ReverseIndexConstructor(outputFileDocs, outputFileWords,
|
||||
IndexJournalReader::singleFile,
|
||||
this::addRankToIdEncoding, tmpDir)
|
||||
.createReverseIndex(heartbeat, workDir);
|
||||
.createReverseIndex(heartbeat,
|
||||
"createReverseIndexFull",
|
||||
workDir);
|
||||
|
||||
}
|
||||
|
||||
@ -129,7 +131,9 @@ public class IndexConstructorMain {
|
||||
new ReverseIndexConstructor(outputFileDocs, outputFileWords,
|
||||
(path) -> IndexJournalReader.singleFile(path).filtering(wordMetaFilter),
|
||||
this::addRankToIdEncoding, tmpDir)
|
||||
.createReverseIndex(heartbeat, workDir);
|
||||
.createReverseIndex(heartbeat,
|
||||
"createReverseIndexPrio",
|
||||
workDir);
|
||||
}
|
||||
|
||||
private static LongPredicate getPriorityIndexWordMetaFilter() {
|
||||
|
@ -242,7 +242,7 @@ public class IndexQueryServiceIntegrationSmokeTest {
|
||||
if (!Files.isDirectory(tmpDir)) Files.createDirectories(tmpDir);
|
||||
|
||||
new ReverseIndexConstructor(outputFileDocs, outputFileWords, IndexJournalReader::singleFile, DocIdRewriter.identity(), tmpDir)
|
||||
.createReverseIndex(new FakeProcessHeartbeat(), workDir);
|
||||
.createReverseIndex(new FakeProcessHeartbeat(), "name", workDir);
|
||||
}
|
||||
|
||||
private void createPrioReverseIndex() throws SQLException, IOException {
|
||||
@ -255,7 +255,7 @@ public class IndexQueryServiceIntegrationSmokeTest {
|
||||
if (!Files.isDirectory(tmpDir)) Files.createDirectories(tmpDir);
|
||||
|
||||
new ReverseIndexConstructor(outputFileDocs, outputFileWords, IndexJournalReader::singleFile, DocIdRewriter.identity(), tmpDir)
|
||||
.createReverseIndex(new FakeProcessHeartbeat(), workDir);
|
||||
.createReverseIndex(new FakeProcessHeartbeat(), "name", workDir);
|
||||
}
|
||||
|
||||
private void createForwardIndex() throws SQLException, IOException {
|
||||
|
@ -495,7 +495,7 @@ public class IndexQueryServiceIntegrationTest {
|
||||
if (!Files.isDirectory(tmpDir)) Files.createDirectories(tmpDir);
|
||||
|
||||
new ReverseIndexConstructor(outputFileDocs, outputFileWords, IndexJournalReader::singleFile, DocIdRewriter.identity(), tmpDir)
|
||||
.createReverseIndex(new FakeProcessHeartbeat(), workDir);
|
||||
.createReverseIndex(new FakeProcessHeartbeat(), "name", workDir);
|
||||
}
|
||||
|
||||
private void createPrioReverseIndex() throws SQLException, IOException {
|
||||
@ -508,7 +508,7 @@ public class IndexQueryServiceIntegrationTest {
|
||||
if (!Files.isDirectory(tmpDir)) Files.createDirectories(tmpDir);
|
||||
|
||||
new ReverseIndexConstructor(outputFileDocs, outputFileWords, IndexJournalReader::singleFile, DocIdRewriter.identity(), tmpDir)
|
||||
.createReverseIndex(new FakeProcessHeartbeat(), workDir);
|
||||
.createReverseIndex(new FakeProcessHeartbeat(), "name", workDir);
|
||||
}
|
||||
|
||||
private void createForwardIndex() throws SQLException, IOException {
|
||||
|
Loading…
Reference in New Issue
Block a user