[
https://issues.apache.org/jira/browse/HBASE-9935?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13818282#comment-13818282
]
Lars Hofhansl commented on HBASE-9935:
--------------------------------------
Looking at KeyValue. The overall static size is still 68 bytes. 4 of which are
actually to cache the keyLength already. Adding 2 bytes to that might well
worth the effort. (Right now I am trying what happens when I *remove* 4 byte
cache for the keyLength).
> Slight perf improvement: Avoid KeyValue.getRowLength() at some places
> ---------------------------------------------------------------------
>
> Key: HBASE-9935
> URL: https://issues.apache.org/jira/browse/HBASE-9935
> Project: HBase
> Issue Type: Bug
> Reporter: Lars Hofhansl
>
> Here's an example:
> {code}
> KeyValue.createLastOnRow(
> kv.getBuffer(), kv.getRowOffset(), kv.getRowLength(),
> kv.getBuffer(), kv.getFamilyOffset(), kv.getFamilyLength(),
> kv.getBuffer(), kv.getQualifierOffset(), kv.getQualifierLength());
> {code}
> Looks harmless enough, but that actually recalculates the rowlength 5 times.
> And each time it needs to decode the rowlength again from the bytes of the KV.
--
This message was sent by Atlassian JIRA
(v6.1#6144)