Skip to content
Permalink
Browse files

0003748: Batch was not complete

  • Loading branch information...
erilong committed Jan 11, 2019
1 parent 517dfdd commit 662c068993acfbae2b999f344b15b9801707c2e5
@@ -55,6 +55,7 @@
import java.util.concurrent.TimeoutException;
import java.util.regex.Matcher;
import java.util.regex.Pattern;
import java.util.zip.ZipException;

import org.apache.commons.io.FileUtils;
import org.apache.commons.lang.StringUtils;
@@ -846,6 +847,12 @@ public boolean extractOnlyOutgoingBatch(String nodeId, long batchId, Writer writ
log.info("Extract of batch {} was interrupted", currentBatch);
} else if (e instanceof StagingLowFreeSpace) {
log.error("Extract is disabled because disk is almost full: {}", e.getMessage());
} else if (e.getCause() instanceof ZipException) {
log.info("The batch {} appears corrupt in staging, so removing it. ({})", currentBatch.getNodeBatchId(), e.getMessage());
IStagedResource extractedBatch = getStagedResource(currentBatch);
if (extractedBatch != null) {
extractedBatch.delete();
}
} else {
log.error("Failed to extract batch {}", currentBatch, e);
}

0 comments on commit 662c068

Please sign in to comment.
You can’t perform that action at this time.