From 09873f9d32564a3a53c5424eb826d22162641bc5 Mon Sep 17 00:00:00 2001 From: larsh Date: Wed, 31 Oct 2012 22:02:09 +0000 Subject: [PATCH] HBASE-7051 CheckAndPut should properly read MVCC git-svn-id: https://svn.apache.org/repos/asf/hbase/trunk@1404377 13f79535-47bb-0310-9956-ffa450edef68 --- .../main/java/org/apache/hadoop/hbase/regionserver/HRegion.java | 2 ++ 1 file changed, 2 insertions(+) diff --git a/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/HRegion.java b/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/HRegion.java index a91fc490fdd..0169315d052 100644 --- a/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/HRegion.java +++ b/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/HRegion.java @@ -2395,6 +2395,8 @@ public class HRegion implements HeapSize { // , Writable{ // Lock row Integer lid = getLock(lockId, get.getRow(), true); + // wait for all previous transactions to complete (with lock held) + mvcc.completeMemstoreInsert(mvcc.beginMemstoreInsert()); List result = null; try { result = get(get, false);