Check for ingest complete periodically in case the event was missed

This commit is contained in:
apriestman 2022-01-06 18:21:38 -05:00
parent 0090b189e9
commit e43e1afd8d

View File

@ -2814,10 +2814,13 @@ final class AutoIngestManager extends Observable implements PropertyChangeListen
/* /*
* Block until notified by the ingest job event listener * Block until notified by the ingest job event listener
* or until interrupted because auto ingest is shutting * or until interrupted because auto ingest is shutting
* down. * down. For very small jobs, it is possible that ingest has
* completed by the time we get here, so check periodically
* in case the event was missed.
*/ */
ingestLock.wait(); while (IngestManager.getInstance().isIngestRunning()) {
sysLogger.log(Level.INFO, "Finished ingest modules analysis for {0} ", manifestPath); ingestLock.wait(300000); // Check every five minutes
}
IngestJob.ProgressSnapshot jobSnapshot = ingestJob.getSnapshot(); IngestJob.ProgressSnapshot jobSnapshot = ingestJob.getSnapshot();
IngestJob.ProgressSnapshot.DataSourceProcessingSnapshot snapshot = jobSnapshot.getDataSourceProcessingSnapshot(); IngestJob.ProgressSnapshot.DataSourceProcessingSnapshot snapshot = jobSnapshot.getDataSourceProcessingSnapshot();
AutoIngestJobLogger nestedJobLogger = new AutoIngestJobLogger(manifestPath, snapshot.getDataSource(), caseDirectoryPath); AutoIngestJobLogger nestedJobLogger = new AutoIngestJobLogger(manifestPath, snapshot.getDataSource(), caseDirectoryPath);