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

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


The following commit(s) were added to refs/heads/elasticity by this push:
     new 9fd7338ba4 Documents causes of error in ConditionalTabletsMutatorImpl 
(#4449)
9fd7338ba4 is described below

commit 9fd7338ba4381cd21bc471bc0bf8d37c04a9b0b3
Author: Keith Turner <ktur...@apache.org>
AuthorDate: Thu Apr 11 19:18:27 2024 -0400

    Documents causes of error in ConditionalTabletsMutatorImpl (#4449)
---
 .../accumulo/server/metadata/ConditionalTabletsMutatorImpl.java  | 9 +++++----
 1 file changed, 5 insertions(+), 4 deletions(-)

diff --git 
a/server/base/src/main/java/org/apache/accumulo/server/metadata/ConditionalTabletsMutatorImpl.java
 
b/server/base/src/main/java/org/apache/accumulo/server/metadata/ConditionalTabletsMutatorImpl.java
index 4401654313..2e999033fa 100644
--- 
a/server/base/src/main/java/org/apache/accumulo/server/metadata/ConditionalTabletsMutatorImpl.java
+++ 
b/server/base/src/main/java/org/apache/accumulo/server/metadata/ConditionalTabletsMutatorImpl.java
@@ -273,9 +273,6 @@ public class ConditionalTabletsMutatorImpl implements 
Ample.ConditionalTabletsMu
   private void 
ensureAllExtentsSeen(HashMap<KeyExtent,ConditionalWriter.Result> resultsMap,
       Set<KeyExtent> extentsSet) {
     if (!resultsMap.keySet().equals(Set.copyOf(extents.values()))) {
-      // ELASTICITY_TODO this check can trigger if someone forgets to submit, 
could check for
-      // that
-
       Sets.difference(resultsMap.keySet(), extentsSet)
           .forEach(extent -> log.error("Unexpected extent seen in in result 
{}", extent));
 
@@ -286,7 +283,11 @@ public class ConditionalTabletsMutatorImpl implements 
Ample.ConditionalTabletsMu
         log.error("result seen {} {}", keyExtent, new 
Text(result.getMutation().getRow()));
       });
 
-      throw new AssertionError("Not all extents were seen, this is 
unexpected");
+      // There are at least two possible causes for this condition. First 
there is a bug in the
+      // ConditionalWriter, and it did not return a result for a mutation that 
was given to it.
+      // Second, Ample code was not used correctly and mutating an extent was 
started but never
+      // submitted.
+      throw new IllegalStateException("Not all extents were seen, this is 
unexpected.");
     }
   }
 

Reply via email to