TextAnalysisWorkflowOperationHandler can leave the workspace populated with files even though it failed

Steps to reproduce

The workspace doesn't get cleaned up of temporary files if the jobs are not successful:

// Wait for all jobs to be finished
if (!waitForStatus(jobs.values().toArray(new Job[jobs.size()])).isSuccess()) {
throw new WorkflowOperationException("Text extraction failed on images from " + sourceTrack);
}

// Remove images that were created for text extraction
logger.debug("Removing temporary images");
for (Attachment image : images) {
workspace.delete(image.getURI());
}

TextAnalysisWorkflowOperationHandler.extractVideoText()

Status

Assignee

Unassigned

Reporter

Christopher Brooks

Severity

Incorrectly Functioning With Workaround

Tags (folksonomy)

Components

Affects versions

Priority

Major
Configure