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

kturner pushed a commit to branch 3.1
in repository https://gitbox.apache.org/repos/asf/accumulo.git

commit aa6e61cb410d6b147d8705f7e516586070e1e522
Merge: cdf30d0667 6555fc12db
Author: Keith Turner <ktur...@apache.org>
AuthorDate: Fri Feb 14 22:38:45 2025 +0000

    Merge branch '2.1' into 3.1

 .../org/apache/accumulo/core/clientImpl/ScannerIterator.java |  2 ++
 .../org/apache/accumulo/core/clientImpl/ThriftScanner.java   | 12 ++++++++++--
 2 files changed, 12 insertions(+), 2 deletions(-)

diff --cc 
core/src/main/java/org/apache/accumulo/core/clientImpl/ThriftScanner.java
index abe644b81b,0447e5d423..c166918a9f
--- a/core/src/main/java/org/apache/accumulo/core/clientImpl/ThriftScanner.java
+++ b/core/src/main/java/org/apache/accumulo/core/clientImpl/ThriftScanner.java
@@@ -19,9 -19,11 +19,10 @@@
  package org.apache.accumulo.core.clientImpl;
  
  import static java.util.concurrent.TimeUnit.MILLISECONDS;
 -import static java.util.concurrent.TimeUnit.SECONDS;
 +import static org.apache.accumulo.core.util.LazySingletons.RANDOM;
  
  import java.io.IOException;
+ import java.io.InterruptedIOException;
 -import java.security.SecureRandom;
  import java.time.Duration;
  import java.util.ArrayList;
  import java.util.Collection;
@@@ -506,8 -511,13 +509,13 @@@ public class ThriftScanner 
            TraceUtil.setException(child2, e, false);
            sleepMillis = pause(sleepMillis, maxSleepTime, 
scanState.runOnScanServer);
          } catch (TException e) {
-           TabletLocator.getLocator(context, 
scanState.tableId).invalidateCache(context,
-               loc.getTserverLocation());
+           boolean wasInterruptedAfterClose =
+               e.getCause() != null && 
e.getCause().getClass().equals(InterruptedIOException.class)
+                   && scanState.closeInitiated;
+           if (!wasInterruptedAfterClose) {
+             TabletLocator.getLocator(context, 
scanState.tableId).invalidateCache(context,
 -                loc.tablet_location);
++                loc.getTserverLocation());
+           }
            error = "Scan failed, thrift error " + e.getClass().getName() + "  
" + e.getMessage()
                + " " + scanState.getErrorLocation();
            if (!error.equals(lastError)) {

Reply via email to