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

Replace HashMap to Array for DataBlockEncoding.idToEncoding

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • 1.4.0, 2.0.0
    • 1.4.0, 2.0.0
    • None
    • None

    Description

      Array is faster than HashMap also no need to autoboxing.
      I can see the DataBlockEncoding#getDataBlockEncoderById is a hot method if enable encoding in my perf test(Random read, all data cache in LruBlockCache).

      Attachments

        1. HBASE-17332.branch-1.V1.patch
          6 kB
          Lijin Bin
        2. HBASE-17332.V3.patch
          6 kB
          Lijin Bin
        3. HBASE-17332.V2.patch
          7 kB
          Lijin Bin
        4. HBASE-17332.patch
          6 kB
          Lijin Bin
        5. DBE.idToEncoding_afterOptimize.png
          836 kB
          Lijin Bin
        6. DBE.idToEncoding.png
          871 kB
          Lijin Bin

        Activity

          People

            binlijin Lijin Bin
            binlijin Lijin Bin
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: