use of cz.mzk.recordmanager.server.solr.SolrIndexingExceptionHandler.Action in project RecordManager2 by moravianlibrary.
the class SolrServerFacadeImpl method fallbackIndex.
private void fallbackIndex(Collection<SolrInputDocument> documents, int commitWithinMs) throws SolrServerException {
for (SolrInputDocument document : documents) {
boolean carryOn = true;
while (carryOn) {
try {
server.add(document, commitWithinMs);
exceptionHandler.ok();
carryOn = false;
} catch (SolrException | SolrServerException | IOException ex) {
Action action = exceptionHandler.handle(ex, documents);
carryOn = action == Action.RETRY;
}
}
}
}
Aggregations