Merge pull request #8334 from atmire/w2p-88835_try-catch-IndexFactoryImpl

Catch exception when writing document to solr core and log it
This commit is contained in:
Tim Donohue
2022-06-10 08:53:09 -05:00
committed by GitHub

View File

@@ -73,7 +73,12 @@ public abstract class IndexFactoryImpl<T extends IndexableObject, S> implements
@Override
public void writeDocument(Context context, T indexableObject, SolrInputDocument solrInputDocument)
throws SQLException, IOException, SolrServerException {
writeDocument(solrInputDocument, null);
try {
writeDocument(solrInputDocument, null);
} catch (Exception e) {
log.error("Error occurred while writing SOLR document for {} object {}",
indexableObject.getType(), indexableObject.getID(), e);
}
}
/**