You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@phoenix.apache.org by gj...@apache.org on 2020/04/09 23:25:32 UTC

[phoenix] branch 4.x updated: PHOENIX-5799 - Inline Index Verification Output API (addendum for HBase 1.3 support)

This is an automated email from the ASF dual-hosted git repository.

gjacoby pushed a commit to branch 4.x
in repository https://gitbox.apache.org/repos/asf/phoenix.git


The following commit(s) were added to refs/heads/4.x by this push:
     new ea9c4eb  PHOENIX-5799 - Inline Index Verification Output API (addendum for HBase 1.3 support)
ea9c4eb is described below

commit ea9c4eb0cdfff9a3cb7c885b8aa985a77e4a1382
Author: Geoffrey Jacoby <gj...@apache.org>
AuthorDate: Thu Apr 9 16:20:35 2020 -0700

    PHOENIX-5799 - Inline Index Verification Output API (addendum for HBase 1.3 support)
---
 .../phoenix/mapreduce/index/IndexVerificationOutputRepository.java   | 5 +++--
 .../phoenix/mapreduce/index/IndexVerificationResultRepository.java   | 5 +++--
 2 files changed, 6 insertions(+), 4 deletions(-)

diff --git a/phoenix-core/src/main/java/org/apache/phoenix/mapreduce/index/IndexVerificationOutputRepository.java b/phoenix-core/src/main/java/org/apache/phoenix/mapreduce/index/IndexVerificationOutputRepository.java
index bcc2e73..dbe4315 100644
--- a/phoenix-core/src/main/java/org/apache/phoenix/mapreduce/index/IndexVerificationOutputRepository.java
+++ b/phoenix-core/src/main/java/org/apache/phoenix/mapreduce/index/IndexVerificationOutputRepository.java
@@ -28,6 +28,7 @@ import org.apache.hadoop.hbase.client.ResultScanner;
 import org.apache.hadoop.hbase.client.Scan;
 import org.apache.hadoop.hbase.client.Table;
 import org.apache.hadoop.hbase.util.Bytes;
+import org.apache.phoenix.compat.hbase.CompatUtil;
 import org.apache.phoenix.coprocessor.MetaDataProtocol;
 import org.apache.phoenix.hbase.index.table.HTableFactory;
 import org.apache.phoenix.hbase.index.util.ImmutableBytesPtr;
@@ -221,8 +222,8 @@ public class IndexVerificationOutputRepository implements AutoCloseable {
         throws IOException {
         Scan scan = new Scan();
         byte[] partialKey = generatePartialOutputTableRowKey(ts, indexName);
-        scan.withStartRow(partialKey);
-        scan.withStopRow(ByteUtil.calculateTheClosestNextRowKeyForPrefix(partialKey));
+        scan.setStartRow(partialKey);
+        scan.setStopRow(ByteUtil.calculateTheClosestNextRowKeyForPrefix(partialKey));
         ResultScanner scanner = outputTable.getScanner(scan);
         return new IndexVerificationOutputRowIterator(scanner.iterator());
     }
diff --git a/phoenix-core/src/main/java/org/apache/phoenix/mapreduce/index/IndexVerificationResultRepository.java b/phoenix-core/src/main/java/org/apache/phoenix/mapreduce/index/IndexVerificationResultRepository.java
index ca8b129..cab66b2 100644
--- a/phoenix-core/src/main/java/org/apache/phoenix/mapreduce/index/IndexVerificationResultRepository.java
+++ b/phoenix-core/src/main/java/org/apache/phoenix/mapreduce/index/IndexVerificationResultRepository.java
@@ -28,6 +28,7 @@ import org.apache.hadoop.hbase.client.ResultScanner;
 import org.apache.hadoop.hbase.client.Scan;
 import org.apache.hadoop.hbase.client.Table;
 import org.apache.hadoop.hbase.util.Bytes;
+import org.apache.phoenix.compat.hbase.CompatUtil;
 import org.apache.phoenix.coprocessor.IndexToolVerificationResult;
 import org.apache.phoenix.coprocessor.MetaDataProtocol;
 import org.apache.phoenix.hbase.index.table.HTableFactory;
@@ -219,8 +220,8 @@ public class IndexVerificationResultRepository implements AutoCloseable {
         byte[] stopRowKey = ByteUtil.calculateTheClosestNextRowKeyForPrefix(startRowKey);
         IndexToolVerificationResult verificationResult = new IndexToolVerificationResult(ts);
         Scan scan = new Scan();
-        scan.withStartRow(startRowKey);
-        scan.withStopRow(stopRowKey);
+        scan.setStartRow(startRowKey);
+        scan.setStopRow(stopRowKey);
         ResultScanner scanner = htable.getScanner(scan);
         for (Result result = scanner.next(); result != null; result = scanner.next()) {
             boolean isFirst = true;