Uploaded image for project: 'HBase'
  1. HBase
  2. HBASE-10627

A logic mistake in HRegionServer isHealthy

Details

    • Bug
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • None
    • 0.96.2, 0.98.1, 0.99.0, 0.94.18
    • None
    • None
    • Reviewed

    Description

      After visiting the isHealthy in HRegionServer, I think there is a logic mistake.

          // Verify that all threads are alive
          if (!(leases.isAlive()
              && cacheFlusher.isAlive() && hlogRoller.isAlive()
              && this.compactionChecker.isAlive())   <---- logic wrong here
              && this.periodicFlusher.isAlive()) {
            stop("One or more threads are no longer alive -- stop");
            return false;
          }
      

      which should be

          // Verify that all threads are alive
          if (!(leases.isAlive()
              && cacheFlusher.isAlive() && hlogRoller.isAlive()
              && this.compactionChecker.isAlive()
              && this.periodicFlusher.isAlive())) {
            stop("One or more threads are no longer alive -- stop");
            return false;
          }
      

      Please finger out if i am wrong. Thx

      Attachments

        1. HBASE-10627-0.94-v1.diff
          0.8 kB
          Shaohui Liu
        2. HBASE-10627-trunk-v1.diff
          0.9 kB
          Anoop Sam John

        Activity

          anoop.hbase Anoop Sam John added a comment -

          Oh!!
          Can u attach a patch for the fix. Thanks for reporting.

          anoop.hbase Anoop Sam John added a comment - Oh!! Can u attach a patch for the fix. Thanks for reporting.
          liushaohui Shaohui Liu added a comment -

          Fix the logic mistake

          liushaohui Shaohui Liu added a comment - Fix the logic mistake
          liushaohui Shaohui Liu added a comment -

          Patch for 0.94

          liushaohui Shaohui Liu added a comment - Patch for 0.94
          anoop.hbase Anoop Sam John added a comment -

          Reattaching trunk patch so that QA can pick this.

          anoop.hbase Anoop Sam John added a comment - Reattaching trunk patch so that QA can pick this.
          anoop.hbase Anoop Sam John added a comment -

          +1

          anoop.hbase Anoop Sam John added a comment - +1
          hadoopqa Hadoop QA added a comment -

          -1 overall. Here are the results of testing the latest attachment
          http://issues.apache.org/jira/secure/attachment/12631495/HBASE-10627-trunk-v1.diff
          against trunk revision .
          ATTACHMENT ID: 12631495

          +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 hadoop1.0. The patch compiles against the hadoop 1.0 profile.

          +1 hadoop1.1. The patch compiles against the hadoop 1.1 profile.

          +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 appears to introduce 2 new Findbugs (version 1.3.9) warnings.

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

          +1 lineLengths. The patch does not introduce lines longer than 100

          +1 site. The mvn site goal succeeds with this patch.

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

          Test results: https://builds.apache.org/job/PreCommit-HBASE-Build/8832//testReport/
          Findbugs warnings: https://builds.apache.org/job/PreCommit-HBASE-Build/8832//artifact/trunk/patchprocess/newPatchFindbugsWarningshbase-hadoop2-compat.html
          Findbugs warnings: https://builds.apache.org/job/PreCommit-HBASE-Build/8832//artifact/trunk/patchprocess/newPatchFindbugsWarningshbase-prefix-tree.html
          Findbugs warnings: https://builds.apache.org/job/PreCommit-HBASE-Build/8832//artifact/trunk/patchprocess/newPatchFindbugsWarningshbase-client.html
          Findbugs warnings: https://builds.apache.org/job/PreCommit-HBASE-Build/8832//artifact/trunk/patchprocess/newPatchFindbugsWarningshbase-common.html
          Findbugs warnings: https://builds.apache.org/job/PreCommit-HBASE-Build/8832//artifact/trunk/patchprocess/newPatchFindbugsWarningshbase-protocol.html
          Findbugs warnings: https://builds.apache.org/job/PreCommit-HBASE-Build/8832//artifact/trunk/patchprocess/newPatchFindbugsWarningshbase-server.html
          Findbugs warnings: https://builds.apache.org/job/PreCommit-HBASE-Build/8832//artifact/trunk/patchprocess/newPatchFindbugsWarningshbase-examples.html
          Findbugs warnings: https://builds.apache.org/job/PreCommit-HBASE-Build/8832//artifact/trunk/patchprocess/newPatchFindbugsWarningshbase-thrift.html
          Findbugs warnings: https://builds.apache.org/job/PreCommit-HBASE-Build/8832//artifact/trunk/patchprocess/newPatchFindbugsWarningshbase-hadoop-compat.html
          Console output: https://builds.apache.org/job/PreCommit-HBASE-Build/8832//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/12631495/HBASE-10627-trunk-v1.diff against trunk revision . ATTACHMENT ID: 12631495 +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 hadoop1.0 . The patch compiles against the hadoop 1.0 profile. +1 hadoop1.1 . The patch compiles against the hadoop 1.1 profile. +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 appears to introduce 2 new Findbugs (version 1.3.9) warnings. +1 release audit . The applied patch does not increase the total number of release audit warnings. +1 lineLengths . The patch does not introduce lines longer than 100 +1 site . The mvn site goal succeeds with this patch. +1 core tests . The patch passed unit tests in . Test results: https://builds.apache.org/job/PreCommit-HBASE-Build/8832//testReport/ Findbugs warnings: https://builds.apache.org/job/PreCommit-HBASE-Build/8832//artifact/trunk/patchprocess/newPatchFindbugsWarningshbase-hadoop2-compat.html Findbugs warnings: https://builds.apache.org/job/PreCommit-HBASE-Build/8832//artifact/trunk/patchprocess/newPatchFindbugsWarningshbase-prefix-tree.html Findbugs warnings: https://builds.apache.org/job/PreCommit-HBASE-Build/8832//artifact/trunk/patchprocess/newPatchFindbugsWarningshbase-client.html Findbugs warnings: https://builds.apache.org/job/PreCommit-HBASE-Build/8832//artifact/trunk/patchprocess/newPatchFindbugsWarningshbase-common.html Findbugs warnings: https://builds.apache.org/job/PreCommit-HBASE-Build/8832//artifact/trunk/patchprocess/newPatchFindbugsWarningshbase-protocol.html Findbugs warnings: https://builds.apache.org/job/PreCommit-HBASE-Build/8832//artifact/trunk/patchprocess/newPatchFindbugsWarningshbase-server.html Findbugs warnings: https://builds.apache.org/job/PreCommit-HBASE-Build/8832//artifact/trunk/patchprocess/newPatchFindbugsWarningshbase-examples.html Findbugs warnings: https://builds.apache.org/job/PreCommit-HBASE-Build/8832//artifact/trunk/patchprocess/newPatchFindbugsWarningshbase-thrift.html Findbugs warnings: https://builds.apache.org/job/PreCommit-HBASE-Build/8832//artifact/trunk/patchprocess/newPatchFindbugsWarningshbase-hadoop-compat.html Console output: https://builds.apache.org/job/PreCommit-HBASE-Build/8832//console This message is automatically generated.
          larsh Lars Hofhansl added a comment -

          Good find. +1

          larsh Lars Hofhansl added a comment - Good find. +1
          yuzhihong@gmail.com Ted Yu added a comment -

          Thanks for the patch, Shaohui.

          yuzhihong@gmail.com Ted Yu added a comment - Thanks for the patch, Shaohui.
          hudson Hudson added a comment -

          SUCCESS: Integrated in HBase-0.94-security #427 (See https://builds.apache.org/job/HBase-0.94-security/427/)
          HBASE-10627 A logic mistake in HRegionServer isHealthy (Shaohui) (tedyu: rev 1573016)

          • /hbase/branches/0.94/src/main/java/org/apache/hadoop/hbase/regionserver/HRegionServer.java
          hudson Hudson added a comment - SUCCESS: Integrated in HBase-0.94-security #427 (See https://builds.apache.org/job/HBase-0.94-security/427/ ) HBASE-10627 A logic mistake in HRegionServer isHealthy (Shaohui) (tedyu: rev 1573016) /hbase/branches/0.94/src/main/java/org/apache/hadoop/hbase/regionserver/HRegionServer.java
          hudson Hudson added a comment -

          FAILURE: Integrated in HBase-0.94-on-Hadoop-2 #37 (See https://builds.apache.org/job/HBase-0.94-on-Hadoop-2/37/)
          HBASE-10627 A logic mistake in HRegionServer isHealthy (Shaohui) (tedyu: rev 1573016)

          • /hbase/branches/0.94/src/main/java/org/apache/hadoop/hbase/regionserver/HRegionServer.java
          hudson Hudson added a comment - FAILURE: Integrated in HBase-0.94-on-Hadoop-2 #37 (See https://builds.apache.org/job/HBase-0.94-on-Hadoop-2/37/ ) HBASE-10627 A logic mistake in HRegionServer isHealthy (Shaohui) (tedyu: rev 1573016) /hbase/branches/0.94/src/main/java/org/apache/hadoop/hbase/regionserver/HRegionServer.java
          hudson Hudson added a comment -

          FAILURE: Integrated in hbase-0.96 #321 (See https://builds.apache.org/job/hbase-0.96/321/)
          HBASE-10627 A logic mistake in HRegionServer isHealthy (Shaohui) (tedyu: rev 1573015)

          • /hbase/branches/0.96/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/HRegionServer.java
          hudson Hudson added a comment - FAILURE: Integrated in hbase-0.96 #321 (See https://builds.apache.org/job/hbase-0.96/321/ ) HBASE-10627 A logic mistake in HRegionServer isHealthy (Shaohui) (tedyu: rev 1573015) /hbase/branches/0.96/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/HRegionServer.java
          hudson Hudson added a comment -

          FAILURE: Integrated in HBase-TRUNK #4966 (See https://builds.apache.org/job/HBase-TRUNK/4966/)
          HBASE-10627 A logic mistake in HRegionServer isHealthy (Shaohui) (tedyu: rev 1573012)

          • /hbase/trunk/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/HRegionServer.java
          hudson Hudson added a comment - FAILURE: Integrated in HBase-TRUNK #4966 (See https://builds.apache.org/job/HBase-TRUNK/4966/ ) HBASE-10627 A logic mistake in HRegionServer isHealthy (Shaohui) (tedyu: rev 1573012) /hbase/trunk/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/HRegionServer.java
          hudson Hudson added a comment -

          FAILURE: Integrated in HBase-0.94-JDK7 #69 (See https://builds.apache.org/job/HBase-0.94-JDK7/69/)
          HBASE-10627 A logic mistake in HRegionServer isHealthy (Shaohui) (tedyu: rev 1573016)

          • /hbase/branches/0.94/src/main/java/org/apache/hadoop/hbase/regionserver/HRegionServer.java
          hudson Hudson added a comment - FAILURE: Integrated in HBase-0.94-JDK7 #69 (See https://builds.apache.org/job/HBase-0.94-JDK7/69/ ) HBASE-10627 A logic mistake in HRegionServer isHealthy (Shaohui) (tedyu: rev 1573016) /hbase/branches/0.94/src/main/java/org/apache/hadoop/hbase/regionserver/HRegionServer.java
          hudson Hudson added a comment -

          FAILURE: Integrated in HBase-0.94 #1305 (See https://builds.apache.org/job/HBase-0.94/1305/)
          HBASE-10627 A logic mistake in HRegionServer isHealthy (Shaohui) (tedyu: rev 1573016)

          • /hbase/branches/0.94/src/main/java/org/apache/hadoop/hbase/regionserver/HRegionServer.java
          hudson Hudson added a comment - FAILURE: Integrated in HBase-0.94 #1305 (See https://builds.apache.org/job/HBase-0.94/1305/ ) HBASE-10627 A logic mistake in HRegionServer isHealthy (Shaohui) (tedyu: rev 1573016) /hbase/branches/0.94/src/main/java/org/apache/hadoop/hbase/regionserver/HRegionServer.java
          hudson Hudson added a comment -

          FAILURE: Integrated in HBase-0.98-on-Hadoop-1.1 #180 (See https://builds.apache.org/job/HBase-0.98-on-Hadoop-1.1/180/)
          HBASE-10627 A logic mistake in HRegionServer isHealthy (Shaohui) (tedyu: rev 1573013)

          • /hbase/branches/0.98/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/HRegionServer.java
          hudson Hudson added a comment - FAILURE: Integrated in HBase-0.98-on-Hadoop-1.1 #180 (See https://builds.apache.org/job/HBase-0.98-on-Hadoop-1.1/180/ ) HBASE-10627 A logic mistake in HRegionServer isHealthy (Shaohui) (tedyu: rev 1573013) /hbase/branches/0.98/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/HRegionServer.java
          hudson Hudson added a comment -

          FAILURE: Integrated in HBase-TRUNK-on-Hadoop-1.1 #102 (See https://builds.apache.org/job/HBase-TRUNK-on-Hadoop-1.1/102/)
          HBASE-10627 A logic mistake in HRegionServer isHealthy (Shaohui) (tedyu: rev 1573012)

          • /hbase/trunk/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/HRegionServer.java
          hudson Hudson added a comment - FAILURE: Integrated in HBase-TRUNK-on-Hadoop-1.1 #102 (See https://builds.apache.org/job/HBase-TRUNK-on-Hadoop-1.1/102/ ) HBASE-10627 A logic mistake in HRegionServer isHealthy (Shaohui) (tedyu: rev 1573012) /hbase/trunk/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/HRegionServer.java
          hudson Hudson added a comment -

          FAILURE: Integrated in hbase-0.96-hadoop2 #221 (See https://builds.apache.org/job/hbase-0.96-hadoop2/221/)
          HBASE-10627 A logic mistake in HRegionServer isHealthy (Shaohui) (tedyu: rev 1573015)

          • /hbase/branches/0.96/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/HRegionServer.java
          hudson Hudson added a comment - FAILURE: Integrated in hbase-0.96-hadoop2 #221 (See https://builds.apache.org/job/hbase-0.96-hadoop2/221/ ) HBASE-10627 A logic mistake in HRegionServer isHealthy (Shaohui) (tedyu: rev 1573015) /hbase/branches/0.96/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/HRegionServer.java
          hudson Hudson added a comment -

          SUCCESS: Integrated in HBase-0.98 #193 (See https://builds.apache.org/job/HBase-0.98/193/)
          HBASE-10627 A logic mistake in HRegionServer isHealthy (Shaohui) (tedyu: rev 1573013)

          • /hbase/branches/0.98/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/HRegionServer.java
          hudson Hudson added a comment - SUCCESS: Integrated in HBase-0.98 #193 (See https://builds.apache.org/job/HBase-0.98/193/ ) HBASE-10627 A logic mistake in HRegionServer isHealthy (Shaohui) (tedyu: rev 1573013) /hbase/branches/0.98/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/HRegionServer.java

          People

            liushaohui Shaohui Liu
            liushaohui Shaohui Liu
            Votes:
            0 Vote for this issue
            Watchers:
            8 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: