[ 
https://issues.apache.org/jira/browse/HDFS-16624?focusedWorklogId=779273&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-779273
 ]

ASF GitHub Bot logged work on HDFS-16624:
-----------------------------------------

                Author: ASF GitHub Bot
            Created on: 07/Jun/22 23:16
            Start Date: 07/Jun/22 23:16
    Worklog Time Spent: 10m 
      Work Description: slfan1989 commented on code in PR #4412:
URL: https://github.com/apache/hadoop/pull/4412#discussion_r891780928


##########
hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/tools/DFSAdmin.java:
##########
@@ -2068,51 +2068,51 @@ int getReconfigurationStatus(final String nodeType, 
final String address, final
       errMsg = String.format("Node [%s] reloading configuration: %s.", address,
           e.toString());
     }
-
-    if (errMsg != null) {
-      err.println(errMsg);
-      return 1;
-    } else {
-      out.print(outMsg);
-    }
-
-    if (status != null) {
-      if (!status.hasTask()) {
-        out.println("no task was found.");
-        return 0;
-      }
-      out.print("started at " + new Date(status.getStartTime()));
-      if (!status.stopped()) {
-        out.println(" and is still running.");
-        return 0;
+    synchronized (this) {

Review Comment:
   thanks for your suggestion, I will modify the junit test.





Issue Time Tracking
-------------------

    Worklog Id:     (was: 779273)
    Time Spent: 1h 50m  (was: 1h 40m)

> Fix org.apache.hadoop.hdfs.tools.TestDFSAdmin#testAllDatanodesReconfig ERROR
> ----------------------------------------------------------------------------
>
>                 Key: HDFS-16624
>                 URL: https://issues.apache.org/jira/browse/HDFS-16624
>             Project: Hadoop HDFS
>          Issue Type: Bug
>    Affects Versions: 3.4.0
>            Reporter: fanshilun
>            Assignee: fanshilun
>            Priority: Major
>              Labels: pull-request-available
>         Attachments: testAllDatanodesReconfig.png
>
>          Time Spent: 1h 50m
>  Remaining Estimate: 0h
>
> HDFS-16619 found an error message during Junit unit testing, as follows:
> expected:<[SUCCESS: Changed property dfs.datanode.peer.stats.enabled]> but 
> was:<[ From: "false"]>
> After code debugging, it was found that there was an error in the selection 
> outs.get(2) of the assertion(1208), index should be equal to 1.
> Please refer to the attachment for debugging pictures
> !testAllDatanodesReconfig.png!



--
This message was sent by Atlassian Jira
(v8.20.7#820007)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to