Hadoop HDFS
  1. Hadoop HDFS
  2. HDFS-3852

TestHftpDelegationToken is broken after HADOOP-8225

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 0.23.3, 2.0.0-alpha
    • Fix Version/s: 0.23.3, 2.0.2-alpha
    • Component/s: hdfs-client, security
    • Labels:
      None

      Description

      It's been failing in all builds for the last 2 days or so. Git bisect indicates that it's due to HADOOP-8225.

      1. HDFS-3852.patch
        0.8 kB
        Daryn Sharp

        Issue Links

          Activity

          Hide
          Daryn Sharp added a comment -

          The test failure seems sporadic. I'll look into it.

          Show
          Daryn Sharp added a comment - The test failure seems sporadic. I'll look into it.
          Hide
          Aaron T. Myers added a comment -

          FWIW, this test appears to fail 100% of the time on my box. I just ran it 5 times and it failed every time.

          Show
          Aaron T. Myers added a comment - FWIW, this test appears to fail 100% of the time on my box. I just ran it 5 times and it failed every time.
          Hide
          Daryn Sharp added a comment -

          Ok. I was just perusing the pre-commit builds. Are you using java 7?

          Show
          Daryn Sharp added a comment - Ok. I was just perusing the pre-commit builds. Are you using java 7?
          Hide
          Aaron T. Myers added a comment -

          Nope, same old java 6. FWIW, got bisect also agrees with me that 8225 caused this.

          Does the test not fail for you?

          Show
          Aaron T. Myers added a comment - Nope, same old java 6. FWIW, got bisect also agrees with me that 8225 caused this. Does the test not fail for you?
          Hide
          Eli Collins added a comment -

          Fails locally for me as well, and also [in recent jobs|
          https://builds.apache.org/job/PreCommit-HDFS-Build/3104//testReport/org.apache.hadoop.hdfs/TestHftpDelegationToken/testHdfsDelegationToken].

          Here's the failure:

          java.lang.AssertionError: wrong tokens in user expected:<2> but was:<1>
                  at org.junit.Assert.fail(Assert.java:91)
                  at org.junit.Assert.failNotEquals(Assert.java:645)
                  at org.junit.Assert.assertEquals(Assert.java:126)
                  at org.junit.Assert.assertEquals(Assert.java:470)
                  at org.apache.hadoop.hdfs.TestHftpDelegationToken.testHdfsDelegationToken(TestHftpDelegationToken.java:60)
          
          Show
          Eli Collins added a comment - Fails locally for me as well, and also [in recent jobs| https://builds.apache.org/job/PreCommit-HDFS-Build/3104//testReport/org.apache.hadoop.hdfs/TestHftpDelegationToken/testHdfsDelegationToken ]. Here's the failure: java.lang.AssertionError: wrong tokens in user expected:<2> but was:<1> at org.junit.Assert.fail(Assert.java:91) at org.junit.Assert.failNotEquals(Assert.java:645) at org.junit.Assert.assertEquals(Assert.java:126) at org.junit.Assert.assertEquals(Assert.java:470) at org.apache.hadoop.hdfs.TestHftpDelegationToken.testHdfsDelegationToken(TestHftpDelegationToken.java:60)
          Hide
          Daryn Sharp added a comment -

          The test is attempting to insert two tokens with the same service. The UGI's private creds is a list which happily accepted tokens with duplicate services and even duplicate tokens. When I changed UGI in HADOOP-8225 to allow extraction of a Credentials object from the UGI, it broke the test because Credentials uses a map for tokens which naturally doesn't allow for service dups. The test is really trying to ensure the correct token is retrieved for htftp so I changed the 2nd token to have a different service to prevent it replacing the first token.

          Arguably, multiple tokens for the same service with different kinds should be permissible. However in practice that is/was not "possible" because a Credentials (which doesn't allow service dups) is used to build up tokens to be dumped into the UGI.

          Show
          Daryn Sharp added a comment - The test is attempting to insert two tokens with the same service. The UGI's private creds is a list which happily accepted tokens with duplicate services and even duplicate tokens. When I changed UGI in HADOOP-8225 to allow extraction of a Credentials object from the UGI, it broke the test because Credentials uses a map for tokens which naturally doesn't allow for service dups. The test is really trying to ensure the correct token is retrieved for htftp so I changed the 2nd token to have a different service to prevent it replacing the first token. Arguably, multiple tokens for the same service with different kinds should be permissible. However in practice that is/was not "possible" because a Credentials (which doesn't allow service dups) is used to build up tokens to be dumped into the UGI.
          Hide
          Aaron T. Myers added a comment -

          Got it. Makes sense. Thanks for the explanation, Daryn, and thanks for looking into this issue.

          The patch looks good to me. +1 pending Jenkins.

          Show
          Aaron T. Myers added a comment - Got it. Makes sense. Thanks for the explanation, Daryn, and thanks for looking into this issue. The patch looks good to me. +1 pending Jenkins.
          Hide
          Hadoop QA added a comment -

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

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

          +1 tests included. The patch appears to include 1 new or modified test files.

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

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

          +1 eclipse:eclipse. The patch built with eclipse:eclipse.

          -1 findbugs. The patch appears to introduce 1 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 hadoop-hdfs-project/hadoop-hdfs.

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

          Test results: https://builds.apache.org/job/PreCommit-HDFS-Build/3107//testReport/
          Findbugs warnings: https://builds.apache.org/job/PreCommit-HDFS-Build/3107//artifact/trunk/patchprocess/newPatchFindbugsWarningshadoop-hdfs.html
          Console output: https://builds.apache.org/job/PreCommit-HDFS-Build/3107//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/12542779/HDFS-3852.patch against trunk revision . +1 @author. The patch does not contain any @author tags. +1 tests included. The patch appears to include 1 new or modified test files. +1 javac. The applied patch does not increase the total number of javac compiler warnings. +1 javadoc. The javadoc tool did not generate any warning messages. +1 eclipse:eclipse. The patch built with eclipse:eclipse. -1 findbugs. The patch appears to introduce 1 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 hadoop-hdfs-project/hadoop-hdfs. +1 contrib tests. The patch passed contrib unit tests. Test results: https://builds.apache.org/job/PreCommit-HDFS-Build/3107//testReport/ Findbugs warnings: https://builds.apache.org/job/PreCommit-HDFS-Build/3107//artifact/trunk/patchprocess/newPatchFindbugsWarningshadoop-hdfs.html Console output: https://builds.apache.org/job/PreCommit-HDFS-Build/3107//console This message is automatically generated.
          Hide
          Daryn Sharp added a comment -

          Findbugs warning is in DN, completely unrelated.

          Show
          Daryn Sharp added a comment - Findbugs warning is in DN, completely unrelated.
          Hide
          Hudson added a comment -

          Integrated in Hadoop-Common-trunk-Commit #2668 (See https://builds.apache.org/job/Hadoop-Common-trunk-Commit/2668/)
          HDFS-3852. TestHftpDelegationToken is broken after HADOOP-8225 (daryn) (Revision 1379623)

          Result = SUCCESS
          daryn : http://svn.apache.org/viewcvs.cgi/?root=Apache-SVN&view=rev&rev=1379623
          Files :

          • /hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt
          • /hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/src/test/java/org/apache/hadoop/hdfs/TestHftpDelegationToken.java
          Show
          Hudson added a comment - Integrated in Hadoop-Common-trunk-Commit #2668 (See https://builds.apache.org/job/Hadoop-Common-trunk-Commit/2668/ ) HDFS-3852 . TestHftpDelegationToken is broken after HADOOP-8225 (daryn) (Revision 1379623) Result = SUCCESS daryn : http://svn.apache.org/viewcvs.cgi/?root=Apache-SVN&view=rev&rev=1379623 Files : /hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt /hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/src/test/java/org/apache/hadoop/hdfs/TestHftpDelegationToken.java
          Hide
          Hudson added a comment -

          Integrated in Hadoop-Hdfs-trunk-Commit #2731 (See https://builds.apache.org/job/Hadoop-Hdfs-trunk-Commit/2731/)
          HDFS-3852. TestHftpDelegationToken is broken after HADOOP-8225 (daryn) (Revision 1379623)

          Result = SUCCESS
          daryn : http://svn.apache.org/viewcvs.cgi/?root=Apache-SVN&view=rev&rev=1379623
          Files :

          • /hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt
          • /hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/src/test/java/org/apache/hadoop/hdfs/TestHftpDelegationToken.java
          Show
          Hudson added a comment - Integrated in Hadoop-Hdfs-trunk-Commit #2731 (See https://builds.apache.org/job/Hadoop-Hdfs-trunk-Commit/2731/ ) HDFS-3852 . TestHftpDelegationToken is broken after HADOOP-8225 (daryn) (Revision 1379623) Result = SUCCESS daryn : http://svn.apache.org/viewcvs.cgi/?root=Apache-SVN&view=rev&rev=1379623 Files : /hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt /hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/src/test/java/org/apache/hadoop/hdfs/TestHftpDelegationToken.java
          Hide
          Hudson added a comment -

          Integrated in Hadoop-Mapreduce-trunk-Commit #2693 (See https://builds.apache.org/job/Hadoop-Mapreduce-trunk-Commit/2693/)
          HDFS-3852. TestHftpDelegationToken is broken after HADOOP-8225 (daryn) (Revision 1379623)

          Result = FAILURE
          daryn : http://svn.apache.org/viewcvs.cgi/?root=Apache-SVN&view=rev&rev=1379623
          Files :

          • /hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt
          • /hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/src/test/java/org/apache/hadoop/hdfs/TestHftpDelegationToken.java
          Show
          Hudson added a comment - Integrated in Hadoop-Mapreduce-trunk-Commit #2693 (See https://builds.apache.org/job/Hadoop-Mapreduce-trunk-Commit/2693/ ) HDFS-3852 . TestHftpDelegationToken is broken after HADOOP-8225 (daryn) (Revision 1379623) Result = FAILURE daryn : http://svn.apache.org/viewcvs.cgi/?root=Apache-SVN&view=rev&rev=1379623 Files : /hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt /hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/src/test/java/org/apache/hadoop/hdfs/TestHftpDelegationToken.java
          Hide
          Hudson added a comment -

          Integrated in Hadoop-Hdfs-0.23-Build #361 (See https://builds.apache.org/job/Hadoop-Hdfs-0.23-Build/361/)
          svn merge -c 1379623 FIXES: HDFS-3852. TestHftpDelegationToken is broken after HADOOP-8225 (daryn) (Revision 1379627)

          Result = UNSTABLE
          daryn : http://svn.apache.org/viewcvs.cgi/?root=Apache-SVN&view=rev&rev=1379627
          Files :

          • /hadoop/common/branches/branch-0.23/hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt
          • /hadoop/common/branches/branch-0.23/hadoop-hdfs-project/hadoop-hdfs/src/test/java/org/apache/hadoop/hdfs/TestHftpDelegationToken.java
          Show
          Hudson added a comment - Integrated in Hadoop-Hdfs-0.23-Build #361 (See https://builds.apache.org/job/Hadoop-Hdfs-0.23-Build/361/ ) svn merge -c 1379623 FIXES: HDFS-3852 . TestHftpDelegationToken is broken after HADOOP-8225 (daryn) (Revision 1379627) Result = UNSTABLE daryn : http://svn.apache.org/viewcvs.cgi/?root=Apache-SVN&view=rev&rev=1379627 Files : /hadoop/common/branches/branch-0.23/hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt /hadoop/common/branches/branch-0.23/hadoop-hdfs-project/hadoop-hdfs/src/test/java/org/apache/hadoop/hdfs/TestHftpDelegationToken.java
          Hide
          Hudson added a comment -

          Integrated in Hadoop-Hdfs-trunk #1152 (See https://builds.apache.org/job/Hadoop-Hdfs-trunk/1152/)
          HDFS-3852. TestHftpDelegationToken is broken after HADOOP-8225 (daryn) (Revision 1379623)

          Result = SUCCESS
          daryn : http://svn.apache.org/viewcvs.cgi/?root=Apache-SVN&view=rev&rev=1379623
          Files :

          • /hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt
          • /hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/src/test/java/org/apache/hadoop/hdfs/TestHftpDelegationToken.java
          Show
          Hudson added a comment - Integrated in Hadoop-Hdfs-trunk #1152 (See https://builds.apache.org/job/Hadoop-Hdfs-trunk/1152/ ) HDFS-3852 . TestHftpDelegationToken is broken after HADOOP-8225 (daryn) (Revision 1379623) Result = SUCCESS daryn : http://svn.apache.org/viewcvs.cgi/?root=Apache-SVN&view=rev&rev=1379623 Files : /hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt /hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/src/test/java/org/apache/hadoop/hdfs/TestHftpDelegationToken.java
          Hide
          Hudson added a comment -

          Integrated in Hadoop-Mapreduce-trunk #1183 (See https://builds.apache.org/job/Hadoop-Mapreduce-trunk/1183/)
          HDFS-3852. TestHftpDelegationToken is broken after HADOOP-8225 (daryn) (Revision 1379623)

          Result = SUCCESS
          daryn : http://svn.apache.org/viewcvs.cgi/?root=Apache-SVN&view=rev&rev=1379623
          Files :

          • /hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt
          • /hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/src/test/java/org/apache/hadoop/hdfs/TestHftpDelegationToken.java
          Show
          Hudson added a comment - Integrated in Hadoop-Mapreduce-trunk #1183 (See https://builds.apache.org/job/Hadoop-Mapreduce-trunk/1183/ ) HDFS-3852 . TestHftpDelegationToken is broken after HADOOP-8225 (daryn) (Revision 1379623) Result = SUCCESS daryn : http://svn.apache.org/viewcvs.cgi/?root=Apache-SVN&view=rev&rev=1379623 Files : /hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt /hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/src/test/java/org/apache/hadoop/hdfs/TestHftpDelegationToken.java

            People

            • Assignee:
              Daryn Sharp
              Reporter:
              Aaron T. Myers
            • Votes:
              0 Vote for this issue
              Watchers:
              10 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Development