errose28 commented on code in PR #8881:
URL: https://github.com/apache/ozone/pull/8881#discussion_r2255429081
##########
hadoop-hdds/container-service/src/main/java/org/apache/hadoop/ozone/container/keyvalue/KeyValueHandler.java:
##########
@@ -760,14 +761,33 @@ ContainerCommandResponseProto
handleGetContainerChecksumInfo(
try {
checksumTree = checksumManager.getContainerChecksumInfo(containerData);
} catch (IOException ex) {
- // For file not found or other inability to read the file, return an
error to the client.
- LOG.error("Error occurred when reading checksum file for container {}",
containerData.getContainerID(), ex);
- return ContainerCommandResponseProto.newBuilder()
- .setCmdType(request.getCmdType())
- .setTraceID(request.getTraceID())
- .setResult(IO_EXCEPTION)
- .setMessage(ex.getMessage())
- .build();
+ // Only build from metadata if the file doesn't exist
+ if (ex instanceof FileNotFoundException) {
+ try {
+ LOG.info("Checksum tree file not found for container {}. Building
from merkle tree from metadata.",
Review Comment:
```suggestion
LOG.info("Checksum tree file not found for container {}. Building
merkle tree from container metadata.",
```
--
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]