HDFS-17204. EC: Reduce unnecessary log when processing excess redundancy. (#6107). Contributed by Shuyan Zhang.

Reviewed-by: Haiyang Hu <haiyang.hu@shopee.com>
Signed-off-by: He Xiaoqiao <hexiaoqiao@apache.org>
This commit is contained in:
zhangshuyan 2023-09-26 18:49:47 +08:00 committed by GitHub
parent 3de66f5c40
commit 26a5f38250
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -4201,6 +4201,12 @@ public class BlockManager implements BlockStatsMXBean {
storage2index.put(storage, index); storage2index.put(storage, index);
} }
if (duplicated.isEmpty()) {
LOG.debug("Found no duplicated internal blocks for {}. Maybe it's " +
"because there are stale storages.", storedBlock);
return;
}
// use delHint only if delHint is duplicated // use delHint only if delHint is duplicated
final DatanodeStorageInfo delStorageHint = final DatanodeStorageInfo delStorageHint =
DatanodeStorageInfo.getDatanodeStorageInfo(nonExcess, delNodeHint); DatanodeStorageInfo.getDatanodeStorageInfo(nonExcess, delNodeHint);