hbase-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ramkrishna vasudevan <ramkrishna.s.vasude...@gmail.com>
Subject Re: HBase versions problem
Date Fri, 16 Oct 2015 08:10:17 GMT
With VERSIONS=>1 and MIN_VERSIONS=0, I think the intended behaviour is to
always have the current version as the one to be returned. So in your cases
you inserted two cells at different timestamp. But the Delete with
addColumn will always try to delete the latest version.  So in this case
the latest version happens to be the value 2 version.  Hence for C1 that
value got masked and whether u do the flush or not you always end up in the
value 1 cell. (ie the first one).

Coming to the family 2 where you want atleast one version to be maintained
. I need to check the code more thoroughly to determine the behaviour
difference between flush and no flush.

REgards
Ram

On Fri, Oct 16, 2015 at 1:05 PM, mukund murrali <mukundmurrali9@gmail.com>
wrote:

> Can anyone enlighten why this is happening. This is causing problems in our
> production.
>
> On Thu, Oct 15, 2015 at 4:15 PM, mukund murrali <mukundmurrali9@gmail.com>
> wrote:
>
> > Hi
> >
> > I am using hbase-1.0. I had two column families C1 and C2.
> >
> > C1 => 'VERSIONS => 1, MIN_VERSIONS => 0 (default)
> > C2 => 'VERSIONS' => 1, MIN_VERSIONS => 1
> >
> > I inserted two versions as follows
> > put 'test','ro1','C1:col1,'value1'
> > put 'test','ro1','C2:col1,'value1'
> >
> >
> > put 'test','ro1','C1:col1,'value2'
> > put 'test','ro1','C2:col1,'value2'
> >
> > I did a delete using java API with addColumn ( not Columns) for both C1
> > and C2 column families. On a get call I got the result as
> >
> > C1:col1                           timestamp=1444904709797,value=value1
> >
> > C2:col1                            timestamp=1444904695656, value=value1
> >
> > on doing a *flush* on the table, the C2 data got vanished and subsequent
> > get call returned with first version of C1.
> >
> > C1:col1                           timestamp=1444904709797,value=value1
> >
> > On deeper analysis, we found that a flush before delete will purge both
> of
> > those data.
> >
> > My question is with MIN_VERSIONS => 0 and VERSIONS => 1, why does the
> > second version gets promoted during deletion and does not get removed
> even
> > after flush?
> >
> > In other words with VERSIONS =>1 , why should the earlier versions be
> > stored?
> >
> > Also with MIN_VERSIONS => 1 and VERSIONS => 1, though the second version
> > promoted but subsequent flush purged it.
> >
> > Is this an inconsistency or my understanding is wrong?
> >
> > Thanks
> >
> > Regards
> > Mukund Murrali
> >
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message