Hadoop HDFS
  1. Hadoop HDFS
  2. HDFS-2205

Log message for failed connection to datanode is not followed by a success message.

    Details

    • Type: Improvement Improvement
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 0.23.0
    • Fix Version/s: 0.23.0, 0.24.0
    • Component/s: hdfs-client
    • Labels:
      None

      Description

      To avoid confusing users on whether their HDFS operation was succesful or not, a success message should be printed.

      1. HDFS-2205.patch
        2 kB
        Ravi Prakash
      2. HDFS-2205.patch
        2 kB
        Ravi Prakash
      3. HDFS-2205.patch
        2 kB
        Ravi Prakash

        Activity

        Hide
        Ravi Prakash added a comment -

        Small patch affecting only the Log. So not including a test.

        Show
        Ravi Prakash added a comment - Small patch affecting only the Log. So not including a test.
        Hide
        Ravi Prakash added a comment -

        Can someone please review and commit this?

        Show
        Ravi Prakash added a comment - Can someone please review and commit this?
        Hide
        Ravi Prakash added a comment -

        Rebased patch to current HEAD. Applied to both, trunk and branch-0.23

        Show
        Ravi Prakash added a comment - Rebased patch to current HEAD. Applied to both, trunk and branch-0.23
        Hide
        Hadoop QA added a comment -

        -1 overall. Here are the results of testing the latest attachment
        http://issues.apache.org/jira/secure/attachment/12498209/HDFS-2205.patch
        against trunk revision .

        +1 @author. The patch does not contain any @author tags.

        -1 tests included. The patch doesn't appear to include any new or modified tests.
        Please justify why no new tests are needed for this patch.
        Also please list what manual steps were performed to verify this patch.

        +1 javadoc. The javadoc tool did not generate any warning messages.

        +1 javac. The applied patch does not increase the total number of javac compiler warnings.

        +1 findbugs. The patch does not introduce any new Findbugs (version 1.3.9) warnings.

        +1 release audit. The applied patch does not increase the total number of release audit warnings.

        +1 core tests. The patch passed unit tests in .

        +1 contrib tests. The patch passed contrib unit tests.

        Test results: https://builds.apache.org/job/PreCommit-HDFS-Build/1353//testReport/
        Console output: https://builds.apache.org/job/PreCommit-HDFS-Build/1353//console

        This message is automatically generated.

        Show
        Hadoop QA added a comment - -1 overall. Here are the results of testing the latest attachment http://issues.apache.org/jira/secure/attachment/12498209/HDFS-2205.patch against trunk revision . +1 @author. The patch does not contain any @author tags. -1 tests included. The patch doesn't appear to include any new or modified tests. Please justify why no new tests are needed for this patch. Also please list what manual steps were performed to verify this patch. +1 javadoc. The javadoc tool did not generate any warning messages. +1 javac. The applied patch does not increase the total number of javac compiler warnings. +1 findbugs. The patch does not introduce any new Findbugs (version 1.3.9) warnings. +1 release audit. The applied patch does not increase the total number of release audit warnings. +1 core tests. The patch passed unit tests in . +1 contrib tests. The patch passed contrib unit tests. Test results: https://builds.apache.org/job/PreCommit-HDFS-Build/1353//testReport/ Console output: https://builds.apache.org/job/PreCommit-HDFS-Build/1353//console This message is automatically generated.
        Hide
        Steve Loughran added a comment -

        instead of going LOG.warn("text" + ex.getMessage() );

        can you go LOG.warn("text" + ex, ex );

        Two reasons

        1. not all exceptions have a message (e.g NullPointerException)
        2. the second argument hands off the potentially nested exception chain to the logger to process as its formatter sees fit.

        A lot of the existing code doesn't get this right, but this patch makes things slightly worse in terms of reporting the exception itself.

        Also, why log at debug the connection failure when more info is being printed at warn() level? I'd delete the debug logging clause.

        Show
        Steve Loughran added a comment - instead of going LOG.warn("text" + ex.getMessage() ); can you go LOG.warn("text" + ex, ex ); Two reasons not all exceptions have a message (e.g NullPointerException) the second argument hands off the potentially nested exception chain to the logger to process as its formatter sees fit. A lot of the existing code doesn't get this right, but this patch makes things slightly worse in terms of reporting the exception itself. Also, why log at debug the connection failure when more info is being printed at warn() level? I'd delete the debug logging clause.
        Hide
        Ravi Prakash added a comment -

        Thanks for your suggestions Steve. I've incorporated the changes in this new patch. Could you please review and commit?

        Show
        Ravi Prakash added a comment - Thanks for your suggestions Steve. I've incorporated the changes in this new patch. Could you please review and commit?
        Hide
        Hadoop QA added a comment -

        -1 overall. Here are the results of testing the latest attachment
        http://issues.apache.org/jira/secure/attachment/12498236/HDFS-2205.patch
        against trunk revision .

        +1 @author. The patch does not contain any @author tags.

        -1 tests included. The patch doesn't appear to include any new or modified tests.
        Please justify why no new tests are needed for this patch.
        Also please list what manual steps were performed to verify this patch.

        +1 javadoc. The javadoc tool did not generate any warning messages.

        +1 javac. The applied patch does not increase the total number of javac compiler warnings.

        +1 findbugs. The patch does not introduce any new Findbugs (version 1.3.9) warnings.

        +1 release audit. The applied patch does not increase the total number of release audit warnings.

        +1 core tests. The patch passed unit tests in .

        +1 contrib tests. The patch passed contrib unit tests.

        Test results: https://builds.apache.org/job/PreCommit-HDFS-Build/1354//testReport/
        Console output: https://builds.apache.org/job/PreCommit-HDFS-Build/1354//console

        This message is automatically generated.

        Show
        Hadoop QA added a comment - -1 overall. Here are the results of testing the latest attachment http://issues.apache.org/jira/secure/attachment/12498236/HDFS-2205.patch against trunk revision . +1 @author. The patch does not contain any @author tags. -1 tests included. The patch doesn't appear to include any new or modified tests. Please justify why no new tests are needed for this patch. Also please list what manual steps were performed to verify this patch. +1 javadoc. The javadoc tool did not generate any warning messages. +1 javac. The applied patch does not increase the total number of javac compiler warnings. +1 findbugs. The patch does not introduce any new Findbugs (version 1.3.9) warnings. +1 release audit. The applied patch does not increase the total number of release audit warnings. +1 core tests. The patch passed unit tests in . +1 contrib tests. The patch passed contrib unit tests. Test results: https://builds.apache.org/job/PreCommit-HDFS-Build/1354//testReport/ Console output: https://builds.apache.org/job/PreCommit-HDFS-Build/1354//console This message is automatically generated.
        Hide
        Steve Loughran added a comment -

        +1

        Show
        Steve Loughran added a comment - +1
        Hide
        Steve Loughran added a comment -

        committed! Thanks!

        Show
        Steve Loughran added a comment - committed! Thanks!
        Hide
        Ravi Prakash added a comment -

        Thank you Steve!

        Show
        Ravi Prakash added a comment - Thank you Steve!

          People

          • Assignee:
            Ravi Prakash
            Reporter:
            Ravi Prakash
          • Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development