ZooKeeper
  1. ZooKeeper
  2. ZOOKEEPER-1352

server.InvalidSnapshotTest is using connection timeouts that are too short

    Details

    • Type: Bug Bug
    • Status: Resolved
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 3.3.4
    • Fix Version/s: 3.4.3, 3.3.5, 3.5.0
    • Component/s: tests
    • Labels:
      None
    • Hadoop Flags:
      Reviewed

      Description

      InvalidSnapshotTest is using connection timeouts that are too short, see this false failure:
      https://builds.apache.org/job/ZooKeeper_branch33_solaris/65/testReport/junit/org.apache.zookeeper.server/InvalidSnapshotTest/testInvalidSnapshot/

      org.apache.zookeeper.KeeperException$ConnectionLossException: KeeperErrorCode = ConnectionLoss for /invalidsnap-0
      	at org.apache.zookeeper.KeeperException.create(KeeperException.java:90)
      	at org.apache.zookeeper.KeeperException.create(KeeperException.java:42)
      	at org.apache.zookeeper.ZooKeeper.create(ZooKeeper.java:643)
      	at org.apache.zookeeper.server.InvalidSnapshotTest.testInvalidSnapshot(InvalidSnapshotTest.java:71)
      

      Also in looking at the test itself it could use some cleanup (reuse features from ClientBase test utils)

      1. ZOOKEEPER-1352_br33.patch
        6 kB
        Patrick Hunt
      2. ZOOKEEPER-1352_br34.patch
        7 kB
        Patrick Hunt
      3. ZOOKEEPER-1352_trunk.patch
        7 kB
        Mahadev konar
      4. ZOOKEEPER-1352_trunk.patch
        7 kB
        Patrick Hunt

        Activity

        Hide
        Hudson added a comment -

        Integrated in ZooKeeper-trunk #1451 (See https://builds.apache.org/job/ZooKeeper-trunk/1451/)
        ZOOKEEPER-1352. server.InvalidSnapshotTest is using connection timeouts that are too short. (phunt via mahadev)

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

        • /zookeeper/trunk/CHANGES.txt
        • /zookeeper/trunk/src/java/test/org/apache/zookeeper/server/InvalidSnapshotTest.java
        • /zookeeper/trunk/src/java/test/org/apache/zookeeper/test/ClientBase.java
        Show
        Hudson added a comment - Integrated in ZooKeeper-trunk #1451 (See https://builds.apache.org/job/ZooKeeper-trunk/1451/ ) ZOOKEEPER-1352 . server.InvalidSnapshotTest is using connection timeouts that are too short. (phunt via mahadev) mahadev : http://svn.apache.org/viewcvs.cgi/?root=Apache-SVN&view=rev&rev=1240924 Files : /zookeeper/trunk/CHANGES.txt /zookeeper/trunk/src/java/test/org/apache/zookeeper/server/InvalidSnapshotTest.java /zookeeper/trunk/src/java/test/org/apache/zookeeper/test/ClientBase.java
        Hide
        Mahadev konar added a comment -

        I just committed this. Thanks Pat!

        Show
        Mahadev konar added a comment - I just committed this. Thanks Pat!
        Hide
        Hadoop QA added a comment -

        +1 overall. Here are the results of testing the latest attachment
        http://issues.apache.org/jira/secure/attachment/12513396/ZOOKEEPER-1352_trunk.patch
        against trunk revision 1238176.

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

        +1 tests included. The patch appears to include 6 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 (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/940//testReport/
        Findbugs warnings: https://builds.apache.org/job/PreCommit-ZOOKEEPER-Build/940//artifact/trunk/build/test/findbugs/newPatchFindbugsWarnings.html
        Console output: https://builds.apache.org/job/PreCommit-ZOOKEEPER-Build/940//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/12513396/ZOOKEEPER-1352_trunk.patch against trunk revision 1238176. +1 @author. The patch does not contain any @author tags. +1 tests included. The patch appears to include 6 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 (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/940//testReport/ Findbugs warnings: https://builds.apache.org/job/PreCommit-ZOOKEEPER-Build/940//artifact/trunk/build/test/findbugs/newPatchFindbugsWarnings.html Console output: https://builds.apache.org/job/PreCommit-ZOOKEEPER-Build/940//console This message is automatically generated.
        Hide
        Mahadev konar added a comment -

        Updated trunk patch. Minor changes to merge the patch.

        Show
        Mahadev konar added a comment - Updated trunk patch. Minor changes to merge the patch.
        Hide
        Mahadev konar added a comment -

        Looks like the trunk patch doesnt apply cleanly. Uploading an updated one.

        Show
        Mahadev konar added a comment - Looks like the trunk patch doesnt apply cleanly. Uploading an updated one.
        Hide
        Mahadev konar added a comment -

        Good change to have. Since its just fixing tests, Ill commit this into all 3 branches.

        Show
        Mahadev konar added a comment - Good change to have. Since its just fixing tests, Ill commit this into all 3 branches.
        Hide
        Hadoop QA added a comment -

        +1 overall. Here are the results of testing the latest attachment
        http://issues.apache.org/jira/secure/attachment/12509602/ZOOKEEPER-1352_trunk.patch
        against trunk revision 1227000.

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

        +1 tests included. The patch appears to include 6 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 (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/880//testReport/
        Findbugs warnings: https://builds.apache.org/job/PreCommit-ZOOKEEPER-Build/880//artifact/trunk/build/test/findbugs/newPatchFindbugsWarnings.html
        Console output: https://builds.apache.org/job/PreCommit-ZOOKEEPER-Build/880//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/12509602/ZOOKEEPER-1352_trunk.patch against trunk revision 1227000. +1 @author. The patch does not contain any @author tags. +1 tests included. The patch appears to include 6 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 (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/880//testReport/ Findbugs warnings: https://builds.apache.org/job/PreCommit-ZOOKEEPER-Build/880//artifact/trunk/build/test/findbugs/newPatchFindbugsWarnings.html Console output: https://builds.apache.org/job/PreCommit-ZOOKEEPER-Build/880//console This message is automatically generated.
        Hide
        Patrick Hunt added a comment -

        The attached patches address the issue and cleanup the code significantly. I verified that for each patch we were indeed using the older snapshot to recover (as expected in the test).

        Show
        Patrick Hunt added a comment - The attached patches address the issue and cleanup the code significantly. I verified that for each patch we were indeed using the older snapshot to recover (as expected in the test).

          People

          • Assignee:
            Patrick Hunt
            Reporter:
            Patrick Hunt
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development