You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@accumulo.apache.org by GitBox <gi...@apache.org> on 2022/10/11 18:48:51 UTC

[GitHub] [accumulo] DomGarguilo commented on a diff in pull request #3013: fixes user compaction stuck when producing no output

DomGarguilo commented on code in PR #3013:
URL: https://github.com/apache/accumulo/pull/3013#discussion_r992672543


##########
test/src/main/java/org/apache/accumulo/test/functional/CompactionIT.java:
##########
@@ -494,6 +495,54 @@ public void testSuccessfulCompaction() throws Exception {
     }
   }
 
+  @Test
+  public void testMultiStepCompactionThatDeletesAll() throws Exception {
+
+    // There was a bug where user compactions would never complete when : the tablet had to be
+    // compacted in multiple passes AND the intermediate passes produced no output.
+
+    try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
+      final String tableName = getUniqueNames(1)[0];
+      c.tableOperations().create(tableName);
+      c.tableOperations().setProperty(tableName, Property.TABLE_MAJC_RATIO.getKey(), "100.0");
+
+      var beforeCount = countFiles(c);
+
+      try (var writer = c.createBatchWriter(tableName)) {
+        for (int i = 0; i < 60; i++) {

Review Comment:
   A variable with a descriptive name could be added in place of `60` here to make it easier to tell what it represents when it is referenced throughout this test.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@accumulo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org