ZooKeeper
  1. ZooKeeper
  2. ZOOKEEPER-1169

Fix compiler (eclipse) warnings in (generated) jute code

    Details

    • Type: Improvement Improvement
    • Status: Closed
    • Priority: Minor Minor
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 3.4.0
    • Component/s: None
    • Labels:
      None
    • Hadoop Flags:
      Reviewed
    • Tags:
      cleanup, cleancode

      Description

      Fixes for compiled jute parser:

      • missing generic types
      • added @SuppressWarnings("unused") because javacc adds a dead throws clause at the
        end of functions.

      Fixes for code compiled by jute compiler:

      • remove import java.util.* and use full ref to java.util.Arrays

      One warning fixed in non-compiled code:
      src/java/main/org/apache/jute/compiler/JRecord.java

      Rationale: The warnings in your IDE (eclipse) get useless if there are tons of them. This patch reduces many of them. Another issue with patch will reduce them to 8.

        Activity

        Mahadev konar made changes -
        Status Resolved [ 5 ] Closed [ 6 ]
        Hide
        Hudson added a comment -

        Integrated in ZooKeeper-trunk #1293 (See https://builds.apache.org/job/ZooKeeper-trunk/1293/)
        ZOOKEEPER-1169. Fix compiler (eclipse) warnings in (generated) jute code (Thomas Koch via phunt)

        phunt : http://svn.apache.org/viewcvs.cgi/?root=Apache-SVN&view=rev&rev=1164710
        Files :

        • /zookeeper/trunk/CHANGES.txt
        • /zookeeper/trunk/src/java/main/org/apache/jute/compiler/JBuffer.java
        • /zookeeper/trunk/src/java/main/org/apache/jute/compiler/JRecord.java
        • /zookeeper/trunk/src/java/main/org/apache/jute/compiler/generated/rcc.jj
        Show
        Hudson added a comment - Integrated in ZooKeeper-trunk #1293 (See https://builds.apache.org/job/ZooKeeper-trunk/1293/ ) ZOOKEEPER-1169 . Fix compiler (eclipse) warnings in (generated) jute code (Thomas Koch via phunt) phunt : http://svn.apache.org/viewcvs.cgi/?root=Apache-SVN&view=rev&rev=1164710 Files : /zookeeper/trunk/CHANGES.txt /zookeeper/trunk/src/java/main/org/apache/jute/compiler/JBuffer.java /zookeeper/trunk/src/java/main/org/apache/jute/compiler/JRecord.java /zookeeper/trunk/src/java/main/org/apache/jute/compiler/generated/rcc.jj
        Hide
        Hudson added a comment -

        Integrated in ZooKeeper-trunk-jdk7 #14 (See https://builds.apache.org/job/ZooKeeper-trunk-jdk7/14/)
        ZOOKEEPER-1169. Fix compiler (eclipse) warnings in (generated) jute code (Thomas Koch via phunt)

        phunt : http://svn.apache.org/viewcvs.cgi/?root=Apache-SVN&view=rev&rev=1164710
        Files :

        • /zookeeper/trunk/CHANGES.txt
        • /zookeeper/trunk/src/java/main/org/apache/jute/compiler/JBuffer.java
        • /zookeeper/trunk/src/java/main/org/apache/jute/compiler/JRecord.java
        • /zookeeper/trunk/src/java/main/org/apache/jute/compiler/generated/rcc.jj
        Show
        Hudson added a comment - Integrated in ZooKeeper-trunk-jdk7 #14 (See https://builds.apache.org/job/ZooKeeper-trunk-jdk7/14/ ) ZOOKEEPER-1169 . Fix compiler (eclipse) warnings in (generated) jute code (Thomas Koch via phunt) phunt : http://svn.apache.org/viewcvs.cgi/?root=Apache-SVN&view=rev&rev=1164710 Files : /zookeeper/trunk/CHANGES.txt /zookeeper/trunk/src/java/main/org/apache/jute/compiler/JBuffer.java /zookeeper/trunk/src/java/main/org/apache/jute/compiler/JRecord.java /zookeeper/trunk/src/java/main/org/apache/jute/compiler/generated/rcc.jj
        Patrick Hunt made changes -
        Status Patch Available [ 10002 ] Resolved [ 5 ]
        Hadoop Flags [Reviewed]
        Fix Version/s 3.4.0 [ 12314469 ]
        Resolution Fixed [ 1 ]
        Hide
        Patrick Hunt added a comment -

        Thanks Thomas, committed to 3.4.0.

        Show
        Patrick Hunt added a comment - Thanks Thomas, committed to 3.4.0.
        Hide
        Hadoop QA added a comment -

        -1 overall. Here are the results of testing the latest attachment
        http://issues.apache.org/jira/secure/attachment/12492786/ZOOKEEPER-1169.patch
        against trunk revision 1164632.

        +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 core unit tests.

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

        Test results: https://builds.apache.org/job/PreCommit-ZOOKEEPER-Build/489//testReport/
        Findbugs warnings: https://builds.apache.org/job/PreCommit-ZOOKEEPER-Build/489//artifact/trunk/build/test/findbugs/newPatchFindbugsWarnings.html
        Console output: https://builds.apache.org/job/PreCommit-ZOOKEEPER-Build/489//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/12492786/ZOOKEEPER-1169.patch against trunk revision 1164632. +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 core unit tests. +1 contrib tests. The patch passed contrib unit tests. Test results: https://builds.apache.org/job/PreCommit-ZOOKEEPER-Build/489//testReport/ Findbugs warnings: https://builds.apache.org/job/PreCommit-ZOOKEEPER-Build/489//artifact/trunk/build/test/findbugs/newPatchFindbugsWarnings.html Console output: https://builds.apache.org/job/PreCommit-ZOOKEEPER-Build/489//console This message is automatically generated.
        Hide
        jiraposter@reviews.apache.org added a comment -

        -----------------------------------------------------------
        This is an automatically generated e-mail. To reply, visit:
        https://reviews.apache.org/r/1708/#review1736
        -----------------------------------------------------------

        Ship it!

        lgtm, I'll commit if the patch testing passes.

        • Patrick

        On 2011-09-02 18:56:43, Thomas Koch wrote:

        -----------------------------------------------------------

        This is an automatically generated e-mail. To reply, visit:

        https://reviews.apache.org/r/1708/

        -----------------------------------------------------------

        (Updated 2011-09-02 18:56:43)

        Review request for zookeeper.

        Summary

        -------

        .

        This addresses bug zookeeper-1169.

        https://issues.apache.org/jira/browse/zookeeper-1169

        Diffs

        -----

        src/java/main/org/apache/jute/compiler/JBuffer.java 466ea69

        src/java/main/org/apache/jute/compiler/JRecord.java bdae672

        src/java/main/org/apache/jute/compiler/generated/rcc.jj 511c17c

        Diff: https://reviews.apache.org/r/1708/diff

        Testing

        -------

        Thanks,

        Thomas

        Show
        jiraposter@reviews.apache.org added a comment - ----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/1708/#review1736 ----------------------------------------------------------- Ship it! lgtm, I'll commit if the patch testing passes. Patrick On 2011-09-02 18:56:43, Thomas Koch wrote: ----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/1708/ ----------------------------------------------------------- (Updated 2011-09-02 18:56:43) Review request for zookeeper. Summary ------- . This addresses bug zookeeper-1169. https://issues.apache.org/jira/browse/zookeeper-1169 Diffs ----- src/java/main/org/apache/jute/compiler/JBuffer.java 466ea69 src/java/main/org/apache/jute/compiler/JRecord.java bdae672 src/java/main/org/apache/jute/compiler/generated/rcc.jj 511c17c Diff: https://reviews.apache.org/r/1708/diff Testing ------- Thanks, Thomas
        Hide
        jiraposter@reviews.apache.org added a comment -

        -----------------------------------------------------------
        This is an automatically generated e-mail. To reply, visit:
        https://reviews.apache.org/r/1708/
        -----------------------------------------------------------

        Review request for zookeeper.

        Summary
        -------

        Show
        jiraposter@reviews.apache.org added a comment - ----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/1708/ ----------------------------------------------------------- Review request for zookeeper. Summary -------
        Thomas Koch made changes -
        Status Open [ 1 ] Patch Available [ 10002 ]
        Thomas Koch made changes -
        Field Original Value New Value
        Attachment ZOOKEEPER-1169.patch [ 12492786 ]
        Thomas Koch created issue -

          People

          • Assignee:
            Thomas Koch
            Reporter:
            Thomas Koch
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development