hbase-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Wei Tan <w...@us.ibm.com>
Subject memstore timestamp and visible timestamp
Date Thu, 02 Aug 2012 22:35:46 GMT

  I have a question regarding the correlation between the visible 
timestamp of a KV (denoted as ts) and its memstore timestamp (aka, the 
write number, denoted as memts). Reading the HRegion.java code it seems 
that these two are independently assigned. Let's assume two concurrent 
put: (k, v1) and (k, v2)

  Suppose somehow memts(k,v1) < memts(k, v2) then (k,v1) will be committed 
and visible before (k,v2). 
If ts(k,v1) < ts(k, v2), then after both KVs commits, (k,v2) becomes the 
latest version.
else, if ts(k,v1) > ts(k, v2), then after a "later"(w.r.t. MVCC) KV 
commits, it immediately become stale and still not visible. --- Is it a 
desirable feature?

  Am I understanding it correctly, that memts(k,v1) < memts(k, v2) does 
not indicate that ts(k,v1) < ts(k, v2), and vice versa? 
PS: let's talk about the hbase region server assigned, not user assigned, 
visible timestamp.



Best Regards,

Wei Tan 
Research Staff Member 
IBM T. J. Watson Research Center
19 Skyline Dr, Hawthorne, NY  10532
wtan@us.ibm.com; 914-784-6752
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message