Skip to content
Snippets Groups Projects
Commit 0090b189 authored by apriestman's avatar apriestman
Browse files

Use original start time if no pipelines are running

parent 2b034c65
Branches
Tags
No related merge requests found
...@@ -1484,16 +1484,17 @@ IngestJobProgressSnapshot getIngestJobProgressSnapshot(boolean includeIngestTask ...@@ -1484,16 +1484,17 @@ IngestJobProgressSnapshot getIngestJobProgressSnapshot(boolean includeIngestTask
boolean fileIngestRunning = false; boolean fileIngestRunning = false;
Date fileIngestStartTime = null; Date fileIngestStartTime = null;
Optional<List<FileIngestPipeline>> fileIngestPipelines = getCurrentFileIngestPipelines(); Optional<List<FileIngestPipeline>> fileIngestPipelines = getCurrentFileIngestPipelines();
if (fileIngestPipelines.isPresent()) { if (!fileIngestPipelines.isPresent()) {
for (FileIngestPipeline pipeline : fileIngestPipelines.get()) { // If there are no currently running pipelines, use the original set.
fileIngestPipelines = Optional.of(ingestModuleTiers.get(0).getFileIngestPipelines());
if (pipeline.isRunning()) { }
fileIngestRunning = true; for (FileIngestPipeline pipeline : fileIngestPipelines.get()) {
} if (pipeline.isRunning()) {
Date pipelineStartTime = pipeline.getStartTime(); fileIngestRunning = true;
if (pipelineStartTime != null && (fileIngestStartTime == null || pipelineStartTime.before(fileIngestStartTime))) { }
fileIngestStartTime = pipelineStartTime; Date pipelineStartTime = pipeline.getStartTime();
} if (pipelineStartTime != null && (fileIngestStartTime == null || pipelineStartTime.before(fileIngestStartTime))) {
fileIngestStartTime = pipelineStartTime;
} }
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment