hbase-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Phabricator (Commented) (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (HBASE-5241) Deletes should not mask Puts that come after it.
Date Sat, 03 Mar 2012 17:57:57 GMT

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

Phabricator commented on HBASE-5241:

aaiyer has commented on the revision "HBASE-5241 [jira] Deletes should not mask Puts that
come after it.".

  src/main/java/org/apache/hadoop/hbase/regionserver/Store.java:609 It seems like going for
stronger read semantics would disable the space savings we get by storing the memstoreTS as
a (1 byte) Zero value, instead of the actual value.

  Perhaps, one way to get similar savings would be to store the actual memstoreTS in the variable
length encoding, after differential encoding.

   Here is what I propose.
      Keep track of a per-StoreFile startMemstoreTS value, that (approximately) keeps track
of the smallest memstoreTS in the file.

     KV's will store the deltas such that KV's-memstoreTS = StoreFile's-startMemstoreTS +

     If the delta is small enough, we will only use 1 or 2 bytes for storing it. Since we
use Bytes.writeVLong: From the java docs:

  if n in [-32, 127): encode in one byte with the actual value. Otherwise,
  if n in [-20*2^8, 20*2^8): encode in two bytes: byte[0] = n/256 - 52; byte[1]=n&0xff.


> Deletes should not mask Puts that come after it.
> ------------------------------------------------
>                 Key: HBASE-5241
>                 URL: https://issues.apache.org/jira/browse/HBASE-5241
>             Project: HBase
>          Issue Type: Improvement
>            Reporter: Amitanand Aiyer
>            Assignee: Amitanand Aiyer
>         Attachments: HBASE-5241.D1731.1.patch, HBASE-5241.D1731.2.patch, HBASE-5241.D1731.3.patch
> Suppose that we have a delete row, and then followed by the put. The delete row
> can mask the put, unless there was a major compaction in between.
> Now that we are flushing the memstoreTS to disk, along with the KVs, we should be able
> to differentiate whether or not the Put happened after the Delete and offer better 
> delete semantics.
> Couldn't find a pre-existing JIRA that already discusses this, so creating one.
> Seems related to https://issues.apache.org/jira/browse/HBASE-2406, but is not quite the

This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira


View raw message