hbase-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From la...@apache.org
Subject [2/3] git commit: HBASE-11667 Comment ClientScanner logic for NSREs.
Date Wed, 06 Aug 2014 18:33:41 GMT
HBASE-11667 Comment ClientScanner logic for NSREs.


Project: http://git-wip-us.apache.org/repos/asf/hbase/repo
Commit: http://git-wip-us.apache.org/repos/asf/hbase/commit/fb8cc733
Tree: http://git-wip-us.apache.org/repos/asf/hbase/tree/fb8cc733
Diff: http://git-wip-us.apache.org/repos/asf/hbase/diff/fb8cc733

Branch: refs/heads/branch-1
Commit: fb8cc733edec3f86884cad19351b8e75484be6cf
Parents: 058ac50
Author: Lars Hofhansl <larsh@apache.org>
Authored: Wed Aug 6 11:28:11 2014 -0700
Committer: Lars Hofhansl <larsh@apache.org>
Committed: Wed Aug 6 11:28:56 2014 -0700

----------------------------------------------------------------------
 .../java/org/apache/hadoop/hbase/client/ClientScanner.java    | 7 +++++++
 1 file changed, 7 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/hbase/blob/fb8cc733/hbase-client/src/main/java/org/apache/hadoop/hbase/client/ClientScanner.java
----------------------------------------------------------------------
diff --git a/hbase-client/src/main/java/org/apache/hadoop/hbase/client/ClientScanner.java
b/hbase-client/src/main/java/org/apache/hadoop/hbase/client/ClientScanner.java
index d13f881..64a77f4 100644
--- a/hbase-client/src/main/java/org/apache/hadoop/hbase/client/ClientScanner.java
+++ b/hbase-client/src/main/java/org/apache/hadoop/hbase/client/ClientScanner.java
@@ -415,7 +415,14 @@ public class ClientScanner extends AbstractClientScanner {
             }
             // Else, its signal from depths of ScannerCallable that we need to reset the
scanner.
             if (this.lastResult != null) {
+              // The region has moved. We need to open a brand new scanner at
+              // the new location.
+              // Reset the startRow to the row we've seen last so that the new
+              // scanner starts at the correct row. Otherwise we may see previously
+              // returned rows again.
+              // (ScannerCallable by now has "relocated" the correct region)
               this.scan.setStartRow(this.lastResult.getRow());
+
               // Skip first row returned.  We already let it out on previous
               // invocation.
               skipFirst = true;


Mime
View raw message