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

Better key splitting in RegionSplitter

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 0.90.4
    • 0.94.0
    • None
    • None
    • Hide
      The split algorithm used by RegionSplitter is now a required parameter. Previously there was one split algorithm called MD5StringSplit, which was the default. MD5StringSplit has been renamed to HexStringSplit, and tweaked so that its maximum key is now "FFFFFFFF" instead of "7FFFFFFF. A new split algorithm UniformSplit has been added which treats keys as arbitrary bytes.
      Show
      The split algorithm used by RegionSplitter is now a required parameter. Previously there was one split algorithm called MD5StringSplit, which was the default. MD5StringSplit has been renamed to HexStringSplit, and tweaked so that its maximum key is now "FFFFFFFF" instead of "7FFFFFFF. A new split algorithm UniformSplit has been added which treats keys as arbitrary bytes.

    Description

      The RegionSplitter utility allows users to create a pre-split table from the command line or do a rolling split on an existing table. It supports pluggable split algorithms that implement the SplitAlgorithm interface. The only/default SplitAlgorithm is one that assumes keys fall in the range from ASCII string "00000000" to ASCII string "7FFFFFFF". This is not a sane default, and seems useless to most users. Users are likely to be surprised by the fact that all the region splits occur in in the byte range of ASCII characters.

      A better default split algorithm would be one that evenly divides the space of all bytes, which is what this patch does. Making a table with five regions would split at \x33\x33..., \x66\x66...., \x99\x99..., \xCC\xCC..., and \xFF\xFF.

      Attachments

        1. HBASE-4489-trunk-v5.patch
          29 kB
          Dave Revell
        2. HBASE-4489-trunk-v4.patch
          28 kB
          Dave Revell
        3. HBASE-4489-trunk-v3.patch
          20 kB
          Dave Revell
        4. HBASE-4489-trunk-v2.patch
          15 kB
          Dave Revell
        5. HBASE-4489-trunk-v1.patch
          4 kB
          Dave Revell
        6. HBASE-4489-branch0.90-v3.patch
          19 kB
          Dave Revell
        7. HBASE-4489-branch0.90-v2.patch
          15 kB
          Dave Revell
        8. HBASE-4489-branch0.90-v1.patch
          4 kB
          Dave Revell

        Issue Links

          Activity

            People

              dave_revell Dave Revell
              dave_revell Dave Revell
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: