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 9503ebe22f verifies tablets are seen by compaction driver (#4434)
9503ebe22f is described below
commit 9503ebe22fef88ee3ecfbecbfecb9f5bfcc86e9b
Author: Keith Turner <[email protected]>
AuthorDate: Mon Apr 8 12:37:39 2024 -0400
verifies tablets are seen by compaction driver (#4434)
---
.../accumulo/manager/tableOps/compact/CompactionDriver.java | 11 +++++++++--
1 file changed, 9 insertions(+), 2 deletions(-)
diff --git
a/server/manager/src/main/java/org/apache/accumulo/manager/tableOps/compact/CompactionDriver.java
b/server/manager/src/main/java/org/apache/accumulo/manager/tableOps/compact/CompactionDriver.java
index 0f224736a0..3790d981c3 100644
---
a/server/manager/src/main/java/org/apache/accumulo/manager/tableOps/compact/CompactionDriver.java
+++
b/server/manager/src/main/java/org/apache/accumulo/manager/tableOps/compact/CompactionDriver.java
@@ -61,10 +61,13 @@ import
org.apache.accumulo.manager.tableOps.delete.PreDeleteTable;
import org.apache.accumulo.server.ServerContext;
import org.apache.accumulo.server.compaction.CompactionConfigStorage;
import org.apache.accumulo.server.compaction.CompactionPluginUtils;
+import org.apache.hadoop.io.Text;
import org.apache.zookeeper.KeeperException;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
+import com.google.common.base.Preconditions;
+
class CompactionDriver extends ManagerRepo {
private static final Logger log =
LoggerFactory.getLogger(CompactionDriver.class);
@@ -300,6 +303,12 @@ class CompactionDriver extends ManagerRepo {
long t2 = System.currentTimeMillis();
+ // The Fate operation gets a table lock that prevents the table from being
deleted while this is
+ // running, so seeing zero tablets in the metadata table is unexpected.
+ Preconditions.checkState(total > 0,
+ "No tablets were seen for table %s in the compaction range %s %s",
tableId,
+ new Text(startRow), new Text(endRow));
+
log.debug(
"{} tablet stats, total:{} complete:{} selected_now:{}
selected_prev:{} selected_by_other:{} "
+ "no_files:{} none_selected:{} user_compaction_requested:{}
user_compaction_waiting:{} "
@@ -314,8 +323,6 @@ class CompactionDriver extends ManagerRepo {
}
return total - complete;
-
- // ELASTICITIY_TODO need to handle seeing zero tablets
}
@Override