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

reduce overhead of maintaing get/next size metric

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Major
    • Resolution: Abandoned
    • None
    • None
    • None

    Description

      [Forked off this specific issue as a separate JIRA from HBASE-6066].

      Reduce overhead of "size metric" maintained in StoreScanner.next().

      if (metric != null) {
           HRegion.incrNumericMetric(this.metricNamePrefix + metric,
                                     copyKv.getLength());
        }
        results.add(copyKv);
      

      A single call to next() might fetch a lot of KVs. We can first add up the size of those KVs in a local variable and then in a finally clause increment the metric one shot, rather than updating AtomicLongs for each KV.

      Attachments

        1. jira-6217.patch
          2 kB
          M. Chen

        Activity

          People

            Unassigned Unassigned
            kannanm Kannan Muthukkaruppan
            Votes:
            0 Vote for this issue
            Watchers:
            8 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: