Changed downloadStartMarker in OmniSegmentLoader to simply use its .delete() method

This commit is contained in:
Charles Allen 2014-11-13 08:56:11 -08:00 committed by Xavier Léauté
parent 8cc48fc730
commit 3cdcf8736f
1 changed files with 2 additions and 4 deletions

View File

@ -138,13 +138,11 @@ public class OmniSegmentLoader implements SegmentLoader
getPuller(segment.getLoadSpec()).getSegmentFiles(segment, storageDir);
try {
FileUtils.deleteDirectory(downloadStartMarker);
}
catch (Exception e) {
if (!downloadStartMarker.delete()) {
throw new SegmentLoadingException("Unable to remove marker file for [%s]", storageDir);
}
loc.addSegment(segment);
retVal = storageDir;