diff --git a/src/main/java/org/apache/accumulo/testing/performance/tests/SplitBalancingPT.java b/src/main/java/org/apache/accumulo/testing/performance/tests/SplitBalancingPT.java index 1ab20a60..48d79b18 100644 --- a/src/main/java/org/apache/accumulo/testing/performance/tests/SplitBalancingPT.java +++ b/src/main/java/org/apache/accumulo/testing/performance/tests/SplitBalancingPT.java @@ -25,7 +25,6 @@ import org.apache.accumulo.core.client.AccumuloClient; import org.apache.accumulo.core.client.Scanner; -import org.apache.accumulo.core.client.admin.servers.ServerId; import org.apache.accumulo.core.data.Key; import org.apache.accumulo.core.data.Range; import org.apache.accumulo.core.data.Value; @@ -61,8 +60,7 @@ public Report runTest(final Environment env) throws Exception { client.tableOperations().addSplits(TABLE_NAME, getSplits()); client.instanceOperations().waitForBalance(); - int totalTabletServers = - client.instanceOperations().getServers(ServerId.Type.TABLET_SERVER).size(); + int totalTabletServers = client.instanceOperations().getTabletServers().size(); int expectedAllocation = NUM_SPLITS / totalTabletServers; int min = expectedAllocation - MARGIN; int max = expectedAllocation + MARGIN; diff --git a/src/main/java/org/apache/accumulo/testing/randomwalk/bulk/SelectiveQueueing.java b/src/main/java/org/apache/accumulo/testing/randomwalk/bulk/SelectiveQueueing.java index 186cfbb1..8ef6567b 100644 --- a/src/main/java/org/apache/accumulo/testing/randomwalk/bulk/SelectiveQueueing.java +++ b/src/main/java/org/apache/accumulo/testing/randomwalk/bulk/SelectiveQueueing.java @@ -21,7 +21,6 @@ import java.util.concurrent.ThreadPoolExecutor; import org.apache.accumulo.core.client.AccumuloClient; -import org.apache.accumulo.core.client.admin.servers.ServerId; import org.apache.accumulo.testing.randomwalk.RandWalkEnv; import org.apache.accumulo.testing.randomwalk.State; import org.slf4j.Logger; @@ -38,7 +37,7 @@ public static boolean shouldQueueOperation(State state, RandWalkEnv env) { final ThreadPoolExecutor pool = (ThreadPoolExecutor) state.get("pool"); long queuedThreads = pool.getTaskCount() - pool.getActiveCount() - pool.getCompletedTaskCount(); final AccumuloClient client = env.getAccumuloClient(); - int numTservers = client.instanceOperations().getServers(ServerId.Type.TABLET_SERVER).size(); + int numTservers = client.instanceOperations().getTabletServers().size(); if (!shouldQueue(queuedThreads, numTservers)) { log.info("Not queueing because of " + queuedThreads + " outstanding tasks");