hbase-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Jim Kellerman (JIRA)" <j...@apache.org>
Subject [jira] Commented: (HBASE-1202) getRow does not always work when specifying number of versions
Date Fri, 10 Apr 2009 18:13:14 GMT

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

Jim Kellerman commented on HBASE-1202:

I don't think numVersions being a count of all results is the issue. (but it is a problem
if it hasn't been fixed).

What the test does is:
1. store the value "value1" in column contents:contents at a specified timestamp.
2. shutdown and restart the cluster to force data to disk.
3. store the value "value2" in column contents:contents at the *same* timestamp as the first
4. call getRow(row) and it gets back "value2" as expected.
5. call getRow(row, HConstants.ALL_VERSIONS) and it gets back "value1" and not "value2"

But now I understand what is going on.

Cell contains a SortedMap<Long, byte[]> (where Long is the timestamp). So what happens
is that "value2" is fetched out of the memcache and then "value1" is fetched from disk and
because the timestamps are the same, overwrites the entry containing "value2". 

I think when we are looking for multiple versions, we need to check if we already have a match
for row/column/timestamp and not insert a second value if we already have one at that timestamp.

> getRow does not always work when specifying number of versions
> --------------------------------------------------------------
>                 Key: HBASE-1202
>                 URL: https://issues.apache.org/jira/browse/HBASE-1202
>             Project: Hadoop HBase
>          Issue Type: Bug
>          Components: regionserver
>    Affects Versions: 0.19.0, 0.19.1, 0.20.0
>            Reporter: Jim Kellerman
>            Assignee: Jim Kellerman
>             Fix For: 0.19.2, 0.20.0
>         Attachments: TestGetRowVersions.java
> When a cell that exists is updated, getRow specifying number of versions does not work.
> What is returned is the original value at that timestamp, instead of the updated value.
> Note that this only applies when more than one version is specified. getRow with (implied)
timestamp = latest does work.

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

View raw message