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

Can't enable a table on a 0.94 cluster from a 0.92 client

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 0.92.2, 0.94.2
    • Component/s: None
    • Labels:
      None
    • Hadoop Flags:
      Reviewed

      Description

      In 0.92 we know a table's enabled by doing this in HCM.isEnabledTable:

      return getTableState(zkw, tableName) == null;

      In 0.94 we do:

      return getTableState(zkw, tableName) == TableState.ENABLED;

      So what happens is that the the 0.92 client will hang forever since the znode contains ENABLED instead of being absent.

      1. 6268-92.txt
        0.7 kB
        Ted Yu
      2. 6268-94.txt
        0.7 kB
        Lars Hofhansl

        Activity

        Hide
        ram_krish ramkrishna.s.vasudevan added a comment -

        https://issues.apache.org/jira/browse/HBASE-5206 caused this. Infact in 0.90 HBASE-5904 has been raised to back out HBASE-5155.
        So the same problem is happening here. .
        Do we need to back out here also?

        Show
        ram_krish ramkrishna.s.vasudevan added a comment - https://issues.apache.org/jira/browse/HBASE-5206 caused this. Infact in 0.90 HBASE-5904 has been raised to back out HBASE-5155 . So the same problem is happening here. . Do we need to back out here also?
        Hide
        lhofhansl Lars Hofhansl added a comment -

        Sigh... It seems we cannot easily fix this 0.94.1, since we'd have to roll back a bigger change. Is 0.92.2 good enough, though?
        The 0.92 fix is obviously trivial just check for TableState.ENABLED or null.

        Show
        lhofhansl Lars Hofhansl added a comment - Sigh... It seems we cannot easily fix this 0.94.1, since we'd have to roll back a bigger change. Is 0.92.2 good enough, though? The 0.92 fix is obviously trivial just check for TableState.ENABLED or null.
        Hide
        jdcryans Jean-Daniel Cryans added a comment -

        This is why I'm not a big fan of backports that are not simple-ish fixes...

        So to me the most important would be to fix the 0.92 side as usually the infrastructure in place will rely on the older version first. In our case we started the migration of our clusters to 0.94 starting with the less important ones so our tools are still relying on 0.92

        Show
        jdcryans Jean-Daniel Cryans added a comment - This is why I'm not a big fan of backports that are not simple-ish fixes... So to me the most important would be to fix the 0.92 side as usually the infrastructure in place will rely on the older version first. In our case we started the migration of our clusters to 0.94 starting with the less important ones so our tools are still relying on 0.92
        Hide
        yuzhihong@gmail.com Ted Yu added a comment -

        Patch as suggested by Lars.

        Show
        yuzhihong@gmail.com Ted Yu added a comment - Patch as suggested by Lars.
        Hide
        stack stack added a comment -

        Patch looks like it covers both cases +1

        Show
        stack stack added a comment - Patch looks like it covers both cases +1
        Hide
        lhofhansl Lars Hofhansl added a comment -

        +1 on patch.
        I apologize to not have caught this in 0.94.0 (HBASE-5206).

        Show
        lhofhansl Lars Hofhansl added a comment - +1 on patch. I apologize to not have caught this in 0.94.0 ( HBASE-5206 ).
        Hide
        stack stack added a comment -

        Committed to 0.92.0

        Show
        stack stack added a comment - Committed to 0.92.0
        Hide
        hudson Hudson added a comment -

        Integrated in HBase-0.92 #549 (See https://builds.apache.org/job/HBase-0.92/549/)
        HBASE-6268 Can't enable a table on a 0.94 cluster from a 0.92 client (Revision 1379292)

        Result = FAILURE
        stack :
        Files :

        • /hbase/branches/0.92/src/main/java/org/apache/hadoop/hbase/zookeeper/ZKTable.java
        Show
        hudson Hudson added a comment - Integrated in HBase-0.92 #549 (See https://builds.apache.org/job/HBase-0.92/549/ ) HBASE-6268 Can't enable a table on a 0.94 cluster from a 0.92 client (Revision 1379292) Result = FAILURE stack : Files : /hbase/branches/0.92/src/main/java/org/apache/hadoop/hbase/zookeeper/ZKTable.java
        Hide
        hudson Hudson added a comment -

        Integrated in HBase-0.92-security #129 (See https://builds.apache.org/job/HBase-0.92-security/129/)
        HBASE-6268 Can't enable a table on a 0.94 cluster from a 0.92 client (Revision 1379292)

        Result = FAILURE
        stack :
        Files :

        • /hbase/branches/0.92/src/main/java/org/apache/hadoop/hbase/zookeeper/ZKTable.java
        Show
        hudson Hudson added a comment - Integrated in HBase-0.92-security #129 (See https://builds.apache.org/job/HBase-0.92-security/129/ ) HBASE-6268 Can't enable a table on a 0.94 cluster from a 0.92 client (Revision 1379292) Result = FAILURE stack : Files : /hbase/branches/0.92/src/main/java/org/apache/hadoop/hbase/zookeeper/ZKTable.java
        Hide
        gchanan Gregory Chanan added a comment -

        I'm not sure I agree with this patch. I'll bring up something on the dev list.

        Show
        gchanan Gregory Chanan added a comment - I'm not sure I agree with this patch. I'll bring up something on the dev list.
        Hide
        jmhsieh Jonathan Hsieh added a comment -

        I'm a bit concerned about this – i think there are people using 0.92.1 and those clients should work againt the newer 0.94's (which has fewer users since is newer). We'll start a discussion on the dev list.

        Show
        jmhsieh Jonathan Hsieh added a comment - I'm a bit concerned about this – i think there are people using 0.92.1 and those clients should work againt the newer 0.94's (which has fewer users since is newer). We'll start a discussion on the dev list.
        Hide
        gchanan Gregory Chanan added a comment -

        Brought up on dev list under the title "0.92/0.94 compatibility and HBASE-5206." My issue is more with leaving in HBASE-5206 as is in 0.94.2 – I probably should have posted on that JIRA. Sorry about that.

        My reading of this patch is that it will work whether we leave in HBASE-5206 or we do the change I propose on the e-mail (moving the enabled state to a different znode). Do you agree, Ted/Lars?

        One nit about the patch, the comment on the isEnabledTable function is no longer valid:

           * Go to zookeeper and see if state of table is {@link TableState#ENABLED}.
        

        but the state doesn't have to be enabled, it can also be null (and should probably point to this JIRA to explain why both are valid?).

        Show
        gchanan Gregory Chanan added a comment - Brought up on dev list under the title "0.92/0.94 compatibility and HBASE-5206 ." My issue is more with leaving in HBASE-5206 as is in 0.94.2 – I probably should have posted on that JIRA. Sorry about that. My reading of this patch is that it will work whether we leave in HBASE-5206 or we do the change I propose on the e-mail (moving the enabled state to a different znode). Do you agree, Ted/Lars? One nit about the patch, the comment on the isEnabledTable function is no longer valid: * Go to zookeeper and see if state of table is {@link TableState#ENABLED}. but the state doesn't have to be enabled, it can also be null (and should probably point to this JIRA to explain why both are valid?).
        Hide
        yuzhihong@gmail.com Ted Yu added a comment -

        I think Gregory's post makes sense.

        I will wait for further validation result against 0.92.2 RC1 and watch out the discussion thread.

        Show
        yuzhihong@gmail.com Ted Yu added a comment - I think Gregory's post makes sense. I will wait for further validation result against 0.92.2 RC1 and watch out the discussion thread.
        Hide
        lhofhansl Lars Hofhansl added a comment -

        0.94 patch.

        Show
        lhofhansl Lars Hofhansl added a comment - 0.94 patch.
        Hide
        lhofhansl Lars Hofhansl added a comment -

        I'll commit that to 0.94.

        Show
        lhofhansl Lars Hofhansl added a comment - I'll commit that to 0.94.
        Hide
        gchanan Gregory Chanan added a comment -

        patch lgtm.

        Show
        gchanan Gregory Chanan added a comment - patch lgtm.
        Hide
        stack stack added a comment -

        +1 on patch for 0.94

        Show
        stack stack added a comment - +1 on patch for 0.94
        Hide
        lhofhansl Lars Hofhansl added a comment -

        Committed 0.94 patch as well.

        Show
        lhofhansl Lars Hofhansl added a comment - Committed 0.94 patch as well.
        Hide
        hudson Hudson added a comment -

        Integrated in HBase-0.94 #446 (See https://builds.apache.org/job/HBase-0.94/446/)
        HBASE-6268 Can't enable a table on a 0.94 cluster from a 0.92 client (Revision 1379688)

        Result = FAILURE
        larsh :
        Files :

        • /hbase/branches/0.94/src/main/java/org/apache/hadoop/hbase/zookeeper/ZKTable.java
        Show
        hudson Hudson added a comment - Integrated in HBase-0.94 #446 (See https://builds.apache.org/job/HBase-0.94/446/ ) HBASE-6268 Can't enable a table on a 0.94 cluster from a 0.92 client (Revision 1379688) Result = FAILURE larsh : Files : /hbase/branches/0.94/src/main/java/org/apache/hadoop/hbase/zookeeper/ZKTable.java
        Hide
        hudson Hudson added a comment -

        Integrated in HBase-0.94-security #51 (See https://builds.apache.org/job/HBase-0.94-security/51/)
        HBASE-6268 Can't enable a table on a 0.94 cluster from a 0.92 client (Revision 1379688)

        Result = FAILURE
        larsh :
        Files :

        • /hbase/branches/0.94/src/main/java/org/apache/hadoop/hbase/zookeeper/ZKTable.java
        Show
        hudson Hudson added a comment - Integrated in HBase-0.94-security #51 (See https://builds.apache.org/job/HBase-0.94-security/51/ ) HBASE-6268 Can't enable a table on a 0.94 cluster from a 0.92 client (Revision 1379688) Result = FAILURE larsh : Files : /hbase/branches/0.94/src/main/java/org/apache/hadoop/hbase/zookeeper/ZKTable.java
        Hide
        hudson Hudson added a comment -

        Integrated in HBase-0.94-security-on-Hadoop-23 #7 (See https://builds.apache.org/job/HBase-0.94-security-on-Hadoop-23/7/)
        HBASE-6268 Can't enable a table on a 0.94 cluster from a 0.92 client (Revision 1379688)

        Result = FAILURE
        larsh :
        Files :

        • /hbase/branches/0.94/src/main/java/org/apache/hadoop/hbase/zookeeper/ZKTable.java
        Show
        hudson Hudson added a comment - Integrated in HBase-0.94-security-on-Hadoop-23 #7 (See https://builds.apache.org/job/HBase-0.94-security-on-Hadoop-23/7/ ) HBASE-6268 Can't enable a table on a 0.94 cluster from a 0.92 client (Revision 1379688) Result = FAILURE larsh : Files : /hbase/branches/0.94/src/main/java/org/apache/hadoop/hbase/zookeeper/ZKTable.java

          People

          • Assignee:
            yuzhihong@gmail.com Ted Yu
            Reporter:
            jdcryans Jean-Daniel Cryans
          • Votes:
            0 Vote for this issue
            Watchers:
            10 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development