errose28 commented on code in PR #7490:
URL: https://github.com/apache/ozone/pull/7490#discussion_r1913842030
##########
hadoop-hdds/container-service/src/main/java/org/apache/hadoop/ozone/container/keyvalue/KeyValueContainerCheck.java:
##########
@@ -379,12 +378,13 @@ private List<ContainerScanError> scanBlock(DBHandle db,
File dbFile, BlockData b
// So, we need to make sure, chunk length > 0, before declaring
// the missing chunk file.
if (!block.getChunks().isEmpty() &&
block.getChunks().get(0).getLen() > 0) {
- ContainerScanError error = new
ContainerScanError(FailureType.MISSING_CHUNK_FILE,
+ ContainerScanError error = new
ContainerScanError(FailureType.MISSING_DATA_FILE,
new File(containerDataFromDisk.getChunksPath()), new
IOException("Missing chunk file " +
chunkFile.getAbsolutePath()));
blockErrors.add(error);
}
} else if (chunk.getChecksumData().getType() !=
ContainerProtos.ChecksumType.NONE) {
+ currentTree.addBlock(block.getBlockID().getLocalID());
Review Comment:
The [truncated
block](https://github.com/apache/ozone/blob/a3401a93835e59193feedf0f3528dd9cd398c1a5/hadoop-hdds/container-service/src/test/java/org/apache/hadoop/ozone/container/keyvalue/TestContainerCorruptions.java#L113)
failure is currently testing this path.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]