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

kadir pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/phoenix.git


The following commit(s) were added to refs/heads/master by this push:
     new 43fcb9d  PHOENIX-5473 Index write failures during index rebuilds 
should not change index table state (addendum)
43fcb9d is described below

commit 43fcb9d0bb4e7f192529044064ae448089f18863
Author: Kadir <kozde...@salesforce.com>
AuthorDate: Mon Sep 16 14:00:57 2019 -0700

    PHOENIX-5473 Index write failures during index rebuilds should not change 
index table state (addendum)
---
 .../org/apache/phoenix/end2end/index/MutableIndexRebuilderIT.java     | 4 ++--
 .../apache/phoenix/coprocessor/UngroupedAggregateRegionObserver.java  | 3 ---
 2 files changed, 2 insertions(+), 5 deletions(-)

diff --git 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/index/MutableIndexRebuilderIT.java
 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/index/MutableIndexRebuilderIT.java
index b974ca0..5f27eb9 100644
--- 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/index/MutableIndexRebuilderIT.java
+++ 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/index/MutableIndexRebuilderIT.java
@@ -75,7 +75,7 @@ public class MutableIndexRebuilderIT extends 
BaseUniqueNamesOwnClusterIT {
      */
     @Test
     public void testRebuildRetriesSuccessful() throws Throwable {
-        int numberOfRetries = 3;
+        int numberOfRetries = 5;
         Map<String, String> serverProps = Maps.newHashMapWithExpectedSize(10);
         serverProps.put(QueryServices.INDEX_FAILURE_HANDLING_REBUILD_ATTRIB, 
Boolean.TRUE.toString());
         
serverProps.put(QueryServices.INDEX_FAILURE_HANDLING_REBUILD_INTERVAL_ATTRIB, 
Long.toString(REBUILD_INTERVAL));
@@ -157,7 +157,7 @@ public class MutableIndexRebuilderIT extends 
BaseUniqueNamesOwnClusterIT {
         @Override
         public void 
postBatchMutate(ObserverContext<RegionCoprocessorEnvironment> c, 
MiniBatchOperationInProgress<Mutation> miniBatchOp) throws IOException {
             attempts.incrementAndGet();
-            throw new TimeoutIOException("Simulating write failure on " + 
c.getEnvironment().getRegionInfo().getTable().getNameAsString());
+            throw new DoNotRetryIOException("Simulating write failure on " + 
c.getEnvironment().getRegionInfo().getTable().getNameAsString());
         }
     }
 }
diff --git 
a/phoenix-core/src/main/java/org/apache/phoenix/coprocessor/UngroupedAggregateRegionObserver.java
 
b/phoenix-core/src/main/java/org/apache/phoenix/coprocessor/UngroupedAggregateRegionObserver.java
index 3dadf7a..3d54dbc 100644
--- 
a/phoenix-core/src/main/java/org/apache/phoenix/coprocessor/UngroupedAggregateRegionObserver.java
+++ 
b/phoenix-core/src/main/java/org/apache/phoenix/coprocessor/UngroupedAggregateRegionObserver.java
@@ -260,9 +260,6 @@ public class UngroupedAggregateRegionObserver extends 
BaseScannerRegionObserver
         try {
             commitBatch(region, localRegionMutations, blockingMemstoreSize);
         } catch (IOException e) {
-            if (e instanceof DoNotRetryIOException) {
-                throw(e);
-            }
             handleIndexWriteException(localRegionMutations, e, new 
MutateCommand() {
                 @Override
                 public void doMutation() throws IOException {

Reply via email to