[
https://issues.apache.org/jira/browse/HDFS-16352?focusedWorklogId=696323&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-696323
]
ASF GitHub Bot logged work on HDFS-16352:
-----------------------------------------
Author: ASF GitHub Bot
Created on: 15/Dec/21 03:34
Start Date: 15/Dec/21 03:34
Worklog Time Spent: 10m
Work Description: Hexiaoqiao commented on a change in pull request #3714:
URL: https://github.com/apache/hadoop/pull/3714#discussion_r769216502
##########
File path:
hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/blockmanagement/DatanodeManager.java
##########
@@ -2172,8 +2172,9 @@ public String getSlowDisksReport() {
.size()];
for (int i = 0; i < reports.length; i++) {
final DatanodeDescriptor d = datanodes.get(i);
- reports[i] = new DatanodeStorageReport(
- new DatanodeInfoBuilder().setFrom(d).build(), d.getStorageReports());
+ DatanodeInfo dnInfo = new DatanodeInfoBuilder().setFrom(d).build();
+ dnInfo.setNumBlocks(d.numBlocks());
Review comment:
Thanks @liubingxing for your replay. It makes sense to me.
--
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]
Issue Time Tracking
-------------------
Worklog Id: (was: 696323)
Time Spent: 3h (was: 2h 50m)
> return the real datanode numBlocks in #getDatanodeStorageReport
> ---------------------------------------------------------------
>
> Key: HDFS-16352
> URL: https://issues.apache.org/jira/browse/HDFS-16352
> Project: Hadoop HDFS
> Issue Type: Improvement
> Reporter: qinyuren
> Assignee: qinyuren
> Priority: Major
> Labels: pull-request-available
> Attachments: image-2021-11-23-22-04-06-131.png
>
> Time Spent: 3h
> Remaining Estimate: 0h
>
> #getDatanodeStorageReport will return the array of DatanodeStorageReport
> which contains the DatanodeInfo in each DatanodeStorageReport, but the
> numBlocks in DatanodeInfo is always zero, which is confusing
> !image-2021-11-23-22-04-06-131.png|width=683,height=338!
> Or we can return the real numBlocks in DatanodeInfo when we call
> #getDatanodeStorageReport
--
This message was sent by Atlassian Jira
(v8.20.1#820001)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]