Uploaded image for project: 'Hadoop Common'
  1. Hadoop Common
  2. HADOOP-6176

Adding a couple private methods to AccessTokenHandler for testing purposes

Details

    • Test
    • Status: Closed
    • Major
    • Resolution: Fixed
    • None
    • 0.21.0
    • security
    • None
    • Reviewed

    Description

      To support some test cases being added as part of HDFS-409, a couple private methods need to be added to AccessTokenHandler. One is for setting token lifetime and another is checking if a token has expired.

      Attachments

        1. core-03.patch
          4 kB
          Kan Zhang
        2. HADOOP-6176-0_20.2.patch
          4 kB
          Jitendra Nath Pandey

        Issue Links

          Activity

            hadoopqa Hadoop QA added a comment -

            +1 overall. Here are the results of testing the latest attachment
            http://issues.apache.org/jira/secure/attachment/12415521/core-03.patch
            against trunk revision 800919.

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

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

            +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 warnings.

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

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

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

            Test results: http://hudson.zones.apache.org/hudson/job/Hadoop-Patch-vesta.apache.org/592/testReport/
            Findbugs warnings: http://hudson.zones.apache.org/hudson/job/Hadoop-Patch-vesta.apache.org/592/artifact/trunk/build/test/findbugs/newPatchFindbugsWarnings.html
            Checkstyle results: http://hudson.zones.apache.org/hudson/job/Hadoop-Patch-vesta.apache.org/592/artifact/trunk/build/test/checkstyle-errors.html
            Console output: http://hudson.zones.apache.org/hudson/job/Hadoop-Patch-vesta.apache.org/592/console

            This message is automatically generated.

            hadoopqa Hadoop QA added a comment - +1 overall. Here are the results of testing the latest attachment http://issues.apache.org/jira/secure/attachment/12415521/core-03.patch against trunk revision 800919. +1 @author. The patch does not contain any @author tags. +1 tests included. The patch appears to include 3 new or modified tests. +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 warnings. +1 release audit. The applied patch does not increase the total number of release audit warnings. +1 core tests. The patch passed core unit tests. +1 contrib tests. The patch passed contrib unit tests. Test results: http://hudson.zones.apache.org/hudson/job/Hadoop-Patch-vesta.apache.org/592/testReport/ Findbugs warnings: http://hudson.zones.apache.org/hudson/job/Hadoop-Patch-vesta.apache.org/592/artifact/trunk/build/test/findbugs/newPatchFindbugsWarnings.html Checkstyle results: http://hudson.zones.apache.org/hudson/job/Hadoop-Patch-vesta.apache.org/592/artifact/trunk/build/test/checkstyle-errors.html Console output: http://hudson.zones.apache.org/hudson/job/Hadoop-Patch-vesta.apache.org/592/console This message is automatically generated.
            jghoman Jakob Homan added a comment -

            +1 with a readability nit: it may be nice to explicitly state in a comment that the tests are needed to expose otherwise private methods for testing. May be a reasonable assumption to make on the reader's part, but clarity is always a good thing.

            jghoman Jakob Homan added a comment - +1 with a readability nit: it may be nice to explicitly state in a comment that the tests are needed to expose otherwise private methods for testing. May be a reasonable assumption to make on the reader's part, but clarity is always a good thing.

            There was an idea to express the essence of this modification via aspects. However, in order to deliver this functionality in a most timely manner this effort will be carried on separately. I might be filing a separate JIRA for it if a preliminary investigation will show that such approach is viable.

            cos Konstantin I Boudnik added a comment - There was an idea to express the essence of this modification via aspects. However, in order to deliver this functionality in a most timely manner this effort will be carried on separately. I might be filing a separate JIRA for it if a preliminary investigation will show that such approach is viable.
            szetszwo Tsz-wo Sze added a comment -

            I have committed this. Thanks, Kan!

            szetszwo Tsz-wo Sze added a comment - I have committed this. Thanks, Kan!
            hudson Hudson added a comment -

            Integrated in Hadoop-Common-trunk #48 (See http://hudson.zones.apache.org/hudson/job/Hadoop-Common-trunk/48/)
            . Add a couple package private methods to AccessTokenHandler for testing. Contributed by Kan Zhang

            hudson Hudson added a comment - Integrated in Hadoop-Common-trunk #48 (See http://hudson.zones.apache.org/hudson/job/Hadoop-Common-trunk/48/ ) . Add a couple package private methods to AccessTokenHandler for testing. Contributed by Kan Zhang

            Patch for hadoop 20 is added.

            jnp Jitendra Nath Pandey added a comment - Patch for hadoop 20 is added.

            People

              kzhang Kan Zhang
              kzhang Kan Zhang
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: