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

ProtobufUtil seems to do extra array copying

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 1.3.2
    • Fix Version/s: 1.4.0, 1.2.6, 1.3.2, 1.1.11, 2.0.0
    • Component/s: None
    • Labels:
      None
    • Hadoop Flags:
      Reviewed

      Description

      In ProtobufUtil, the protobuf fields are copied into an array using toByteArray(). These are then passed into the KeyValue constructor which does another copy.

      It seems like we can avoid a copy here by using HBaseZeroCopyByteString#zeroCopyGetBytes() ?

        Attachments

        1. HBASE-18026.addendum.patch
          1 kB
          Vincent Poon
        2. HBASE-18026.master.v1.patch
          8 kB
          Vincent Poon
        3. HBASE-18026.branch-1.v1.patch
          9 kB
          Vincent Poon

          Activity

            People

            • Assignee:
              vincentpoon Vincent Poon
              Reporter:
              vincentpoon Vincent Poon
            • Votes:
              0 Vote for this issue
              Watchers:
              6 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: