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 2021/02/17 14:21:51 UTC
[accumulo-testing] branch main updated: Add more splits to RW
multitable CreateTable
This is an automated email from the ASF dual-hosted git repository.
mmiller pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/accumulo-testing.git
The following commit(s) were added to refs/heads/main by this push:
new 66dcd04 Add more splits to RW multitable CreateTable
66dcd04 is described below
commit 66dcd0430ff0b012a75c256f4bb8a462c2ffe14d
Author: Mike Miller <mm...@apache.org>
AuthorDate: Wed Feb 17 09:21:10 2021 -0500
Add more splits to RW multitable CreateTable
---
.../apache/accumulo/testing/randomwalk/multitable/CreateTable.java | 7 +++++--
1 file changed, 5 insertions(+), 2 deletions(-)
diff --git a/src/main/java/org/apache/accumulo/testing/randomwalk/multitable/CreateTable.java b/src/main/java/org/apache/accumulo/testing/randomwalk/multitable/CreateTable.java
index b132662..3ef2d27 100644
--- a/src/main/java/org/apache/accumulo/testing/randomwalk/multitable/CreateTable.java
+++ b/src/main/java/org/apache/accumulo/testing/randomwalk/multitable/CreateTable.java
@@ -36,13 +36,16 @@ public class CreateTable extends Test {
for (int i = 1; i < 10; i++) {
splits.add(new Text(Integer.toString(i)));
}
+ for (String s : "a b c d e f".split(" ")) {
+ splits.add(new Text(s));
+ }
}
@Override
public void visit(State state, RandWalkEnv env, Properties props) throws Exception {
AccumuloClient client = env.getAccumuloClient();
- int nextId = ((Integer) state.get("nextId")).intValue();
+ int nextId = (Integer) state.get("nextId");
String tableName = String.format("%s_%d", state.getString("tableNamePrefix"), nextId);
try {
client.tableOperations().create(tableName);
@@ -61,6 +64,6 @@ public class CreateTable extends Test {
}
nextId++;
- state.set("nextId", Integer.valueOf(nextId));
+ state.set("nextId", nextId);
}
}