You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@hbase.apache.org by "Jonathan Gray (JIRA)" <ji...@apache.org> on 2011/01/09 14:16:45 UTC

[jira] Commented: (HBASE-3433) Remove the KV copy of every KV in Scan; introduced by HBASE-3232 (why doesn't keyonlyfilter make copies rather than mutate -- HBASE-3211)?

    [ https://issues.apache.org/jira/browse/HBASE-3433?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12979318#action_12979318 ] 

Jonathan Gray commented on HBASE-3433:
--------------------------------------

This is only a shallow copy.

> Remove the KV copy of every KV in Scan; introduced by HBASE-3232 (why doesn't keyonlyfilter make copies rather than mutate -- HBASE-3211)?
> ------------------------------------------------------------------------------------------------------------------------------------------
>
>                 Key: HBASE-3433
>                 URL: https://issues.apache.org/jira/browse/HBASE-3433
>             Project: HBase
>          Issue Type: Improvement
>            Reporter: stack
>            Priority: Critical
>             Fix For: 0.92.0
>
>
> Here is offending code from inside in StoreScanner#next:
> {code}
>       // kv is no longer immutable due to KeyOnlyFilter! use copy for safety
>       KeyValue copyKv = new KeyValue(kv.getBuffer(), kv.getOffset(), kv.getLength());
> {code}
> This looks wrong given philosophy up to this has been avoidance of garbage-making copies.
> Maybe this has been looked into before and this is the only thing to be done but why is KeyOnlyFilter not making copies rather than mutating originals?
> Making this critical against 0.92.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.