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

CreateTableProcedure/ModifyTableProcedure needs to fail when there is no family in table descriptor

    Details

    • Type: Improvement
    • Status: Resolved
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 2.0.0
    • Fix Version/s: 1.3.0, 2.0.0
    • Component/s: master
    • Labels:
      None
    • Hadoop Flags:
      Reviewed

      Description

      If there is only one family in the table, DeleteColumnFamilyProcedure will fail.
      Currently, when hbase.table.sanity.checks is set to false, hbase master logs a warning and CreateTableProcedure/ModifyTableProcedure will succeed.
      This behavior is not consistent with DeleteColumnFamilyProcedure's.

      Another point, before HBASE-13145, PeriodicMemstoreFlusher will run into the following exception. lastStoreFlushTimeMap is populated for families, if there is no family in the table, there is no entry in lastStoreFlushTimeMap.

      16/02/01 11:14:26 ERROR regionserver.HRegionServer$PeriodicMemstoreFlusher: Caught exception 
      java.util.NoSuchElementException 
      at java.util.concurrent.ConcurrentHashMap$HashIterator.nextEntry(ConcurrentHashMap.java:1354) 
      at java.util.concurrent.ConcurrentHashMap$ValueIterator.next(ConcurrentHashMap.java:1384) 
      at java.util.Collections.min(Collections.java:628) 
      at org.apache.hadoop.hbase.regionserver.HRegion.getEarliestFlushTimeForAllStores(HRegion.java:1572) 
      at org.apache.hadoop.hbase.regionserver.HRegion.shouldFlush(HRegion.java:1904) 
      at org.apache.hadoop.hbase.regionserver.HRegionServer$PeriodicMemstoreFlusher.chore(HRegionServer.java:1509) 
      at org.apache.hadoop.hbase.Chore.run(Chore.java:87) 
      at java.lang.Thread.run(Thread.java:745) 
      

        Attachments

        1. HBASE-15456-001_branch-1.patch
          19 kB
          huaxiang sun
        2. HBASE-15456-branch-1_v002.patch
          20 kB
          huaxiang sun
        3. HBASE-15456-branch-1.patch
          19 kB
          huaxiang sun
        4. HBASE-15456-branch-1.patch
          19 kB
          huaxiang sun
        5. HBASE-15456-v001.patch
          13 kB
          huaxiang sun
        6. HBASE-15456-v002.patch
          17 kB
          huaxiang sun
        7. HBASE-15456-v002.patch
          17 kB
          huaxiang sun
        8. HBASE-15456-v003.patch
          17 kB
          huaxiang sun
        9. HBASE-15456-v004.patch
          18 kB
          huaxiang sun

          Activity

            People

            • Assignee:
              huaxiang huaxiang sun
              Reporter:
              huaxiang huaxiang sun
            • Votes:
              0 Vote for this issue
              Watchers:
              6 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: