HBase
  1. HBase
  2. HBASE-4253

Intermittent test failure because of missing config parameter in new HTable(tablename)

    Details

    • Type: Bug Bug
    • Status: Resolved
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 0.90.4
    • Fix Version/s: 0.90.5
    • Component/s: None
    • Labels:
      None
    • Hadoop Flags:
      Reviewed

      Description

      As per the description in HBASE-4138 this issue is raised to fix the random testcase failure.
      Consider the log in the failed build #2132 for the testcase TestScannerTimeOut

      2011-08-23 04:30:11,195 INFO [main] zookeeper.MiniZooKeeperCluster(141): Failed binding ZK Server to client port: 21818
      2011-08-23 04:30:11,226 INFO [main] zookeeper.MiniZooKeeperCluster(164): Started MiniZK Cluster and connect 1 ZK server on client port: 21819

      By default we try connecting to 21818 but as it was not bindable we connect to 21819. (may be the port was busy).

      After starting the miniZkCluster

      this.conf.set("hbase.zookeeper.property.clientPort",
      Integer.toString(clientPort));

      we set this port in the config object.
      So for RS and Master the zookeeper client port will be 21819.
      Now when the testcase starts running there is no testcase till TestScannerTimeout#test3686a where we need a new client connection.
      Now as part of test3686a we create new HTable() which calls

      this(HBaseConfiguration.create(), tableName);
      

      Here we create a new configuration object. Hence the zookeeper client port is taken to be 21818.
      Ideally due to improper shutdown of some prev zk cluster that was running in 21818 the test case was able to connect to this but the port being different it could not find the /hbase node.
      Hence the failure has happened.
      The remaining two testcases in TestHTablePool that failed also has the similar problem. Even the failure in build #2119 is exactly the same.
      There should be a mechanism from the test for the client code to know to which zk he should connect to.
      Another intersting thing
      All testcases are using new HTable(conf, tablename).
      Only these 3 test cases are using it like new HTable(tablename). Hence the problem.

      1. HBASE_4253_0.90.patch
        0.6 kB
        ramkrishna.s.vasudevan
      2. HBASE-4253.patch
        1 kB
        ramkrishna.s.vasudevan

        Issue Links

          Activity

          Hide
          Ted Yu added a comment -

          Integrated to TRUNK.

          Thanks for the patch Ramkrishna.

          Show
          Ted Yu added a comment - Integrated to TRUNK. Thanks for the patch Ramkrishna.
          Hide
          ramkrishna.s.vasudevan added a comment -

          Incase if needed you can take for 0.90 version also. Here as the HBASE-4253 fix is not there here the test case will keep hanging waiting for root location.
          Just incase needed this can be integrated.

          Show
          ramkrishna.s.vasudevan added a comment - Incase if needed you can take for 0.90 version also. Here as the HBASE-4253 fix is not there here the test case will keep hanging waiting for root location. Just incase needed this can be integrated.
          Hide
          Ted Yu added a comment -

          Integrate to 0.90 branch as well.

          Show
          Ted Yu added a comment - Integrate to 0.90 branch as well.
          Hide
          Hudson added a comment -

          Integrated in HBase-TRUNK #2145 (See https://builds.apache.org/job/HBase-TRUNK/2145/)
          HBASE-4253 Intermittent test failure because of missing config parameter in new
          HTable(tablename) (Ramkrishna)

          tedyu :
          Files :

          • /hbase/trunk/CHANGES.txt
          • /hbase/trunk/src/test/java/org/apache/hadoop/hbase/client/TestHTablePool.java
          • /hbase/trunk/src/test/java/org/apache/hadoop/hbase/client/TestScannerTimeout.java
          Show
          Hudson added a comment - Integrated in HBase-TRUNK #2145 (See https://builds.apache.org/job/HBase-TRUNK/2145/ ) HBASE-4253 Intermittent test failure because of missing config parameter in new HTable(tablename) (Ramkrishna) tedyu : Files : /hbase/trunk/CHANGES.txt /hbase/trunk/src/test/java/org/apache/hadoop/hbase/client/TestHTablePool.java /hbase/trunk/src/test/java/org/apache/hadoop/hbase/client/TestScannerTimeout.java
          Hide
          stack added a comment -

          +1 on this patch.

          Show
          stack added a comment - +1 on this patch.
          Hide
          Hudson added a comment -

          Integrated in HBase-TRUNK #2151 (See https://builds.apache.org/job/HBase-TRUNK/2151/)
          HBASE-4253 TestScannerTimeOut.test3686a and TestHTablePool.testReturnDifferentTable() failure because of using new HTable(tablename)

          stack :
          Files :

          • /hbase/trunk/CHANGES.txt
          Show
          Hudson added a comment - Integrated in HBase-TRUNK #2151 (See https://builds.apache.org/job/HBase-TRUNK/2151/ ) HBASE-4253 TestScannerTimeOut.test3686a and TestHTablePool.testReturnDifferentTable() failure because of using new HTable(tablename) stack : Files : /hbase/trunk/CHANGES.txt

            People

            • Assignee:
              ramkrishna.s.vasudevan
              Reporter:
              ramkrishna.s.vasudevan
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Development