Factor out batch indexing logic into a ChangeBatchIndexer
Change-Id: Ief166fadc61f76a5f4ffdb879322e9883040bdd6
This commit is contained in:
@@ -325,13 +325,14 @@ class SolrChangeIndex implements ChangeIndex, LifecycleListener {
|
||||
}
|
||||
|
||||
@Override
|
||||
public void markReady() throws IOException {
|
||||
public void markReady(boolean ready) throws IOException {
|
||||
// TODO Move the schema version information to a special meta-document
|
||||
FileBasedConfig cfg = new FileBasedConfig(
|
||||
solrIndexConfig(sitePaths),
|
||||
FS.detect());
|
||||
for (Map.Entry<String, Integer> e : SCHEMA_VERSIONS.entrySet()) {
|
||||
cfg.setInt("index", e.getKey(), "schemaVersion", e.getValue());
|
||||
cfg.setInt("index", e.getKey(), "schemaVersion",
|
||||
ready ? e.getValue() : -1);
|
||||
}
|
||||
cfg.save();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user