Details

    • Type: Sub-task Sub-task
    • Status: Resolved
    • Priority: Minor Minor
    • Resolution: Won't Fix
    • Affects Version/s: trunk
    • Fix Version/s: None
    • Component/s: build
    • Labels:
      None
    • Target Version/s:

      Description

      Clean up a bunch of existing javac warnings in hadoop-yarn-server-web-proxy module.

        Activity

        Hide
        Harsh J added a comment -

        Minor patch that cleans up javac warnings from yarn-server-web-proxy submodule.

        Show
        Harsh J added a comment - Minor patch that cleans up javac warnings from yarn-server-web-proxy submodule.
        Hide
        Hadoop QA added a comment -

        -1 overall. Here are the results of testing the latest attachment
        http://issues.apache.org/jira/secure/attachment/12523709/0016-YARN-Server-Web-Proxy-Cleanup.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 generated 493 javac compiler warnings (more than the trunk's current 492 warnings).

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

        +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 failed these unit tests:
        org.apache.hadoop.yarn.server.TestContainerManagerSecurity

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

        Test results: https://builds.apache.org/job/PreCommit-MAPREDUCE-Build/2283//testReport/
        Console output: https://builds.apache.org/job/PreCommit-MAPREDUCE-Build/2283//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/12523709/0016-YARN-Server-Web-Proxy-Cleanup.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 generated 493 javac compiler warnings (more than the trunk's current 492 warnings). +1 eclipse:eclipse. The patch built with eclipse:eclipse. +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 failed these unit tests: org.apache.hadoop.yarn.server.TestContainerManagerSecurity +1 contrib tests. The patch passed contrib unit tests. Test results: https://builds.apache.org/job/PreCommit-MAPREDUCE-Build/2283//testReport/ Console output: https://builds.apache.org/job/PreCommit-MAPREDUCE-Build/2283//console This message is automatically generated.
        Hide
        Harsh J added a comment -

        The only change here is:

        --- hadoop-mapreduce-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-web-proxy/src/main/java/org/apache/hadoop/yarn/server/webproxy/WebAppProxyServlet.java
        +++ hadoop-mapreduce-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-web-proxy/src/main/java/org/apache/hadoop/yarn/server/webproxy/WebAppProxyServlet.java
        @@ -144,7 +144,6 @@ public class WebAppProxyServlet extends HttpServlet {
             config.setLocalAddress(localAddress);
             HttpMethod method = new GetMethod(uri.getEscapedURI());
         
        -    @SuppressWarnings("unchecked")
             Enumeration<String> names = req.getHeaderNames();
             while(names.hasMoreElements()) {
               String name = names.nextElement();
        

        And with my local JDK 1.6 (and Eclipse 3.7.x), the warning ought to reduce. I'm not sure why we need an unchecked suppressor there, as the signature for req.getHeaderNames() is typed in itself:

        Enumeration<String> javax.servlet.http.HttpServletRequest.getHeaderNames()

        Show
        Harsh J added a comment - The only change here is: --- hadoop-mapreduce-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-web-proxy/src/main/java/org/apache/hadoop/yarn/server/webproxy/WebAppProxyServlet.java +++ hadoop-mapreduce-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-web-proxy/src/main/java/org/apache/hadoop/yarn/server/webproxy/WebAppProxyServlet.java @@ -144,7 +144,6 @@ public class WebAppProxyServlet extends HttpServlet { config.setLocalAddress(localAddress); HttpMethod method = new GetMethod(uri.getEscapedURI()); - @SuppressWarnings( "unchecked" ) Enumeration< String > names = req.getHeaderNames(); while (names.hasMoreElements()) { String name = names.nextElement(); And with my local JDK 1.6 (and Eclipse 3.7.x), the warning ought to reduce. I'm not sure why we need an unchecked suppressor there, as the signature for req.getHeaderNames() is typed in itself: Enumeration<String> javax.servlet.http.HttpServletRequest.getHeaderNames()
        Hide
        Harsh J added a comment -

        The above comment is for this message:

        -1 javac. The applied patch generated 493 javac compiler warnings (more than the trunk's current 492 warnings).

        [Perhaps the build machines are using an old version of the http jar that has a different signature?)

        Show
        Harsh J added a comment - The above comment is for this message: -1 javac. The applied patch generated 493 javac compiler warnings (more than the trunk's current 492 warnings). [Perhaps the build machines are using an old version of the http jar that has a different signature?)
        Hide
        Robert Joseph Evans added a comment -

        Maven should be taking care of that. If not something is wrong with maven, or our pom file is not specifying all of its dependencies correctly.

        Show
        Robert Joseph Evans added a comment - Maven should be taking care of that. If not something is wrong with maven, or our pom file is not specifying all of its dependencies correctly.
        Hide
        Harsh J added a comment -

        Patches were too broad and have gone stale. Will address these forms of issue over separate, smaller and more divided JIRAs in future.

        Closing out parent JIRA MAPREDUCE-4172, and hence closing out this.

        Show
        Harsh J added a comment - Patches were too broad and have gone stale. Will address these forms of issue over separate, smaller and more divided JIRAs in future. Closing out parent JIRA MAPREDUCE-4172 , and hence closing out this.

          People

          • Assignee:
            Harsh J
            Reporter:
            Harsh J
          • Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development