You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@accumulo.apache.org by mm...@apache.org on 2020/01/17 19:57:02 UTC

[accumulo] branch master updated: Drop no longer valid testRelativePaths in VolumeIT

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

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


The following commit(s) were added to refs/heads/master by this push:
     new f83d869  Drop no longer valid testRelativePaths in VolumeIT
f83d869 is described below

commit f83d869597257e54f1370573dac46f2f27dc7731
Author: Mike Miller <mm...@apache.org>
AuthorDate: Fri Jan 17 12:28:51 2020 -0500

    Drop no longer valid testRelativePaths in VolumeIT
---
 .../java/org/apache/accumulo/test/VolumeIT.java    | 86 ----------------------
 1 file changed, 86 deletions(-)

diff --git a/test/src/main/java/org/apache/accumulo/test/VolumeIT.java b/test/src/main/java/org/apache/accumulo/test/VolumeIT.java
index 7008d52..766cc41 100644
--- a/test/src/main/java/org/apache/accumulo/test/VolumeIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/VolumeIT.java
@@ -189,92 +189,6 @@ public class VolumeIT extends ConfigurableMacBase {
   }
 
   @Test
-  public void testRelativePaths() throws Exception {
-
-    List<String> expected = new ArrayList<>();
-
-    try (AccumuloClient client = Accumulo.newClient().from(getClientProperties()).build()) {
-      String tableName = getUniqueNames(1)[0];
-      client.tableOperations().create(tableName,
-          new NewTableConfiguration().withoutDefaultIterators());
-
-      TableId tableId = TableId.of(client.tableOperations().tableIdMap().get(tableName));
-
-      SortedSet<Text> partitions = new TreeSet<>();
-      // with some splits
-      for (String s : "c,g,k,p,s,v".split(","))
-        partitions.add(new Text(s));
-
-      client.tableOperations().addSplits(tableName, partitions);
-
-      BatchWriter bw = client.createBatchWriter(tableName);
-
-      // create two files in each tablet
-      for (String s : VolumeChooserIT.alpha_rows) {
-        Mutation m = new Mutation(s);
-        m.put("cf1", "cq1", "1");
-        bw.addMutation(m);
-        expected.add(s + ":cf1:cq1:1");
-      }
-
-      bw.flush();
-      client.tableOperations().flush(tableName, null, null, true);
-
-      for (String s : VolumeChooserIT.alpha_rows) {
-        Mutation m = new Mutation(s);
-        m.put("cf1", "cq1", "2");
-        bw.addMutation(m);
-        expected.add(s + ":cf1:cq1:2");
-      }
-
-      bw.close();
-      client.tableOperations().flush(tableName, null, null, true);
-
-      verifyData(expected, client.createScanner(tableName, Authorizations.EMPTY));
-
-      client.tableOperations().offline(tableName, true);
-
-      client.securityOperations().grantTablePermission("root", MetadataTable.NAME,
-          TablePermission.WRITE);
-
-      try (Scanner metaScanner = client.createScanner(MetadataTable.NAME, Authorizations.EMPTY)) {
-        metaScanner.fetchColumnFamily(MetadataSchema.TabletsSection.DataFileColumnFamily.NAME);
-        metaScanner.setRange(new KeyExtent(tableId, null, null).toMetadataRange());
-
-        try (BatchWriter mbw = client.createBatchWriter(MetadataTable.NAME)) {
-          for (Entry<Key,Value> entry : metaScanner) {
-            String cq = entry.getKey().getColumnQualifier().toString();
-            if (cq.startsWith(v1.toString())) {
-              Path path = new Path(cq);
-              String relPath = "/" + path.getParent().getName() + "/" + path.getName();
-              Mutation fileMut = new Mutation(entry.getKey().getRow());
-              fileMut.putDelete(entry.getKey().getColumnFamily(),
-                  entry.getKey().getColumnQualifier());
-              fileMut.put(entry.getKey().getColumnFamily().toString(), relPath,
-                  entry.getValue().toString());
-              mbw.addMutation(fileMut);
-            }
-          }
-        }
-
-        client.tableOperations().online(tableName, true);
-
-        verifyData(expected, client.createScanner(tableName, Authorizations.EMPTY));
-
-        client.tableOperations().compact(tableName, null, null, true, true);
-
-        verifyData(expected, client.createScanner(tableName, Authorizations.EMPTY));
-
-        for (Entry<Key,Value> entry : metaScanner) {
-          String cq = entry.getKey().getColumnQualifier().toString();
-          Path path = new Path(cq);
-          assertTrue("relative path not deleted " + path, path.depth() > 2);
-        }
-      }
-    }
-  }
-
-  @Test
   public void testAddVolumes() throws Exception {
     try (AccumuloClient client = Accumulo.newClient().from(getClientProperties()).build()) {
       String[] tableNames = getUniqueNames(2);