You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@accumulo.apache.org by mw...@apache.org on 2019/03/20 19:09:52 UTC
[accumulo] branch master updated: Remove createClient() methods
from ITs (#1047)
This is an automated email from the ASF dual-hosted git repository.
mwalch 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 f9bf659 Remove createClient() methods from ITs (#1047)
f9bf659 is described below
commit f9bf6599242573fe2c064198308fcc5bdf0c21c0
Author: Mike Walch <mw...@apache.org>
AuthorDate: Wed Mar 20 15:09:47 2019 -0400
Remove createClient() methods from ITs (#1047)
---
.../its/mapred/AccumuloFileOutputFormatIT.java | 7 +--
.../hadoop/its/mapred/AccumuloInputFormatIT.java | 7 +--
.../its/mapred/AccumuloRowInputFormatIT.java | 3 +-
.../hadoop/its/mapred/MultiTableInputFormatIT.java | 3 +-
.../accumulo/hadoop/its/mapred/TokenFileIT.java | 2 +-
.../its/mapreduce/AccumuloFileOutputFormatIT.java | 3 +-
.../its/mapreduce/AccumuloInputFormatIT.java | 3 +-
.../its/mapreduce/AccumuloOutputFormatIT.java | 3 +-
.../its/mapreduce/AccumuloRowInputFormatIT.java | 3 +-
.../its/mapreduce/MultiTableInputFormatIT.java | 3 +-
.../accumulo/hadoop/its/mapreduce/TokenFileIT.java | 2 +-
.../accumulo/harness/AccumuloClusterHarness.java | 24 ++-------
.../accumulo/harness/SharedMiniClusterBase.java | 19 +++----
.../accumulo/test/ArbitraryTablePropertiesIT.java | 6 +--
.../accumulo/test/BadDeleteMarkersCreatedIT.java | 9 ++--
.../java/org/apache/accumulo/test/BalanceIT.java | 3 +-
.../org/apache/accumulo/test/BatchWriterIT.java | 3 +-
.../accumulo/test/BatchWriterInTabletServerIT.java | 5 +-
.../accumulo/test/BulkImportSequentialRowsIT.java | 3 +-
.../apache/accumulo/test/BulkImportVolumeIT.java | 3 +-
.../java/org/apache/accumulo/test/CleanWalIT.java | 7 +--
.../apache/accumulo/test/ClientSideIteratorIT.java | 3 +-
.../java/org/apache/accumulo/test/CloneIT.java | 15 +++---
.../org/apache/accumulo/test/CloseScannerIT.java | 3 +-
.../apache/accumulo/test/ConditionalWriterIT.java | 38 ++++++-------
.../java/org/apache/accumulo/test/FindMaxIT.java | 3 +-
.../org/apache/accumulo/test/ImportExportIT.java | 3 +-
.../accumulo/test/InterruptibleScannersIT.java | 3 +-
.../accumulo/test/IsolationAndDeepCopyIT.java | 3 +-
.../org/apache/accumulo/test/IteratorEnvIT.java | 3 +-
.../apache/accumulo/test/KeyValueEqualityIT.java | 3 +-
.../java/org/apache/accumulo/test/LocatorIT.java | 3 +-
.../accumulo/test/MetaConstraintRetryIT.java | 3 +-
.../java/org/apache/accumulo/test/MetaSplitIT.java | 11 ++--
.../accumulo/test/MultiTableBatchWriterIT.java | 3 +-
.../org/apache/accumulo/test/NamespacesIT.java | 2 +-
.../accumulo/test/NewTableConfigurationIT.java | 35 ++++++------
.../org/apache/accumulo/test/OrIteratorIT.java | 13 ++---
.../test/RecoveryCompactionsAreFlushesIT.java | 3 +-
.../java/org/apache/accumulo/test/SampleIT.java | 7 +--
.../apache/accumulo/test/ScanFlushWithTimeIT.java | 3 +-
.../org/apache/accumulo/test/ShellConfigIT.java | 5 +-
.../org/apache/accumulo/test/ShellServerIT.java | 63 +++++++++++-----------
.../apache/accumulo/test/SplitCancelsMajCIT.java | 3 +-
.../org/apache/accumulo/test/SplitRecoveryIT.java | 3 +-
.../accumulo/test/TableConfigurationUpdateIT.java | 3 +-
.../apache/accumulo/test/TableOperationsIT.java | 3 +-
.../ThriftServerBindsBeforeZooKeeperLockIT.java | 5 +-
.../apache/accumulo/test/TransportCachingIT.java | 3 +-
.../accumulo/test/UserCompactionStrategyIT.java | 15 +++---
.../java/org/apache/accumulo/test/UsersIT.java | 3 +-
.../org/apache/accumulo/test/YieldScannersIT.java | 5 +-
.../accumulo/test/ZooKeeperPropertiesIT.java | 3 +-
.../accumulo/test/functional/AccumuloClientIT.java | 4 +-
.../accumulo/test/functional/AddSplitIT.java | 3 +-
.../test/functional/BadIteratorMincIT.java | 3 +-
.../test/functional/BadLocalityGroupMincIT.java | 3 +-
.../BalanceInPresenceOfOfflineTableIT.java | 5 +-
.../accumulo/test/functional/BatchScanSplitIT.java | 3 +-
.../test/functional/BatchWriterFlushIT.java | 5 +-
.../accumulo/test/functional/BigRootTabletIT.java | 3 +-
.../apache/accumulo/test/functional/BinaryIT.java | 5 +-
.../accumulo/test/functional/BinaryStressIT.java | 7 +--
.../accumulo/test/functional/BloomFilterIT.java | 3 +-
.../accumulo/test/functional/BulkFailureIT.java | 3 +-
.../accumulo/test/functional/BulkFileIT.java | 3 +-
.../apache/accumulo/test/functional/BulkIT.java | 5 +-
.../accumulo/test/functional/BulkLoadIT.java | 19 +++----
.../test/functional/BulkSplitOptimizationIT.java | 9 ++--
.../test/functional/ChaoticBalancerIT.java | 5 +-
.../accumulo/test/functional/ClassLoaderIT.java | 3 +-
.../accumulo/test/functional/CloneTestIT.java | 7 +--
.../accumulo/test/functional/CombinerIT.java | 3 +-
.../accumulo/test/functional/CompactionIT.java | 9 ++--
.../accumulo/test/functional/ConcurrencyIT.java | 3 +-
.../test/functional/ConcurrentDeleteTableIT.java | 5 +-
.../accumulo/test/functional/ConstraintIT.java | 3 +-
.../accumulo/test/functional/CreateAndUseIT.java | 7 +--
.../test/functional/CreateInitialSplitsIT.java | 3 +-
.../test/functional/CreateManyScannersIT.java | 3 +-
.../accumulo/test/functional/CredentialsIT.java | 6 +--
.../test/functional/DeleteEverythingIT.java | 7 +--
.../accumulo/test/functional/DeleteFailIT.java | 3 +-
.../apache/accumulo/test/functional/DeleteIT.java | 5 +-
.../accumulo/test/functional/DeleteRowsIT.java | 5 +-
.../test/functional/DeleteRowsSplitIT.java | 3 +-
.../test/functional/DeleteTableDuringSplitIT.java | 3 +-
.../test/functional/DeletedTablesDontFlushIT.java | 3 +-
.../test/functional/DynamicThreadPoolsIT.java | 9 ++--
.../test/functional/FateConcurrencyIT.java | 3 +-
.../accumulo/test/functional/FateStarvationIT.java | 5 +-
.../accumulo/test/functional/LargeRowIT.java | 7 +--
.../accumulo/test/functional/LogicalTimeIT.java | 3 +-
.../test/functional/ManyWriteAheadLogsIT.java | 3 +-
.../test/functional/MasterAssignmentIT.java | 3 +-
.../accumulo/test/functional/MasterFailoverIT.java | 5 +-
.../apache/accumulo/test/functional/MaxOpenIT.java | 9 ++--
.../apache/accumulo/test/functional/MergeIT.java | 7 +--
.../accumulo/test/functional/MetadataIT.java | 7 +--
.../accumulo/test/functional/PermissionsIT.java | 6 +--
.../accumulo/test/functional/ReadWriteIT.java | 14 ++---
.../apache/accumulo/test/functional/RenameIT.java | 3 +-
.../apache/accumulo/test/functional/RestartIT.java | 27 +++++-----
.../accumulo/test/functional/RestartStressIT.java | 5 +-
.../accumulo/test/functional/RowDeleteIT.java | 3 +-
.../apache/accumulo/test/functional/ScanIdIT.java | 3 +-
.../accumulo/test/functional/ScanIteratorIT.java | 5 +-
.../accumulo/test/functional/ScanRangeIT.java | 3 +-
.../test/functional/ScanSessionTimeOutIT.java | 7 +--
.../accumulo/test/functional/ScannerContextIT.java | 9 ++--
.../apache/accumulo/test/functional/ScannerIT.java | 3 +-
.../test/functional/ServerSideErrorIT.java | 3 +-
.../test/functional/SessionBlockVerifyIT.java | 3 +-
.../test/functional/SparseColumnFamilyIT.java | 3 +-
.../apache/accumulo/test/functional/SplitIT.java | 13 ++---
.../apache/accumulo/test/functional/SummaryIT.java | 18 +++----
.../apache/accumulo/test/functional/TableIT.java | 5 +-
.../apache/accumulo/test/functional/TabletIT.java | 3 +-
.../functional/TabletStateChangeIteratorIT.java | 3 +-
.../apache/accumulo/test/functional/TimeoutIT.java | 3 +-
.../accumulo/test/functional/TooManyDeletesIT.java | 3 +-
.../accumulo/test/functional/VisibilityIT.java | 7 +--
.../test/functional/WriteAheadLogEncryptedIT.java | 3 +-
.../accumulo/test/functional/WriteAheadLogIT.java | 5 +-
.../accumulo/test/functional/WriteLotsIT.java | 8 +--
.../test/mapred/AccumuloFileOutputFormatIT.java | 7 +--
.../test/mapred/AccumuloInputFormatIT.java | 7 +--
.../mapred/AccumuloMultiTableInputFormatIT.java | 3 +-
.../test/mapred/AccumuloRowInputFormatIT.java | 3 +-
.../apache/accumulo/test/mapred/TokenFileIT.java | 3 +-
.../test/mapreduce/AccumuloFileOutputFormatIT.java | 3 +-
.../test/mapreduce/AccumuloInputFormatIT.java | 13 ++---
.../mapreduce/AccumuloMultiTableInputFormatIT.java | 3 +-
.../test/mapreduce/AccumuloOutputFormatIT.java | 3 +-
.../test/mapreduce/AccumuloRowInputFormatIT.java | 3 +-
.../accumulo/test/mapreduce/TokenFileIT.java | 3 +-
.../accumulo/test/proxy/SimpleProxyBase.java | 3 +-
.../test/replication/StatusCombinerMacIT.java | 5 +-
138 files changed, 479 insertions(+), 373 deletions(-)
diff --git a/hadoop-mapreduce/src/test/java/org/apache/accumulo/hadoop/its/mapred/AccumuloFileOutputFormatIT.java b/hadoop-mapreduce/src/test/java/org/apache/accumulo/hadoop/its/mapred/AccumuloFileOutputFormatIT.java
index c4c65ef..4af172e 100644
--- a/hadoop-mapreduce/src/test/java/org/apache/accumulo/hadoop/its/mapred/AccumuloFileOutputFormatIT.java
+++ b/hadoop-mapreduce/src/test/java/org/apache/accumulo/hadoop/its/mapred/AccumuloFileOutputFormatIT.java
@@ -25,6 +25,7 @@ import static org.junit.Assert.fail;
import java.io.File;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchWriter;
import org.apache.accumulo.core.client.BatchWriterConfig;
@@ -81,7 +82,7 @@ public class AccumuloFileOutputFormatIT extends AccumuloClusterHarness {
@Test
public void testEmptyWrite() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
c.tableOperations().create(EMPTY_TABLE);
handleWriteTests(false);
}
@@ -89,7 +90,7 @@ public class AccumuloFileOutputFormatIT extends AccumuloClusterHarness {
@Test
public void testRealWrite() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
c.tableOperations().create(TEST_TABLE);
BatchWriter bw = c.createBatchWriter(TEST_TABLE, new BatchWriterConfig());
Mutation m = new Mutation("Key");
@@ -205,7 +206,7 @@ public class AccumuloFileOutputFormatIT extends AccumuloClusterHarness {
@Test
public void writeBadVisibility() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
c.tableOperations().create(BAD_TABLE);
BatchWriter bw = c.createBatchWriter(BAD_TABLE, new BatchWriterConfig());
Mutation m = new Mutation("r1");
diff --git a/hadoop-mapreduce/src/test/java/org/apache/accumulo/hadoop/its/mapred/AccumuloInputFormatIT.java b/hadoop-mapreduce/src/test/java/org/apache/accumulo/hadoop/its/mapred/AccumuloInputFormatIT.java
index 68b7aad..30c2bcb 100644
--- a/hadoop-mapreduce/src/test/java/org/apache/accumulo/hadoop/its/mapred/AccumuloInputFormatIT.java
+++ b/hadoop-mapreduce/src/test/java/org/apache/accumulo/hadoop/its/mapred/AccumuloInputFormatIT.java
@@ -24,6 +24,7 @@ import java.io.File;
import java.util.Collection;
import java.util.Collections;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchWriter;
import org.apache.accumulo.core.client.BatchWriterConfig;
@@ -153,7 +154,7 @@ public class AccumuloInputFormatIT extends AccumuloClusterHarness {
@Test
public void testMap() throws Exception {
String table = getUniqueNames(1)[0];
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
c.tableOperations().create(table);
BatchWriter bw = c.createBatchWriter(table, new BatchWriterConfig());
for (int i = 0; i < 100; i++) {
@@ -179,7 +180,7 @@ public class AccumuloInputFormatIT extends AccumuloClusterHarness {
public void testSample() throws Exception {
final String TEST_TABLE_3 = getUniqueNames(1)[0];
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
c.tableOperations().create(TEST_TABLE_3,
new NewTableConfiguration().enableSampling(SAMPLER_CONFIG));
BatchWriter bw = c.createBatchWriter(TEST_TABLE_3, new BatchWriterConfig());
@@ -215,7 +216,7 @@ public class AccumuloInputFormatIT extends AccumuloClusterHarness {
Collection<IteratorSetting.Column> fetchColumns = Collections
.singleton(new IteratorSetting.Column(new Text("foo"), new Text("bar")));
- try (AccumuloClient accumuloClient = createAccumuloClient()) {
+ try (AccumuloClient accumuloClient = Accumulo.newClient().from(getClientProps()).build()) {
accumuloClient.tableOperations().create(table);
AccumuloInputFormat.configure().clientProperties(getClientInfo().getProperties()).table(table)
diff --git a/hadoop-mapreduce/src/test/java/org/apache/accumulo/hadoop/its/mapred/AccumuloRowInputFormatIT.java b/hadoop-mapreduce/src/test/java/org/apache/accumulo/hadoop/its/mapred/AccumuloRowInputFormatIT.java
index d13d099..4479c74 100644
--- a/hadoop-mapreduce/src/test/java/org/apache/accumulo/hadoop/its/mapred/AccumuloRowInputFormatIT.java
+++ b/hadoop-mapreduce/src/test/java/org/apache/accumulo/hadoop/its/mapred/AccumuloRowInputFormatIT.java
@@ -26,6 +26,7 @@ import java.util.Iterator;
import java.util.List;
import java.util.Map.Entry;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchWriter;
import org.apache.accumulo.core.client.BatchWriterConfig;
@@ -188,7 +189,7 @@ public class AccumuloRowInputFormatIT extends AccumuloClusterHarness {
@Test
public void test() throws Exception {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(1)[0];
client.tableOperations().create(tableName);
BatchWriter writer = null;
diff --git a/hadoop-mapreduce/src/test/java/org/apache/accumulo/hadoop/its/mapred/MultiTableInputFormatIT.java b/hadoop-mapreduce/src/test/java/org/apache/accumulo/hadoop/its/mapred/MultiTableInputFormatIT.java
index 95244fe..cca51c8 100644
--- a/hadoop-mapreduce/src/test/java/org/apache/accumulo/hadoop/its/mapred/MultiTableInputFormatIT.java
+++ b/hadoop-mapreduce/src/test/java/org/apache/accumulo/hadoop/its/mapred/MultiTableInputFormatIT.java
@@ -22,6 +22,7 @@ import static org.junit.Assert.assertNull;
import java.io.File;
import java.io.IOException;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchWriter;
import org.apache.accumulo.core.client.BatchWriterConfig;
@@ -127,7 +128,7 @@ public class MultiTableInputFormatIT extends AccumuloClusterHarness {
String[] tableNames = getUniqueNames(2);
String table1 = tableNames[0];
String table2 = tableNames[1];
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
c.tableOperations().create(table1);
c.tableOperations().create(table2);
BatchWriter bw = c.createBatchWriter(table1, new BatchWriterConfig());
diff --git a/hadoop-mapreduce/src/test/java/org/apache/accumulo/hadoop/its/mapred/TokenFileIT.java b/hadoop-mapreduce/src/test/java/org/apache/accumulo/hadoop/its/mapred/TokenFileIT.java
index 5f2f66c..702cf1e 100644
--- a/hadoop-mapreduce/src/test/java/org/apache/accumulo/hadoop/its/mapred/TokenFileIT.java
+++ b/hadoop-mapreduce/src/test/java/org/apache/accumulo/hadoop/its/mapred/TokenFileIT.java
@@ -149,7 +149,7 @@ public class TokenFileIT extends AccumuloClusterHarness {
String[] tableNames = getUniqueNames(2);
String table1 = tableNames[0];
String table2 = tableNames[1];
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
c.tableOperations().create(table1);
c.tableOperations().create(table2);
BatchWriter bw = c.createBatchWriter(table1, new BatchWriterConfig());
diff --git a/hadoop-mapreduce/src/test/java/org/apache/accumulo/hadoop/its/mapreduce/AccumuloFileOutputFormatIT.java b/hadoop-mapreduce/src/test/java/org/apache/accumulo/hadoop/its/mapreduce/AccumuloFileOutputFormatIT.java
index b17aeb5..15ad926 100644
--- a/hadoop-mapreduce/src/test/java/org/apache/accumulo/hadoop/its/mapreduce/AccumuloFileOutputFormatIT.java
+++ b/hadoop-mapreduce/src/test/java/org/apache/accumulo/hadoop/its/mapreduce/AccumuloFileOutputFormatIT.java
@@ -23,6 +23,7 @@ import static org.junit.Assert.fail;
import java.io.File;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchWriter;
import org.apache.accumulo.core.client.BatchWriterConfig;
@@ -82,7 +83,7 @@ public class AccumuloFileOutputFormatIT extends AccumuloClusterHarness {
TEST_TABLE = PREFIX + "_mapreduce_test_table";
EMPTY_TABLE = PREFIX + "_mapreduce_empty_table";
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
c.tableOperations().create(EMPTY_TABLE);
c.tableOperations().create(TEST_TABLE);
c.tableOperations().create(BAD_TABLE);
diff --git a/hadoop-mapreduce/src/test/java/org/apache/accumulo/hadoop/its/mapreduce/AccumuloInputFormatIT.java b/hadoop-mapreduce/src/test/java/org/apache/accumulo/hadoop/its/mapreduce/AccumuloInputFormatIT.java
index d577a4e..947f518 100644
--- a/hadoop-mapreduce/src/test/java/org/apache/accumulo/hadoop/its/mapreduce/AccumuloInputFormatIT.java
+++ b/hadoop-mapreduce/src/test/java/org/apache/accumulo/hadoop/its/mapreduce/AccumuloInputFormatIT.java
@@ -31,6 +31,7 @@ import java.util.List;
import java.util.TreeSet;
import java.util.concurrent.TimeUnit;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.AccumuloException;
import org.apache.accumulo.core.client.BatchWriter;
@@ -93,7 +94,7 @@ public class AccumuloInputFormatIT extends AccumuloClusterHarness {
@Before
public void before() {
inputFormat = new AccumuloInputFormat();
- client = createAccumuloClient();
+ client = Accumulo.newClient().from(getClientProps()).build();
}
@After
diff --git a/hadoop-mapreduce/src/test/java/org/apache/accumulo/hadoop/its/mapreduce/AccumuloOutputFormatIT.java b/hadoop-mapreduce/src/test/java/org/apache/accumulo/hadoop/its/mapreduce/AccumuloOutputFormatIT.java
index 75b27b1..24a2290 100644
--- a/hadoop-mapreduce/src/test/java/org/apache/accumulo/hadoop/its/mapreduce/AccumuloOutputFormatIT.java
+++ b/hadoop-mapreduce/src/test/java/org/apache/accumulo/hadoop/its/mapreduce/AccumuloOutputFormatIT.java
@@ -26,6 +26,7 @@ import java.io.IOException;
import java.util.Iterator;
import java.util.Map.Entry;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchWriter;
import org.apache.accumulo.core.client.BatchWriterConfig;
@@ -127,7 +128,7 @@ public class AccumuloOutputFormatIT extends AccumuloClusterHarness {
String[] tableNames = getUniqueNames(2);
String table1 = tableNames[0];
String table2 = tableNames[1];
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
c.tableOperations().create(table1);
c.tableOperations().create(table2);
BatchWriter bw = c.createBatchWriter(table1, new BatchWriterConfig());
diff --git a/hadoop-mapreduce/src/test/java/org/apache/accumulo/hadoop/its/mapreduce/AccumuloRowInputFormatIT.java b/hadoop-mapreduce/src/test/java/org/apache/accumulo/hadoop/its/mapreduce/AccumuloRowInputFormatIT.java
index ccca41c..9a88c86 100644
--- a/hadoop-mapreduce/src/test/java/org/apache/accumulo/hadoop/its/mapreduce/AccumuloRowInputFormatIT.java
+++ b/hadoop-mapreduce/src/test/java/org/apache/accumulo/hadoop/its/mapreduce/AccumuloRowInputFormatIT.java
@@ -26,6 +26,7 @@ import java.util.Iterator;
import java.util.List;
import java.util.Map.Entry;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchWriter;
import org.apache.accumulo.core.client.BatchWriterConfig;
@@ -183,7 +184,7 @@ public class AccumuloRowInputFormatIT extends AccumuloClusterHarness {
@Test
public void test() throws Exception {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(1)[0];
client.tableOperations().create(tableName);
BatchWriter writer = null;
diff --git a/hadoop-mapreduce/src/test/java/org/apache/accumulo/hadoop/its/mapreduce/MultiTableInputFormatIT.java b/hadoop-mapreduce/src/test/java/org/apache/accumulo/hadoop/its/mapreduce/MultiTableInputFormatIT.java
index 07349dd..814e0d9 100644
--- a/hadoop-mapreduce/src/test/java/org/apache/accumulo/hadoop/its/mapreduce/MultiTableInputFormatIT.java
+++ b/hadoop-mapreduce/src/test/java/org/apache/accumulo/hadoop/its/mapreduce/MultiTableInputFormatIT.java
@@ -22,6 +22,7 @@ import static org.junit.Assert.assertNull;
import java.io.File;
import java.io.IOException;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchWriter;
import org.apache.accumulo.core.client.BatchWriterConfig;
@@ -127,7 +128,7 @@ public class MultiTableInputFormatIT extends AccumuloClusterHarness {
String[] tableNames = getUniqueNames(2);
String table1 = tableNames[0];
String table2 = tableNames[1];
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
c.tableOperations().create(table1);
c.tableOperations().create(table2);
BatchWriter bw = c.createBatchWriter(table1, new BatchWriterConfig());
diff --git a/hadoop-mapreduce/src/test/java/org/apache/accumulo/hadoop/its/mapreduce/TokenFileIT.java b/hadoop-mapreduce/src/test/java/org/apache/accumulo/hadoop/its/mapreduce/TokenFileIT.java
index 35006dc..d3ee1af 100644
--- a/hadoop-mapreduce/src/test/java/org/apache/accumulo/hadoop/its/mapreduce/TokenFileIT.java
+++ b/hadoop-mapreduce/src/test/java/org/apache/accumulo/hadoop/its/mapreduce/TokenFileIT.java
@@ -143,7 +143,7 @@ public class TokenFileIT extends AccumuloClusterHarness {
String[] tableNames = getUniqueNames(2);
String table1 = tableNames[0];
String table2 = tableNames[1];
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
c.tableOperations().create(table1);
c.tableOperations().create(table2);
BatchWriter bw = c.createBatchWriter(table1, new BatchWriterConfig());
diff --git a/test/src/main/java/org/apache/accumulo/harness/AccumuloClusterHarness.java b/test/src/main/java/org/apache/accumulo/harness/AccumuloClusterHarness.java
index 7f4ba00..c87d1a3 100644
--- a/test/src/main/java/org/apache/accumulo/harness/AccumuloClusterHarness.java
+++ b/test/src/main/java/org/apache/accumulo/harness/AccumuloClusterHarness.java
@@ -18,7 +18,6 @@ package org.apache.accumulo.harness;
import static com.google.common.base.Preconditions.checkState;
import static java.nio.charset.StandardCharsets.UTF_8;
-import static org.junit.Assert.fail;
import java.io.IOException;
import java.util.Properties;
@@ -28,6 +27,7 @@ import org.apache.accumulo.cluster.ClusterControl;
import org.apache.accumulo.cluster.ClusterUser;
import org.apache.accumulo.cluster.ClusterUsers;
import org.apache.accumulo.cluster.standalone.StandaloneAccumuloCluster;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.admin.SecurityOperations;
import org.apache.accumulo.core.client.admin.TableOperations;
@@ -191,7 +191,7 @@ public abstract class AccumuloClusterHarness extends AccumuloITBase
UserGroupInformation.loginUserFromKeytab(rootUser.getPrincipal(),
rootUser.getKeytab().getAbsolutePath());
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
// Create the trace table
client.tableOperations().create(traceTable);
@@ -213,7 +213,7 @@ public abstract class AccumuloClusterHarness extends AccumuloITBase
public void cleanupTables() throws Exception {
final String tablePrefix = this.getClass().getSimpleName() + "_";
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
final TableOperations tops = client.tableOperations();
for (String table : tops.list()) {
if (table.startsWith(tablePrefix)) {
@@ -226,7 +226,7 @@ public abstract class AccumuloClusterHarness extends AccumuloITBase
public void cleanupUsers() throws Exception {
final String userPrefix = this.getClass().getSimpleName();
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
final SecurityOperations secOps = client.securityOperations();
for (String user : secOps.listLocalUsers()) {
if (user.startsWith(userPrefix)) {
@@ -271,7 +271,7 @@ public abstract class AccumuloClusterHarness extends AccumuloITBase
return clusterConf.getAdminPrincipal();
}
- public static Properties getClientProperties() {
+ public static Properties getClientProps() {
checkState(initialized);
return getCluster().getClientProperties();
}
@@ -347,20 +347,6 @@ public abstract class AccumuloClusterHarness extends AccumuloITBase
return clusterConf;
}
- public AccumuloClient createAccumuloClient() {
- checkState(initialized);
- try {
- String princ = getAdminPrincipal();
- AuthenticationToken token = getAdminToken();
- log.debug("Creating client as {} with {}", princ, token);
- return cluster.createAccumuloClient(princ, token);
- } catch (Exception e) {
- log.error("Could not connect to Accumulo", e);
- fail("Could not connect to Accumulo: " + e.getMessage());
- throw new RuntimeException("Could not connect to Accumulo", e);
- }
- }
-
// TODO Really don't want this here. Will ultimately need to abstract configuration method away
// from MAConfig
// and change over to something more generic
diff --git a/test/src/main/java/org/apache/accumulo/harness/SharedMiniClusterBase.java b/test/src/main/java/org/apache/accumulo/harness/SharedMiniClusterBase.java
index efe0ce2..4195120 100644
--- a/test/src/main/java/org/apache/accumulo/harness/SharedMiniClusterBase.java
+++ b/test/src/main/java/org/apache/accumulo/harness/SharedMiniClusterBase.java
@@ -19,8 +19,8 @@ package org.apache.accumulo.harness;
import static org.junit.Assert.assertTrue;
import java.io.File;
-import java.io.IOException;
import java.security.SecureRandom;
+import java.util.Properties;
import org.apache.accumulo.cluster.ClusterUser;
import org.apache.accumulo.cluster.ClusterUsers;
@@ -28,6 +28,7 @@ import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.security.tokens.AuthenticationToken;
import org.apache.accumulo.core.client.security.tokens.KerberosToken;
import org.apache.accumulo.core.client.security.tokens.PasswordToken;
+import org.apache.accumulo.core.conf.ClientProperty;
import org.apache.accumulo.core.conf.Property;
import org.apache.accumulo.core.security.TablePermission;
import org.apache.accumulo.miniclusterImpl.MiniAccumuloClusterImpl;
@@ -168,19 +169,11 @@ public abstract class SharedMiniClusterBase extends AccumuloITBase implements Cl
}
public static AuthenticationToken getToken() {
- if (token instanceof KerberosToken) {
- try {
- UserGroupInformation.loginUserFromKeytab(getPrincipal(),
- krb.getRootUser().getKeytab().getAbsolutePath());
- } catch (IOException e) {
- throw new RuntimeException("Failed to login", e);
- }
- }
- return token;
+ return ClientProperty.getAuthenticationToken(getClientProps());
}
public static String getPrincipal() {
- return principal;
+ return ClientProperty.AUTH_PRINCIPAL.getValue(getClientProps());
}
public static MiniAccumuloClusterImpl getCluster() {
@@ -191,8 +184,8 @@ public abstract class SharedMiniClusterBase extends AccumuloITBase implements Cl
return cluster.getConfig().getDir();
}
- public static AccumuloClient createClient() {
- return getCluster().createAccumuloClient(principal, getToken());
+ public static Properties getClientProps() {
+ return getCluster().getClientProperties();
}
public static TestingKdc getKdc() {
diff --git a/test/src/main/java/org/apache/accumulo/test/ArbitraryTablePropertiesIT.java b/test/src/main/java/org/apache/accumulo/test/ArbitraryTablePropertiesIT.java
index 02003fc..22eea8a 100644
--- a/test/src/main/java/org/apache/accumulo/test/ArbitraryTablePropertiesIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/ArbitraryTablePropertiesIT.java
@@ -62,7 +62,7 @@ public class ArbitraryTablePropertiesIT extends SharedMiniClusterBase {
// make a table
final String tableName = getUniqueNames(1)[0];
- try (AccumuloClient client = createClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
client.tableOperations().create(tableName);
// Set variables for the property name to use and the initial value
@@ -121,7 +121,7 @@ public class ArbitraryTablePropertiesIT extends SharedMiniClusterBase {
// Create a root user and create the table
// Create a test user and grant that user permission to alter the table
final String tableName = getUniqueNames(1)[0];
- try (AccumuloClient c = createClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
c.securityOperations().createLocalUser(testUser,
(testToken instanceof PasswordToken ? (PasswordToken) testToken : null));
c.tableOperations().create(tableName);
@@ -192,7 +192,7 @@ public class ArbitraryTablePropertiesIT extends SharedMiniClusterBase {
// Create a root user and create the table
// Create a test user and grant that user permission to alter the table
final String tableName = getUniqueNames(1)[0];
- try (AccumuloClient c = createClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
c.securityOperations().createLocalUser(testUser,
(testToken instanceof PasswordToken ? (PasswordToken) testToken : null));
c.tableOperations().create(tableName);
diff --git a/test/src/main/java/org/apache/accumulo/test/BadDeleteMarkersCreatedIT.java b/test/src/main/java/org/apache/accumulo/test/BadDeleteMarkersCreatedIT.java
index 027b263..4db99db 100644
--- a/test/src/main/java/org/apache/accumulo/test/BadDeleteMarkersCreatedIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/BadDeleteMarkersCreatedIT.java
@@ -28,6 +28,7 @@ import java.util.TreeSet;
import java.util.concurrent.TimeUnit;
import org.apache.accumulo.core.Constants;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.Scanner;
import org.apache.accumulo.core.client.admin.InstanceOperations;
@@ -85,7 +86,7 @@ public class BadDeleteMarkersCreatedIT extends AccumuloClusterHarness {
@Before
public void alterConfig() throws Exception {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
InstanceOperations iops = client.instanceOperations();
Map<String,String> config = iops.getSystemConfiguration();
gcCycleDelay = config.get(Property.GC_CYCLE_DELAY.getKey());
@@ -96,7 +97,7 @@ public class BadDeleteMarkersCreatedIT extends AccumuloClusterHarness {
}
getCluster().getClusterControl().stopAllServers(ServerType.GARBAGE_COLLECTOR);
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
ClientInfo info = ClientInfo.from(client.properties());
ZooCache zcache = new ZooCache(info.getZooKeepers(), info.getZooKeepersSessionTimeOut());
zcache.clear();
@@ -131,7 +132,7 @@ public class BadDeleteMarkersCreatedIT extends AccumuloClusterHarness {
@After
public void restoreConfig() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
InstanceOperations iops = c.instanceOperations();
if (gcCycleDelay != null) {
iops.setProperty(Property.GC_CYCLE_DELAY.getKey(), gcCycleDelay);
@@ -150,7 +151,7 @@ public class BadDeleteMarkersCreatedIT extends AccumuloClusterHarness {
public void test() throws Exception {
// make a table
String tableName = getUniqueNames(1)[0];
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
log.info("Creating table to be deleted");
c.tableOperations().create(tableName);
final String tableId = c.tableOperations().tableIdMap().get(tableName);
diff --git a/test/src/main/java/org/apache/accumulo/test/BalanceIT.java b/test/src/main/java/org/apache/accumulo/test/BalanceIT.java
index 12228cb..d955576 100644
--- a/test/src/main/java/org/apache/accumulo/test/BalanceIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/BalanceIT.java
@@ -19,6 +19,7 @@ package org.apache.accumulo.test;
import java.util.SortedSet;
import java.util.TreeSet;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.harness.AccumuloClusterHarness;
import org.apache.hadoop.io.Text;
@@ -37,7 +38,7 @@ public class BalanceIT extends AccumuloClusterHarness {
@Test
public void testBalance() throws Exception {
String tableName = getUniqueNames(1)[0];
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
log.info("Creating table");
c.tableOperations().create(tableName);
SortedSet<Text> splits = new TreeSet<>();
diff --git a/test/src/main/java/org/apache/accumulo/test/BatchWriterIT.java b/test/src/main/java/org/apache/accumulo/test/BatchWriterIT.java
index 5d70d16..968b2d7 100644
--- a/test/src/main/java/org/apache/accumulo/test/BatchWriterIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/BatchWriterIT.java
@@ -16,6 +16,7 @@
*/
package org.apache.accumulo.test;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchWriter;
import org.apache.accumulo.core.client.BatchWriterConfig;
@@ -35,7 +36,7 @@ public class BatchWriterIT extends AccumuloClusterHarness {
public void test() throws Exception {
// call the batchwriter with buffer of size zero
String table = getUniqueNames(1)[0];
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
c.tableOperations().create(table);
BatchWriterConfig config = new BatchWriterConfig();
config.setMaxMemory(0);
diff --git a/test/src/main/java/org/apache/accumulo/test/BatchWriterInTabletServerIT.java b/test/src/main/java/org/apache/accumulo/test/BatchWriterInTabletServerIT.java
index 1a21680..4052680 100644
--- a/test/src/main/java/org/apache/accumulo/test/BatchWriterInTabletServerIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/BatchWriterInTabletServerIT.java
@@ -21,6 +21,7 @@ import static org.junit.Assert.assertTrue;
import java.util.Map;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchWriter;
import org.apache.accumulo.core.client.BatchWriterConfig;
@@ -60,7 +61,7 @@ public class BatchWriterInTabletServerIT extends AccumuloClusterHarness {
public void testNormalWrite() throws Exception {
String[] uniqueNames = getUniqueNames(2);
String t1 = uniqueNames[0], t2 = uniqueNames[1];
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
int numEntriesToWritePerEntry = 50;
IteratorSetting itset = BatchWriterIterator.iteratorSetting(6, 0, 15, 1000,
numEntriesToWritePerEntry, t2, c, getAdminToken(), false, false);
@@ -80,7 +81,7 @@ public class BatchWriterInTabletServerIT extends AccumuloClusterHarness {
public void testClearLocatorAndSplitWrite() throws Exception {
String[] uniqueNames = getUniqueNames(2);
String t1 = uniqueNames[0], t2 = uniqueNames[1];
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
int numEntriesToWritePerEntry = 50;
IteratorSetting itset = BatchWriterIterator.iteratorSetting(6, 0, 15, 1000,
numEntriesToWritePerEntry, t2, c, getAdminToken(), true, true);
diff --git a/test/src/main/java/org/apache/accumulo/test/BulkImportSequentialRowsIT.java b/test/src/main/java/org/apache/accumulo/test/BulkImportSequentialRowsIT.java
index 69d3273..02f7486 100644
--- a/test/src/main/java/org/apache/accumulo/test/BulkImportSequentialRowsIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/BulkImportSequentialRowsIT.java
@@ -21,6 +21,7 @@ import static org.junit.Assert.assertTrue;
import java.util.TreeSet;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.admin.TableOperations;
import org.apache.accumulo.core.security.Authorizations;
@@ -62,7 +63,7 @@ public class BulkImportSequentialRowsIT extends AccumuloClusterHarness {
@Test
public void testBulkImportFailure() throws Exception {
String tableName = getUniqueNames(1)[0];
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
TableOperations to = client.tableOperations();
to.create(tableName);
FileSystem fs = getFileSystem();
diff --git a/test/src/main/java/org/apache/accumulo/test/BulkImportVolumeIT.java b/test/src/main/java/org/apache/accumulo/test/BulkImportVolumeIT.java
index 95dc1ca..65a6826 100644
--- a/test/src/main/java/org/apache/accumulo/test/BulkImportVolumeIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/BulkImportVolumeIT.java
@@ -21,6 +21,7 @@ import static org.junit.Assert.assertTrue;
import java.io.File;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.conf.Property;
import org.apache.accumulo.harness.AccumuloClusterHarness;
@@ -66,7 +67,7 @@ public class BulkImportVolumeIT extends AccumuloClusterHarness {
@Test
public void testBulkImportFailure() throws Exception {
String tableName = getUniqueNames(1)[0];
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
client.tableOperations().create(tableName);
FileSystem fs = getFileSystem();
Path rootPath = new Path(cluster.getTemporaryPath(), getClass().getName());
diff --git a/test/src/main/java/org/apache/accumulo/test/CleanWalIT.java b/test/src/main/java/org/apache/accumulo/test/CleanWalIT.java
index 9452efc..5bdf6f5 100644
--- a/test/src/main/java/org/apache/accumulo/test/CleanWalIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/CleanWalIT.java
@@ -22,6 +22,7 @@ import static org.junit.Assert.assertEquals;
import java.util.Map.Entry;
import java.util.concurrent.TimeUnit;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchWriter;
import org.apache.accumulo.core.client.Scanner;
@@ -67,7 +68,7 @@ public class CleanWalIT extends AccumuloClusterHarness {
@Before
public void offlineTraceTable() throws Exception {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
String traceTable = client.instanceOperations().getSystemConfiguration()
.get(Property.TRACE_TABLE.getKey());
if (client.tableOperations().exists(traceTable)) {
@@ -79,7 +80,7 @@ public class CleanWalIT extends AccumuloClusterHarness {
@After
public void onlineTraceTable() throws Exception {
if (cluster != null) {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
String traceTable = client.instanceOperations().getSystemConfiguration()
.get(Property.TRACE_TABLE.getKey());
if (client.tableOperations().exists(traceTable)) {
@@ -92,7 +93,7 @@ public class CleanWalIT extends AccumuloClusterHarness {
// test for ACCUMULO-1830
@Test
public void test() throws Exception {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(1)[0];
client.tableOperations().create(tableName);
try (BatchWriter bw = client.createBatchWriter(tableName)) {
diff --git a/test/src/main/java/org/apache/accumulo/test/ClientSideIteratorIT.java b/test/src/main/java/org/apache/accumulo/test/ClientSideIteratorIT.java
index fc5cfed..c0fc664 100644
--- a/test/src/main/java/org/apache/accumulo/test/ClientSideIteratorIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/ClientSideIteratorIT.java
@@ -24,6 +24,7 @@ import java.util.ArrayList;
import java.util.List;
import java.util.Map.Entry;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchWriter;
import org.apache.accumulo.core.client.ClientSideIteratorScanner;
@@ -76,7 +77,7 @@ public class ClientSideIteratorIT extends AccumuloClusterHarness {
@Before
public void setupInstance() {
- client = createAccumuloClient();
+ client = Accumulo.newClient().from(getClientProps()).build();
tableName = getUniqueNames(1)[0];
}
diff --git a/test/src/main/java/org/apache/accumulo/test/CloneIT.java b/test/src/main/java/org/apache/accumulo/test/CloneIT.java
index a0f30b4..814982c 100644
--- a/test/src/main/java/org/apache/accumulo/test/CloneIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/CloneIT.java
@@ -23,6 +23,7 @@ import static org.junit.Assert.fail;
import java.util.HashSet;
import java.util.Map.Entry;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchWriter;
import org.apache.accumulo.core.client.Scanner;
@@ -45,7 +46,7 @@ public class CloneIT extends AccumuloClusterHarness {
@Test
public void testNoFiles() throws Exception {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(1)[0];
client.tableOperations().create(tableName);
@@ -73,7 +74,7 @@ public class CloneIT extends AccumuloClusterHarness {
@Test
public void testFilesChange() throws Exception {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(1)[0];
client.tableOperations().create(tableName);
@@ -129,7 +130,7 @@ public class CloneIT extends AccumuloClusterHarness {
// test split where files of children are the same
@Test
public void testSplit1() throws Exception {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(1)[0];
client.tableOperations().create(tableName);
@@ -172,7 +173,7 @@ public class CloneIT extends AccumuloClusterHarness {
// test split where files of children differ... like majc and split occurred
@Test
public void testSplit2() throws Exception {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(1)[0];
client.tableOperations().create(tableName);
@@ -247,7 +248,7 @@ public class CloneIT extends AccumuloClusterHarness {
// test two tablets splitting into four
@Test
public void testSplit3() throws Exception {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(1)[0];
client.tableOperations().create(tableName);
@@ -295,7 +296,7 @@ public class CloneIT extends AccumuloClusterHarness {
// test cloned marker
@Test
public void testClonedMarker() throws Exception {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(1)[0];
client.tableOperations().create(tableName);
@@ -360,7 +361,7 @@ public class CloneIT extends AccumuloClusterHarness {
// test two tablets splitting into four
@Test
public void testMerge() throws Exception {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(1)[0];
client.tableOperations().create(tableName);
diff --git a/test/src/main/java/org/apache/accumulo/test/CloseScannerIT.java b/test/src/main/java/org/apache/accumulo/test/CloseScannerIT.java
index 4594230..6a920c0 100644
--- a/test/src/main/java/org/apache/accumulo/test/CloseScannerIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/CloseScannerIT.java
@@ -21,6 +21,7 @@ import static org.junit.Assert.assertTrue;
import java.util.List;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.IsolatedScanner;
import org.apache.accumulo.core.client.Scanner;
@@ -40,7 +41,7 @@ public class CloseScannerIT extends AccumuloClusterHarness {
@Test
public void testManyScans() throws Exception {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(1)[0];
client.tableOperations().create(tableName);
diff --git a/test/src/main/java/org/apache/accumulo/test/ConditionalWriterIT.java b/test/src/main/java/org/apache/accumulo/test/ConditionalWriterIT.java
index 793f4c8..3508542 100644
--- a/test/src/main/java/org/apache/accumulo/test/ConditionalWriterIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/ConditionalWriterIT.java
@@ -134,7 +134,7 @@ public class ConditionalWriterIT extends AccumuloClusterHarness {
@Before
public void deleteUsers() throws Exception {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
Set<String> users = client.securityOperations().listLocalUsers();
ClusterUser user = getUser(0);
if (users.contains(user.getPrincipal())) {
@@ -146,7 +146,7 @@ public class ConditionalWriterIT extends AccumuloClusterHarness {
@Test
public void testBasic() throws Exception {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(1)[0];
client.tableOperations().create(tableName);
@@ -241,7 +241,7 @@ public class ConditionalWriterIT extends AccumuloClusterHarness {
@Test
public void testFields() throws Exception {
- try (AccumuloClient client1 = createAccumuloClient()) {
+ try (AccumuloClient client1 = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(1)[0];
String user = null;
@@ -349,7 +349,7 @@ public class ConditionalWriterIT extends AccumuloClusterHarness {
public void testBadColVis() throws Exception {
// test when a user sets a col vis in a condition that can never be seen
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(1)[0];
client.tableOperations().create(tableName);
@@ -462,7 +462,7 @@ public class ConditionalWriterIT extends AccumuloClusterHarness {
public void testConstraints() throws Exception {
// ensure constraint violations are properly reported
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(1)[0];
client.tableOperations().create(tableName);
@@ -495,7 +495,7 @@ public class ConditionalWriterIT extends AccumuloClusterHarness {
@Test
public void testIterators() throws Exception {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(1)[0];
client.tableOperations().create(tableName,
@@ -644,7 +644,7 @@ public class ConditionalWriterIT extends AccumuloClusterHarness {
public void testTableAndConditionIterators() throws Exception {
// test w/ table that has iterators configured
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(1)[0];
IteratorSetting aiConfig1 = new IteratorSetting(30, "AI1", AddingIterator.class);
@@ -741,7 +741,7 @@ public class ConditionalWriterIT extends AccumuloClusterHarness {
@Test
public void testBatch() throws Exception {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(1)[0];
client.tableOperations().create(tableName);
@@ -859,7 +859,7 @@ public class ConditionalWriterIT extends AccumuloClusterHarness {
@Test
public void testBigBatch() throws Exception {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(1)[0];
client.tableOperations().create(tableName);
@@ -934,7 +934,7 @@ public class ConditionalWriterIT extends AccumuloClusterHarness {
@Test
public void testBatchErrors() throws Exception {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(1)[0];
client.tableOperations().create(tableName);
@@ -1021,7 +1021,7 @@ public class ConditionalWriterIT extends AccumuloClusterHarness {
public void testSameRow() throws Exception {
// test multiple mutations for same row in same batch
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(1)[0];
client.tableOperations().create(tableName);
@@ -1209,7 +1209,7 @@ public class ConditionalWriterIT extends AccumuloClusterHarness {
// test multiple threads using a single conditional writer
String tableName = getUniqueNames(1)[0];
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
client.tableOperations().create(tableName);
@@ -1290,7 +1290,7 @@ public class ConditionalWriterIT extends AccumuloClusterHarness {
@Test
public void testSecurity() throws Exception {
// test against table user does not have read and/or write permissions for
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
String user = null;
// Create a new user
@@ -1356,7 +1356,7 @@ public class ConditionalWriterIT extends AccumuloClusterHarness {
@Test
public void testTimeout() throws Exception {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
String table = getUniqueNames(1)[0];
@@ -1409,7 +1409,7 @@ public class ConditionalWriterIT extends AccumuloClusterHarness {
@Test
public void testDeleteTable() throws Exception {
String table = getUniqueNames(1)[0];
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
try {
client.createConditionalWriter(table, new ConditionalWriterConfig());
@@ -1443,7 +1443,7 @@ public class ConditionalWriterIT extends AccumuloClusterHarness {
@Test
public void testOffline() throws Exception {
String table = getUniqueNames(1)[0];
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
client.tableOperations().create(table);
@@ -1477,7 +1477,7 @@ public class ConditionalWriterIT extends AccumuloClusterHarness {
@Test
public void testError() throws Exception {
String table = getUniqueNames(1)[0];
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
client.tableOperations().create(table);
@@ -1508,7 +1508,7 @@ public class ConditionalWriterIT extends AccumuloClusterHarness {
public void testNoConditions() throws AccumuloException, AccumuloSecurityException,
TableExistsException, TableNotFoundException {
String table = getUniqueNames(1)[0];
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
client.tableOperations().create(table);
@@ -1529,7 +1529,7 @@ public class ConditionalWriterIT extends AccumuloClusterHarness {
// Need to add a getClientConfig() to AccumuloCluster
Assume.assumeTrue(getClusterType() == ClusterType.MINI);
Process tracer = null;
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
AccumuloCluster cluster = getCluster();
MiniAccumuloClusterImpl mac = (MiniAccumuloClusterImpl) cluster;
if (!client.tableOperations().exists("trace")) {
diff --git a/test/src/main/java/org/apache/accumulo/test/FindMaxIT.java b/test/src/main/java/org/apache/accumulo/test/FindMaxIT.java
index bab0afe..b1fc374 100644
--- a/test/src/main/java/org/apache/accumulo/test/FindMaxIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/FindMaxIT.java
@@ -22,6 +22,7 @@ import static org.junit.Assert.assertNull;
import java.util.ArrayList;
import java.util.Map.Entry;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchWriter;
import org.apache.accumulo.core.client.Scanner;
@@ -49,7 +50,7 @@ public class FindMaxIT extends AccumuloClusterHarness {
@Test
public void test1() throws Exception {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(1)[0];
client.tableOperations().create(tableName);
diff --git a/test/src/main/java/org/apache/accumulo/test/ImportExportIT.java b/test/src/main/java/org/apache/accumulo/test/ImportExportIT.java
index 188dbda..1e8ac19 100644
--- a/test/src/main/java/org/apache/accumulo/test/ImportExportIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/ImportExportIT.java
@@ -29,6 +29,7 @@ import java.util.Iterator;
import java.util.Map.Entry;
import org.apache.accumulo.core.Constants;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchWriter;
import org.apache.accumulo.core.client.Scanner;
@@ -68,7 +69,7 @@ public class ImportExportIT extends AccumuloClusterHarness {
@Test
public void testExportImportThenScan() throws Exception {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
String[] tableNames = getUniqueNames(2);
String srcTable = tableNames[0], destTable = tableNames[1];
diff --git a/test/src/main/java/org/apache/accumulo/test/InterruptibleScannersIT.java b/test/src/main/java/org/apache/accumulo/test/InterruptibleScannersIT.java
index a7a0c72..59aba17 100644
--- a/test/src/main/java/org/apache/accumulo/test/InterruptibleScannersIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/InterruptibleScannersIT.java
@@ -20,6 +20,7 @@ import static org.junit.Assert.fail;
import java.util.ArrayList;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.IteratorSetting;
import org.apache.accumulo.core.client.Scanner;
@@ -50,7 +51,7 @@ public class InterruptibleScannersIT extends AccumuloClusterHarness {
public void test() throws Exception {
// make a table
final String tableName = getUniqueNames(1)[0];
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
client.tableOperations().create(tableName);
// make the world's slowest scanner
diff --git a/test/src/main/java/org/apache/accumulo/test/IsolationAndDeepCopyIT.java b/test/src/main/java/org/apache/accumulo/test/IsolationAndDeepCopyIT.java
index 5c704e6..ab672a6 100644
--- a/test/src/main/java/org/apache/accumulo/test/IsolationAndDeepCopyIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/IsolationAndDeepCopyIT.java
@@ -24,6 +24,7 @@ import static org.junit.Assert.assertTrue;
import java.util.Iterator;
import java.util.Map.Entry;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchWriter;
import org.apache.accumulo.core.client.IteratorSetting;
@@ -45,7 +46,7 @@ public class IsolationAndDeepCopyIT extends AccumuloClusterHarness {
// test bug fox for ACCUMULO-3977
String table = super.getUniqueNames(1)[0];
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
client.tableOperations().create(table);
diff --git a/test/src/main/java/org/apache/accumulo/test/IteratorEnvIT.java b/test/src/main/java/org/apache/accumulo/test/IteratorEnvIT.java
index de7044b..935b32b 100644
--- a/test/src/main/java/org/apache/accumulo/test/IteratorEnvIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/IteratorEnvIT.java
@@ -27,6 +27,7 @@ import java.util.EnumSet;
import java.util.Iterator;
import java.util.Map;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchWriter;
import org.apache.accumulo.core.client.IteratorSetting;
@@ -145,7 +146,7 @@ public class IteratorEnvIT extends AccumuloClusterHarness {
@Before
public void setup() {
- client = createAccumuloClient();
+ client = Accumulo.newClient().from(getClientProps()).build();
}
@After
diff --git a/test/src/main/java/org/apache/accumulo/test/KeyValueEqualityIT.java b/test/src/main/java/org/apache/accumulo/test/KeyValueEqualityIT.java
index f299e6c..5774619 100644
--- a/test/src/main/java/org/apache/accumulo/test/KeyValueEqualityIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/KeyValueEqualityIT.java
@@ -22,6 +22,7 @@ import static org.junit.Assert.assertFalse;
import java.util.Iterator;
import java.util.Map.Entry;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchWriter;
import org.apache.accumulo.core.client.admin.TableOperations;
@@ -41,7 +42,7 @@ public class KeyValueEqualityIT extends AccumuloClusterHarness {
@Test
public void testEquality() throws Exception {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
final String[] tables = getUniqueNames(2);
final String table1 = tables[0], table2 = tables[1];
diff --git a/test/src/main/java/org/apache/accumulo/test/LocatorIT.java b/test/src/main/java/org/apache/accumulo/test/LocatorIT.java
index 0c1605d..f721612 100644
--- a/test/src/main/java/org/apache/accumulo/test/LocatorIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/LocatorIT.java
@@ -31,6 +31,7 @@ import java.util.Map.Entry;
import java.util.Set;
import java.util.TreeSet;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.TableNotFoundException;
import org.apache.accumulo.core.client.TableOfflineException;
@@ -86,7 +87,7 @@ public class LocatorIT extends AccumuloClusterHarness {
@Test
public void testBasic() throws Exception {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(1)[0];
client.tableOperations().create(tableName);
diff --git a/test/src/main/java/org/apache/accumulo/test/MetaConstraintRetryIT.java b/test/src/main/java/org/apache/accumulo/test/MetaConstraintRetryIT.java
index 7947aa4..b3609ba 100644
--- a/test/src/main/java/org/apache/accumulo/test/MetaConstraintRetryIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/MetaConstraintRetryIT.java
@@ -17,6 +17,7 @@
package org.apache.accumulo.test;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.clientImpl.Writer;
import org.apache.accumulo.core.data.Mutation;
@@ -40,7 +41,7 @@ public class MetaConstraintRetryIT extends AccumuloClusterHarness {
// a test for ACCUMULO-3096
@Test(expected = ConstraintViolationException.class)
public void test() throws Exception {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
client.securityOperations().grantTablePermission(getAdminPrincipal(), MetadataTable.NAME,
TablePermission.WRITE);
diff --git a/test/src/main/java/org/apache/accumulo/test/MetaSplitIT.java b/test/src/main/java/org/apache/accumulo/test/MetaSplitIT.java
index 1247a8f..5da3d29 100644
--- a/test/src/main/java/org/apache/accumulo/test/MetaSplitIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/MetaSplitIT.java
@@ -24,6 +24,7 @@ import java.util.Collections;
import java.util.SortedSet;
import java.util.TreeSet;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.AccumuloException;
import org.apache.accumulo.core.client.AccumuloSecurityException;
@@ -52,7 +53,7 @@ public class MetaSplitIT extends AccumuloClusterHarness {
@Before
public void saveMetadataSplits() throws Exception {
if (getClusterType() == ClusterType.STANDALONE) {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
Collection<Text> splits = client.tableOperations().listSplits(MetadataTable.NAME);
// We expect a single split
if (!splits.equals(Arrays.asList(new Text("~")))) {
@@ -71,7 +72,7 @@ public class MetaSplitIT extends AccumuloClusterHarness {
public void restoreMetadataSplits() throws Exception {
if (metadataSplits != null) {
log.info("Restoring split on metadata table");
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
client.tableOperations().merge(MetadataTable.NAME, null, null);
client.tableOperations().addSplits(MetadataTable.NAME, new TreeSet<>(metadataSplits));
}
@@ -80,7 +81,7 @@ public class MetaSplitIT extends AccumuloClusterHarness {
@Test(expected = AccumuloException.class)
public void testRootTableSplit() throws Exception {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
SortedSet<Text> splits = new TreeSet<>();
splits.add(new Text("5"));
client.tableOperations().addSplits(RootTable.NAME, splits);
@@ -89,7 +90,7 @@ public class MetaSplitIT extends AccumuloClusterHarness {
@Test
public void testRootTableMerge() throws Exception {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
client.tableOperations().merge(RootTable.NAME, null, null);
}
}
@@ -104,7 +105,7 @@ public class MetaSplitIT extends AccumuloClusterHarness {
@Test
public void testMetadataTableSplit() throws Exception {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
TableOperations opts = client.tableOperations();
for (int i = 1; i <= 10; i++) {
opts.create(Integer.toString(i));
diff --git a/test/src/main/java/org/apache/accumulo/test/MultiTableBatchWriterIT.java b/test/src/main/java/org/apache/accumulo/test/MultiTableBatchWriterIT.java
index a5ba515..58b70c1 100644
--- a/test/src/main/java/org/apache/accumulo/test/MultiTableBatchWriterIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/MultiTableBatchWriterIT.java
@@ -25,6 +25,7 @@ import java.util.HashMap;
import java.util.Map;
import java.util.Map.Entry;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchWriter;
import org.apache.accumulo.core.client.MultiTableBatchWriter;
@@ -56,7 +57,7 @@ public class MultiTableBatchWriterIT extends AccumuloClusterHarness {
@Before
public void setUpArgs() {
- accumuloClient = createAccumuloClient();
+ accumuloClient = Accumulo.newClient().from(getClientProps()).build();
mtbw = getMultiTableBatchWriter();
}
diff --git a/test/src/main/java/org/apache/accumulo/test/NamespacesIT.java b/test/src/main/java/org/apache/accumulo/test/NamespacesIT.java
index 5119c97..2aa4a76 100644
--- a/test/src/main/java/org/apache/accumulo/test/NamespacesIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/NamespacesIT.java
@@ -105,7 +105,7 @@ public class NamespacesIT extends AccumuloClusterHarness {
Assume.assumeTrue(getClusterType() == ClusterType.MINI);
// prepare a unique namespace and get a new root client for each test
- c = createAccumuloClient();
+ c = Accumulo.newClient().from(getClientProps()).build();
namespace = "ns_" + getUniqueNames(1)[0];
}
diff --git a/test/src/main/java/org/apache/accumulo/test/NewTableConfigurationIT.java b/test/src/main/java/org/apache/accumulo/test/NewTableConfigurationIT.java
index b98d73b..23307ff 100644
--- a/test/src/main/java/org/apache/accumulo/test/NewTableConfigurationIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/NewTableConfigurationIT.java
@@ -27,6 +27,7 @@ import java.util.Map.Entry;
import java.util.Set;
import java.util.TreeMap;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.AccumuloException;
import org.apache.accumulo.core.client.AccumuloSecurityException;
@@ -67,7 +68,7 @@ public class NewTableConfigurationIT extends SharedMiniClusterBase {
@Test
public void testSetPropertiesOverwriteOlderProperties()
throws AccumuloSecurityException, AccumuloException, TableExistsException {
- try (AccumuloClient client = createClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(2)[0];
NewTableConfiguration ntc = new NewTableConfiguration();
Map<String,String> initialProps = new HashMap<>();
@@ -112,7 +113,7 @@ public class NewTableConfigurationIT extends SharedMiniClusterBase {
@Test
public void testSimpleLocalityGroupCreation() throws AccumuloSecurityException, AccumuloException,
TableExistsException, TableNotFoundException {
- try (AccumuloClient client = createClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(2)[0];
NewTableConfiguration ntc = new NewTableConfiguration();
// set locality groups map
@@ -139,7 +140,7 @@ public class NewTableConfigurationIT extends SharedMiniClusterBase {
@Test
public void testMulitpleCallsToSetLocalityGroups() throws AccumuloSecurityException,
AccumuloException, TableExistsException, TableNotFoundException {
- try (AccumuloClient client = createClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(2)[0];
NewTableConfiguration ntc = new NewTableConfiguration();
// set first locality groups map
@@ -166,7 +167,7 @@ public class NewTableConfigurationIT extends SharedMiniClusterBase {
@Test
public void testSetPropertiesAndGroups() throws AccumuloSecurityException, AccumuloException,
TableExistsException, TableNotFoundException {
- try (AccumuloClient client = createClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(2)[0];
NewTableConfiguration ntc = new NewTableConfiguration();
@@ -232,7 +233,7 @@ public class NewTableConfigurationIT extends SharedMiniClusterBase {
@Test
public void testSetGroupsWithoutDefaultIterators() throws AccumuloSecurityException,
AccumuloException, TableExistsException, TableNotFoundException {
- try (AccumuloClient client = createClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(2)[0];
NewTableConfiguration ntc = new NewTableConfiguration().withoutDefaultIterators();
@@ -258,7 +259,7 @@ public class NewTableConfigurationIT extends SharedMiniClusterBase {
@Test
public void testPreconfigureIteratorWithDefaultIterator1() throws AccumuloException,
TableNotFoundException, AccumuloSecurityException, TableExistsException {
- try (AccumuloClient client = createClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(2)[0];
NewTableConfiguration ntc = new NewTableConfiguration();
@@ -287,7 +288,7 @@ public class NewTableConfigurationIT extends SharedMiniClusterBase {
@Test
public void testPreconfiguredIteratorWithDefaultIterator2() throws AccumuloException,
TableNotFoundException, AccumuloSecurityException, TableExistsException {
- try (AccumuloClient client = createClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(2)[0];
NewTableConfiguration ntc = new NewTableConfiguration();
@@ -317,7 +318,7 @@ public class NewTableConfigurationIT extends SharedMiniClusterBase {
@Test
public void testPreconfiguredIteratorWithDefaultIterator3() throws AccumuloException,
TableNotFoundException, AccumuloSecurityException, TableExistsException {
- try (AccumuloClient client = createClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(2)[0];
NewTableConfiguration ntc = new NewTableConfiguration();
@@ -345,7 +346,7 @@ public class NewTableConfigurationIT extends SharedMiniClusterBase {
@Test
public void testSettingInitialIteratorWithAdditionalIteratorOptions() throws AccumuloException,
TableNotFoundException, AccumuloSecurityException, TableExistsException {
- try (AccumuloClient client = createClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(2)[0];
NewTableConfiguration ntc = new NewTableConfiguration();
@@ -368,7 +369,7 @@ public class NewTableConfigurationIT extends SharedMiniClusterBase {
@Test
public void testSetIteratorWithoutDefaultIterators() throws AccumuloException,
TableNotFoundException, AccumuloSecurityException, TableExistsException {
- try (AccumuloClient client = createClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(2)[0];
NewTableConfiguration ntc = new NewTableConfiguration().withoutDefaultIterators();
@@ -396,7 +397,7 @@ public class NewTableConfigurationIT extends SharedMiniClusterBase {
@Test
public void testSettingIteratorAndProperties() throws AccumuloException, TableNotFoundException,
AccumuloSecurityException, TableExistsException {
- try (AccumuloClient client = createClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(2)[0];
NewTableConfiguration ntc = new NewTableConfiguration();
@@ -436,7 +437,7 @@ public class NewTableConfigurationIT extends SharedMiniClusterBase {
@Test(expected = IllegalArgumentException.class)
public void testIteratorConflictFound1()
throws AccumuloException, AccumuloSecurityException, TableExistsException {
- try (AccumuloClient client = createClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(2)[0];
NewTableConfiguration ntc = new NewTableConfiguration();
@@ -451,7 +452,7 @@ public class NewTableConfigurationIT extends SharedMiniClusterBase {
@Test(expected = IllegalArgumentException.class)
public void testIteratorConflictFound2()
throws AccumuloException, AccumuloSecurityException, TableExistsException {
- try (AccumuloClient client = createClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(2)[0];
NewTableConfiguration ntc = new NewTableConfiguration();
@@ -466,7 +467,7 @@ public class NewTableConfigurationIT extends SharedMiniClusterBase {
@Test(expected = IllegalArgumentException.class)
public void testIteratorConflictFound3()
throws AccumuloException, AccumuloSecurityException, TableExistsException {
- try (AccumuloClient client = createClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(2)[0];
NewTableConfiguration ntc = new NewTableConfiguration();
@@ -485,7 +486,7 @@ public class NewTableConfigurationIT extends SharedMiniClusterBase {
@Test
public void testMultipleIteratorValid() throws AccumuloException, TableNotFoundException,
AccumuloSecurityException, TableExistsException {
- try (AccumuloClient client = createClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(2)[0];
NewTableConfiguration ntc = new NewTableConfiguration();
@@ -515,7 +516,7 @@ public class NewTableConfigurationIT extends SharedMiniClusterBase {
@Test
public void testGroupsIteratorAndPropsTogether() throws AccumuloException, TableNotFoundException,
AccumuloSecurityException, TableExistsException {
- try (AccumuloClient client = createClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(2)[0];
NewTableConfiguration ntc = new NewTableConfiguration();
@@ -557,7 +558,7 @@ public class NewTableConfigurationIT extends SharedMiniClusterBase {
@Test
public void testNtcChaining() throws AccumuloException, AccumuloSecurityException,
TableExistsException, TableNotFoundException {
- try (AccumuloClient client = createClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(2)[0];
IteratorSetting setting = new IteratorSetting(10, "anIterator", "it.class",
diff --git a/test/src/main/java/org/apache/accumulo/test/OrIteratorIT.java b/test/src/main/java/org/apache/accumulo/test/OrIteratorIT.java
index 9c39c45..673ac3e 100644
--- a/test/src/main/java/org/apache/accumulo/test/OrIteratorIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/OrIteratorIT.java
@@ -31,6 +31,7 @@ import java.util.Map.Entry;
import java.util.Set;
import java.util.TreeSet;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchScanner;
import org.apache.accumulo.core.client.BatchWriter;
@@ -57,7 +58,7 @@ public class OrIteratorIT extends AccumuloClusterHarness {
@Test
public void testMultipleRowsInTablet() throws Exception {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
final String tableName = getUniqueNames(1)[0];
client.tableOperations().create(tableName);
@@ -99,7 +100,7 @@ public class OrIteratorIT extends AccumuloClusterHarness {
@Test
public void testMultipleTablets() throws Exception {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
final String tableName = getUniqueNames(1)[0];
client.tableOperations().create(tableName);
@@ -151,7 +152,7 @@ public class OrIteratorIT extends AccumuloClusterHarness {
@Test
public void testSingleLargeRow() throws Exception {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
final String tableName = getUniqueNames(1)[0];
client.tableOperations().create(tableName);
client.tableOperations().setProperty(tableName, Property.TABLE_SCAN_MAXMEM.getKey(), "1");
@@ -199,7 +200,7 @@ public class OrIteratorIT extends AccumuloClusterHarness {
@Test
public void testNoMatchesForTable() throws Exception {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
final String tableName = getUniqueNames(1)[0];
client.tableOperations().create(tableName);
@@ -232,7 +233,7 @@ public class OrIteratorIT extends AccumuloClusterHarness {
@Test
public void testNoMatchesInSingleTablet() throws Exception {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
final String tableName = getUniqueNames(1)[0];
client.tableOperations().create(tableName);
@@ -287,7 +288,7 @@ public class OrIteratorIT extends AccumuloClusterHarness {
@Test
public void testResultOrder() throws Exception {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
final String tableName = getUniqueNames(1)[0];
client.tableOperations().create(tableName);
diff --git a/test/src/main/java/org/apache/accumulo/test/RecoveryCompactionsAreFlushesIT.java b/test/src/main/java/org/apache/accumulo/test/RecoveryCompactionsAreFlushesIT.java
index 4a82b33..3239fa4 100644
--- a/test/src/main/java/org/apache/accumulo/test/RecoveryCompactionsAreFlushesIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/RecoveryCompactionsAreFlushesIT.java
@@ -21,6 +21,7 @@ import static org.junit.Assert.assertFalse;
import java.util.Map.Entry;
import org.apache.accumulo.cluster.ClusterControl;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchWriter;
import org.apache.accumulo.core.client.Scanner;
@@ -60,7 +61,7 @@ public class RecoveryCompactionsAreFlushesIT extends AccumuloClusterHarness {
public void test() throws Exception {
// create a table
String tableName = getUniqueNames(1)[0];
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
c.tableOperations().create(tableName);
c.tableOperations().setProperty(tableName, Property.TABLE_MAJC_RATIO.getKey(), "100");
c.tableOperations().setProperty(tableName, Property.TABLE_FILE_MAX.getKey(), "3");
diff --git a/test/src/main/java/org/apache/accumulo/test/SampleIT.java b/test/src/main/java/org/apache/accumulo/test/SampleIT.java
index eb5fbdc..82dbefa 100644
--- a/test/src/main/java/org/apache/accumulo/test/SampleIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/SampleIT.java
@@ -32,6 +32,7 @@ import java.util.Map.Entry;
import java.util.Set;
import java.util.TreeMap;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.AccumuloException;
import org.apache.accumulo.core.client.AccumuloSecurityException;
@@ -124,7 +125,7 @@ public class SampleIT extends AccumuloClusterHarness {
@Test
public void testBasic() throws Exception {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(1)[0];
String clone = tableName + "_clone";
@@ -302,7 +303,7 @@ public class SampleIT extends AccumuloClusterHarness {
@Test
public void testIterator() throws Exception {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(1)[0];
String clone = tableName + "_clone";
@@ -415,7 +416,7 @@ public class SampleIT extends AccumuloClusterHarness {
@Test
public void testSampleNotPresent() throws Exception {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(1)[0];
String clone = tableName + "_clone";
diff --git a/test/src/main/java/org/apache/accumulo/test/ScanFlushWithTimeIT.java b/test/src/main/java/org/apache/accumulo/test/ScanFlushWithTimeIT.java
index c925f31..8e1ce01 100644
--- a/test/src/main/java/org/apache/accumulo/test/ScanFlushWithTimeIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/ScanFlushWithTimeIT.java
@@ -23,6 +23,7 @@ import java.util.SortedSet;
import java.util.TreeSet;
import java.util.concurrent.TimeUnit;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchScanner;
import org.apache.accumulo.core.client.BatchWriter;
@@ -49,7 +50,7 @@ public class ScanFlushWithTimeIT extends AccumuloClusterHarness {
public void test() throws Exception {
log.info("Creating table");
String tableName = getUniqueNames(1)[0];
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
c.tableOperations().create(tableName);
log.info("Adding slow iterator");
IteratorSetting setting = new IteratorSetting(50, SlowIterator.class);
diff --git a/test/src/main/java/org/apache/accumulo/test/ShellConfigIT.java b/test/src/main/java/org/apache/accumulo/test/ShellConfigIT.java
index d481956..854212d 100644
--- a/test/src/main/java/org/apache/accumulo/test/ShellConfigIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/ShellConfigIT.java
@@ -25,6 +25,7 @@ import static org.junit.Assert.fail;
import java.io.File;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.security.tokens.AuthenticationToken;
import org.apache.accumulo.core.client.security.tokens.KerberosToken;
@@ -49,7 +50,7 @@ public class ShellConfigIT extends AccumuloClusterHarness {
@Before
public void checkProperty() throws Exception {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
// TABLE_VOLUME_CHOOSER is a valid property that can be updated in ZK, whereas the crypto
// properties are not.
// This lets us run this test more generically rather than forcibly needing to update some
@@ -64,7 +65,7 @@ public class ShellConfigIT extends AccumuloClusterHarness {
@After
public void resetProperty() throws Exception {
if (origPropValue != null) {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
client.instanceOperations().setProperty(PERTABLE_CHOOSER_PROP, origPropValue);
}
}
diff --git a/test/src/main/java/org/apache/accumulo/test/ShellServerIT.java b/test/src/main/java/org/apache/accumulo/test/ShellServerIT.java
index 39abb04..a6b0775 100644
--- a/test/src/main/java/org/apache/accumulo/test/ShellServerIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/ShellServerIT.java
@@ -47,6 +47,7 @@ import java.util.Iterator;
import java.util.List;
import java.util.Map;
import java.util.Map.Entry;
+import java.util.Properties;
import java.util.Random;
import java.util.Set;
import java.util.SortedSet;
@@ -55,6 +56,7 @@ import java.util.UUID;
import java.util.concurrent.TimeUnit;
import org.apache.accumulo.core.Constants;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.AccumuloException;
import org.apache.accumulo.core.client.AccumuloSecurityException;
@@ -304,12 +306,13 @@ public class ShellServerIT extends SharedMiniClusterBase {
traceProcess = getCluster().exec(TraceServer.class).getProcess();
- AccumuloClient client = getCluster().createAccumuloClient(getPrincipal(), getToken());
- TableOperations tops = client.tableOperations();
-
- // give the tracer some time to start
- while (!tops.exists("trace")) {
- sleepUninterruptibly(1, TimeUnit.SECONDS);
+ Properties props = getCluster().getClientProperties();
+ try (AccumuloClient client = Accumulo.newClient().from(props).build()) {
+ TableOperations tops = client.tableOperations();
+ // give the tracer some time to start
+ while (!tops.exists("trace")) {
+ sleepUninterruptibly(1, TimeUnit.SECONDS);
+ }
}
}
@@ -331,7 +334,7 @@ public class ShellServerIT extends SharedMiniClusterBase {
@After
public void deleteTables() throws Exception {
- try (AccumuloClient c = createClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
for (String table : c.tableOperations().list()) {
if (!table.startsWith(Namespace.ACCUMULO.name() + ".") && !table.equals("trace"))
try {
@@ -612,7 +615,7 @@ public class ShellServerIT extends SharedMiniClusterBase {
@Test
public void setIterOptionPrompt() throws Exception {
- try (AccumuloClient client = createClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = name.getMethodName();
ts.exec("createtable " + tableName);
@@ -736,7 +739,7 @@ public class ShellServerIT extends SharedMiniClusterBase {
new ErrorMessageCallback() {
@Override
public String getErrorMessage() {
- try (AccumuloClient c = createClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
return "Current auths for root are: "
+ c.securityOperations().getUserAuthorizations("root");
} catch (Exception e) {
@@ -873,7 +876,7 @@ public class ShellServerIT extends SharedMiniClusterBase {
ts.exec("insert a b c value", true);
ts.exec("scan", true, "value", true);
- try (AccumuloClient accumuloClient = createClient()) {
+ try (AccumuloClient accumuloClient = Accumulo.newClient().from(getClientProps()).build()) {
for (Entry<String,String> entry : accumuloClient.tableOperations().getProperties(table)) {
if (entry.getKey().equals("table.custom.description"))
assertEquals("Initial property was not set correctly", "description", entry.getValue());
@@ -1564,7 +1567,7 @@ public class ShellServerIT extends SharedMiniClusterBase {
ts.exec("insert " + i + " cf cq value", true);
}
- try (AccumuloClient accumuloClient = createClient();
+ try (AccumuloClient accumuloClient = Accumulo.newClient().from(getClientProps()).build();
Scanner s = accumuloClient.createScanner(table, Authorizations.EMPTY)) {
IteratorSetting cfg = new IteratorSetting(30, SlowIterator.class);
SlowIterator.setSleepTime(cfg, 500);
@@ -2003,7 +2006,7 @@ public class ShellServerIT extends SharedMiniClusterBase {
}
private String getTableId(String tableName) throws Exception {
- try (AccumuloClient client = createClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
for (int i = 0; i < 5; i++) {
Map<String,String> nameToId = client.tableOperations().tableIdMap();
@@ -2151,7 +2154,7 @@ public class ShellServerIT extends SharedMiniClusterBase {
public void testCreateTableWithLocalityGroups() throws Exception {
final String table = name.getMethodName();
ts.exec("createtable " + table + " -l locg1=fam1,fam2", true);
- try (AccumuloClient accumuloClient = createClient()) {
+ try (AccumuloClient accumuloClient = Accumulo.newClient().from(getClientProps()).build()) {
Map<String,Set<Text>> lMap = accumuloClient.tableOperations().getLocalityGroups(table);
Set<Text> expectedColFams = new HashSet<>(Arrays.asList(new Text("fam1"), new Text("fam2")));
for (Entry<String,Set<Text>> entry : lMap.entrySet()) {
@@ -2171,7 +2174,7 @@ public class ShellServerIT extends SharedMiniClusterBase {
public void testCreateTableWithMultipleLocalityGroups() throws Exception {
final String table = name.getMethodName();
ts.exec("createtable " + table + " -l locg1=fam1,fam2 locg2=colfam1", true);
- try (AccumuloClient accumuloClient = createClient()) {
+ try (AccumuloClient accumuloClient = Accumulo.newClient().from(getClientProps()).build()) {
Map<String,Set<Text>> lMap = accumuloClient.tableOperations().getLocalityGroups(table);
assertTrue(lMap.keySet().contains("locg1"));
assertTrue(lMap.keySet().contains("locg2"));
@@ -2332,7 +2335,7 @@ public class ShellServerIT extends SharedMiniClusterBase {
public void testCreateTableWithSplitsFile1()
throws IOException, AccumuloSecurityException, TableNotFoundException, AccumuloException {
String splitsFile = null;
- try (AccumuloClient client = createClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
splitsFile = System.getProperty("user.dir") + "/target/splitFile";
generateSplitsFile(splitsFile, 1000, 12, false, false, true, false, false);
SortedSet<Text> expectedSplits = readSplitsFromFile(splitsFile, false);
@@ -2354,7 +2357,7 @@ public class ShellServerIT extends SharedMiniClusterBase {
public void testCreateTableWithSplitsFile2()
throws IOException, AccumuloSecurityException, TableNotFoundException, AccumuloException {
String splitsFile = null;
- try (AccumuloClient client = createClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
splitsFile = System.getProperty("user.dir") + "/target/splitFile";
generateSplitsFile(splitsFile, 300, 12, false, false, false, false, false);
SortedSet<Text> expectedSplits = readSplitsFromFile(splitsFile, false);
@@ -2376,7 +2379,7 @@ public class ShellServerIT extends SharedMiniClusterBase {
public void testCreateTableWithSplitsFile3()
throws IOException, AccumuloSecurityException, TableNotFoundException, AccumuloException {
String splitsFile = null;
- try (AccumuloClient client = createClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
splitsFile = System.getProperty("user.dir") + "/target/splitFile";
generateSplitsFile(splitsFile, 100, 23, false, true, true, false, false);
SortedSet<Text> expectedSplits = readSplitsFromFile(splitsFile, false);
@@ -2398,7 +2401,7 @@ public class ShellServerIT extends SharedMiniClusterBase {
public void testCreateTableWithSplitsFile4()
throws IOException, AccumuloSecurityException, TableNotFoundException, AccumuloException {
String splitsFile = null;
- try (AccumuloClient client = createClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
splitsFile = System.getProperty("user.dir") + "/target/splitFile";
generateSplitsFile(splitsFile, 100, 31, false, false, true, true, false);
SortedSet<Text> expectedSplits = readSplitsFromFile(splitsFile, false);
@@ -2420,7 +2423,7 @@ public class ShellServerIT extends SharedMiniClusterBase {
public void testCreateTableWithSplitsFile5()
throws IOException, AccumuloSecurityException, TableNotFoundException, AccumuloException {
String splitsFile = null;
- try (AccumuloClient client = createClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
splitsFile = System.getProperty("user.dir") + "/target/splitFile";
generateSplitsFile(splitsFile, 100, 32, false, false, true, false, true);
SortedSet<Text> expectedSplits = readSplitsFromFile(splitsFile, false);
@@ -2442,7 +2445,7 @@ public class ShellServerIT extends SharedMiniClusterBase {
public void testCreateTableWithSplitsFile6()
throws IOException, AccumuloSecurityException, TableNotFoundException, AccumuloException {
String splitsFile = null;
- try (AccumuloClient client = createClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
splitsFile = System.getProperty("user.dir") + "/target/splitFile";
generateSplitsFile(splitsFile, 100, 12, false, false, false, true, true);
SortedSet<Text> expectedSplits = readSplitsFromFile(splitsFile, false);
@@ -2464,7 +2467,7 @@ public class ShellServerIT extends SharedMiniClusterBase {
public void testCreateTableWithSplitsFile7()
throws IOException, AccumuloSecurityException, TableNotFoundException, AccumuloException {
String splitsFile = null;
- try (AccumuloClient client = createClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
splitsFile = System.getProperty("user.dir") + "/target/splitFile";
generateSplitsFile(splitsFile, 100, 12, false, false, true, true, true);
SortedSet<Text> expectedSplits = readSplitsFromFile(splitsFile, false);
@@ -2486,7 +2489,7 @@ public class ShellServerIT extends SharedMiniClusterBase {
public void testCreateTableWithEmptySplitFile()
throws IOException, AccumuloSecurityException, TableNotFoundException, AccumuloException {
String splitsFile = null;
- try (AccumuloClient client = createClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
splitsFile = System.getProperty("user.dir") + "/target/splitFile";
generateSplitsFile(splitsFile, 0, 0, false, false, false, false, false);
SortedSet<Text> expectedSplits = readSplitsFromFile(splitsFile, false);
@@ -2506,7 +2509,7 @@ public class ShellServerIT extends SharedMiniClusterBase {
public void testCreateTableWithCopySplitsFromOtherTable()
throws IOException, AccumuloSecurityException, TableNotFoundException, AccumuloException {
// create a table and add some splits
- try (AccumuloClient client = createClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
final String tableName1 = name.getMethodName() + "_table1";
ts.exec("createtable " + tableName1, true);
String output = ts.exec("tables", true);
@@ -2543,7 +2546,7 @@ public class ShellServerIT extends SharedMiniClusterBase {
public void testCreateTableWithBinarySplitsFile1()
throws IOException, AccumuloSecurityException, TableNotFoundException, AccumuloException {
String splitsFile = null;
- try (AccumuloClient client = createClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
splitsFile = System.getProperty("user.dir") + "/target/splitFile";
generateSplitsFile(splitsFile, 200, 12, true, true, true, false, false);
SortedSet<Text> expectedSplits = readSplitsFromFile(splitsFile, false);
@@ -2565,7 +2568,7 @@ public class ShellServerIT extends SharedMiniClusterBase {
public void testCreateTableWithBinarySplitsFile2()
throws IOException, AccumuloSecurityException, TableNotFoundException, AccumuloException {
String splitsFile = null;
- try (AccumuloClient client = createClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
splitsFile = System.getProperty("user.dir") + "/target/splitFile";
generateSplitsFile(splitsFile, 300, 12, true, true, false, false, false);
SortedSet<Text> expectedSplits = readSplitsFromFile(splitsFile, false);
@@ -2587,7 +2590,7 @@ public class ShellServerIT extends SharedMiniClusterBase {
public void testCreateTableWithBinarySplitsFile3()
throws IOException, AccumuloSecurityException, TableNotFoundException, AccumuloException {
String splitsFile = null;
- try (AccumuloClient client = createClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
splitsFile = System.getProperty("user.dir") + "/target/splitFile";
generateSplitsFile(splitsFile, 100, 23, true, true, true, false, false);
SortedSet<Text> expectedSplits = readSplitsFromFile(splitsFile, false);
@@ -2609,7 +2612,7 @@ public class ShellServerIT extends SharedMiniClusterBase {
public void testCreateTableWithBinarySplitsFile4()
throws IOException, AccumuloSecurityException, TableNotFoundException, AccumuloException {
String splitsFile = null;
- try (AccumuloClient client = createClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
splitsFile = System.getProperty("user.dir") + "/target/splitFile";
generateSplitsFile(splitsFile, 100, 31, true, true, true, true, false);
SortedSet<Text> expectedSplits = readSplitsFromFile(splitsFile, false);
@@ -2631,7 +2634,7 @@ public class ShellServerIT extends SharedMiniClusterBase {
public void testCreateTableWithBinarySplitsFile5()
throws IOException, AccumuloSecurityException, TableNotFoundException, AccumuloException {
String splitsFile = null;
- try (AccumuloClient client = createClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
splitsFile = System.getProperty("user.dir") + "/target/splitFile";
generateSplitsFile(splitsFile, 100, 32, true, true, true, false, true);
SortedSet<Text> expectedSplits = readSplitsFromFile(splitsFile, false);
@@ -2653,7 +2656,7 @@ public class ShellServerIT extends SharedMiniClusterBase {
public void testCreateTableWithBinarySplitsFile6()
throws IOException, AccumuloSecurityException, TableNotFoundException, AccumuloException {
String splitsFile = null;
- try (AccumuloClient client = createClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
splitsFile = System.getProperty("user.dir") + "/target/splitFile";
generateSplitsFile(splitsFile, 100, 12, true, true, false, true, true);
SortedSet<Text> expectedSplits = readSplitsFromFile(splitsFile, false);
@@ -2675,7 +2678,7 @@ public class ShellServerIT extends SharedMiniClusterBase {
public void testCreateTableWithBinarySplitsFile7()
throws IOException, AccumuloSecurityException, TableNotFoundException, AccumuloException {
String splitsFile = null;
- try (AccumuloClient client = createClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
splitsFile = System.getProperty("user.dir") + "/target/splitFile";
generateSplitsFile(splitsFile, 100, 12, true, true, true, true, true);
SortedSet<Text> expectedSplits = readSplitsFromFile(splitsFile, false);
diff --git a/test/src/main/java/org/apache/accumulo/test/SplitCancelsMajCIT.java b/test/src/main/java/org/apache/accumulo/test/SplitCancelsMajCIT.java
index 2645022..3927049 100644
--- a/test/src/main/java/org/apache/accumulo/test/SplitCancelsMajCIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/SplitCancelsMajCIT.java
@@ -25,6 +25,7 @@ import java.util.TreeSet;
import java.util.concurrent.TimeUnit;
import java.util.concurrent.atomic.AtomicReference;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchWriter;
import org.apache.accumulo.core.client.IteratorSetting;
@@ -59,7 +60,7 @@ public class SplitCancelsMajCIT extends SharedMiniClusterBase {
@Test
public void test() throws Exception {
final String tableName = getUniqueNames(1)[0];
- try (AccumuloClient c = createClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
c.tableOperations().create(tableName);
// majc should take 100 * .5 secs
IteratorSetting it = new IteratorSetting(100, SlowIterator.class);
diff --git a/test/src/main/java/org/apache/accumulo/test/SplitRecoveryIT.java b/test/src/main/java/org/apache/accumulo/test/SplitRecoveryIT.java
index a2ca838..a28b319 100644
--- a/test/src/main/java/org/apache/accumulo/test/SplitRecoveryIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/SplitRecoveryIT.java
@@ -22,6 +22,7 @@ import static org.junit.Assert.assertEquals;
import java.util.Map.Entry;
import java.util.concurrent.TimeUnit;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchWriter;
import org.apache.accumulo.core.client.Scanner;
@@ -70,7 +71,7 @@ public class SplitRecoveryIT extends AccumuloClusterHarness {
String tableName = getUniqueNames(1)[0];
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
for (int tn = 0; tn < 2; tn++) {
// create a table and put some data in it
client.tableOperations().create(tableName);
diff --git a/test/src/main/java/org/apache/accumulo/test/TableConfigurationUpdateIT.java b/test/src/main/java/org/apache/accumulo/test/TableConfigurationUpdateIT.java
index d7361d7..24d92c6 100644
--- a/test/src/main/java/org/apache/accumulo/test/TableConfigurationUpdateIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/TableConfigurationUpdateIT.java
@@ -29,6 +29,7 @@ import java.util.concurrent.Executors;
import java.util.concurrent.Future;
import java.util.concurrent.TimeUnit;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.clientImpl.Namespace;
import org.apache.accumulo.core.conf.AccumuloConfiguration;
@@ -53,7 +54,7 @@ public class TableConfigurationUpdateIT extends AccumuloClusterHarness {
@Test
public void test() throws Exception {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
ServerContext context = getCluster().getServerContext();
String table = getUniqueNames(1)[0];
diff --git a/test/src/main/java/org/apache/accumulo/test/TableOperationsIT.java b/test/src/main/java/org/apache/accumulo/test/TableOperationsIT.java
index eaf021b..bf61995 100644
--- a/test/src/main/java/org/apache/accumulo/test/TableOperationsIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/TableOperationsIT.java
@@ -37,6 +37,7 @@ import java.util.TreeMap;
import java.util.TreeSet;
import java.util.concurrent.TimeUnit;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.AccumuloException;
import org.apache.accumulo.core.client.AccumuloSecurityException;
@@ -79,7 +80,7 @@ public class TableOperationsIT extends AccumuloClusterHarness {
@Before
public void setup() {
- accumuloClient = createAccumuloClient();
+ accumuloClient = Accumulo.newClient().from(getClientProps()).build();
}
@After
diff --git a/test/src/main/java/org/apache/accumulo/test/ThriftServerBindsBeforeZooKeeperLockIT.java b/test/src/main/java/org/apache/accumulo/test/ThriftServerBindsBeforeZooKeeperLockIT.java
index bf45d07..9b23e82 100644
--- a/test/src/main/java/org/apache/accumulo/test/ThriftServerBindsBeforeZooKeeperLockIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/ThriftServerBindsBeforeZooKeeperLockIT.java
@@ -24,6 +24,7 @@ import java.util.Collection;
import java.util.List;
import org.apache.accumulo.core.Constants;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.conf.Property;
import org.apache.accumulo.core.util.MonitorUtil;
@@ -132,7 +133,7 @@ public class ThriftServerBindsBeforeZooKeeperLockIT extends AccumuloClusterHarne
@Test
public void testMasterService() throws Exception {
final MiniAccumuloClusterImpl cluster = (MiniAccumuloClusterImpl) getCluster();
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
final String instanceID = client.instanceOperations().getInstanceID();
// Wait for the Master to grab its lock
@@ -200,7 +201,7 @@ public class ThriftServerBindsBeforeZooKeeperLockIT extends AccumuloClusterHarne
@Test
public void testGarbageCollectorPorts() throws Exception {
final MiniAccumuloClusterImpl cluster = (MiniAccumuloClusterImpl) getCluster();
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
String instanceID = client.instanceOperations().getInstanceID();
// Wait for the Master to grab its lock
diff --git a/test/src/main/java/org/apache/accumulo/test/TransportCachingIT.java b/test/src/main/java/org/apache/accumulo/test/TransportCachingIT.java
index 7044314..58070f2 100644
--- a/test/src/main/java/org/apache/accumulo/test/TransportCachingIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/TransportCachingIT.java
@@ -25,6 +25,7 @@ import java.util.ArrayList;
import java.util.List;
import org.apache.accumulo.core.Constants;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.clientImpl.ClientContext;
import org.apache.accumulo.core.clientImpl.ThriftTransportKey;
@@ -51,7 +52,7 @@ public class TransportCachingIT extends AccumuloClusterHarness {
@Test
public void testCachedTransport() throws InterruptedException {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
while (client.instanceOperations().getTabletServers().isEmpty()) {
// sleep until a tablet server is up
Thread.sleep(50);
diff --git a/test/src/main/java/org/apache/accumulo/test/UserCompactionStrategyIT.java b/test/src/main/java/org/apache/accumulo/test/UserCompactionStrategyIT.java
index 6bbf1bb..809fc7f 100644
--- a/test/src/main/java/org/apache/accumulo/test/UserCompactionStrategyIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/UserCompactionStrategyIT.java
@@ -33,6 +33,7 @@ import java.util.Random;
import java.util.Set;
import java.util.TreeSet;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.AccumuloException;
import org.apache.accumulo.core.client.BatchWriter;
@@ -72,7 +73,7 @@ public class UserCompactionStrategyIT extends AccumuloClusterHarness {
@After
public void checkForDanglingFateLocks() {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
assertNotNull(c);
FunctionalTestUtils.assertNoDanglingFateLocks((ClientContext) c, getCluster());
}
@@ -80,7 +81,7 @@ public class UserCompactionStrategyIT extends AccumuloClusterHarness {
@Test
public void testDropA() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(1)[0];
c.tableOperations().create(tableName);
@@ -112,7 +113,7 @@ public class UserCompactionStrategyIT extends AccumuloClusterHarness {
private void testDropNone(Map<String,String> options) throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(1)[0];
c.tableOperations().create(tableName);
@@ -154,7 +155,7 @@ public class UserCompactionStrategyIT extends AccumuloClusterHarness {
// test per-table classpath + user specified compaction strategy
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
final String tableName = getUniqueNames(1)[0];
File target = new File(System.getProperty("user.dir"), "target");
assertTrue(target.mkdirs() || target.isDirectory());
@@ -201,7 +202,7 @@ public class UserCompactionStrategyIT extends AccumuloClusterHarness {
public void testIterators() throws Exception {
// test compaction strategy + iterators
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(1)[0];
c.tableOperations().create(tableName);
@@ -245,7 +246,7 @@ public class UserCompactionStrategyIT extends AccumuloClusterHarness {
@Test
public void testFileSize() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(1)[0];
c.tableOperations().create(tableName);
@@ -282,7 +283,7 @@ public class UserCompactionStrategyIT extends AccumuloClusterHarness {
public void testConcurrent() throws Exception {
// two compactions without iterators or strategy should be able to run concurrently
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(1)[0];
c.tableOperations().create(tableName);
diff --git a/test/src/main/java/org/apache/accumulo/test/UsersIT.java b/test/src/main/java/org/apache/accumulo/test/UsersIT.java
index af6ecc4..8fccd2e 100644
--- a/test/src/main/java/org/apache/accumulo/test/UsersIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/UsersIT.java
@@ -23,6 +23,7 @@ import static org.junit.Assert.fail;
import java.util.Set;
import org.apache.accumulo.cluster.ClusterUser;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.AccumuloSecurityException;
import org.apache.accumulo.core.client.security.SecurityErrorCode;
@@ -35,7 +36,7 @@ public class UsersIT extends AccumuloClusterHarness {
@Test
public void testCreateExistingUser() throws Exception {
ClusterUser user0 = getUser(0);
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
Set<String> currentUsers = client.securityOperations().listLocalUsers();
// Ensure that the user exists
diff --git a/test/src/main/java/org/apache/accumulo/test/YieldScannersIT.java b/test/src/main/java/org/apache/accumulo/test/YieldScannersIT.java
index c987b7c..65b4a9a 100644
--- a/test/src/main/java/org/apache/accumulo/test/YieldScannersIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/YieldScannersIT.java
@@ -22,6 +22,7 @@ import java.util.Collections;
import java.util.Iterator;
import java.util.Map;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchScanner;
import org.apache.accumulo.core.client.BatchWriter;
@@ -62,7 +63,7 @@ public class YieldScannersIT extends AccumuloClusterHarness {
public void testScan() throws Exception {
// make a table
final String tableName = getUniqueNames(1)[0];
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
client.tableOperations().create(tableName);
final BatchWriter writer = client.createBatchWriter(tableName, new BatchWriterConfig());
for (int i = 0; i < 10; i++) {
@@ -117,7 +118,7 @@ public class YieldScannersIT extends AccumuloClusterHarness {
public void testBatchScan() throws Exception {
// make a table
final String tableName = getUniqueNames(1)[0];
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
client.tableOperations().create(tableName);
final BatchWriter writer = client.createBatchWriter(tableName, new BatchWriterConfig());
for (int i = 0; i < 10; i++) {
diff --git a/test/src/main/java/org/apache/accumulo/test/ZooKeeperPropertiesIT.java b/test/src/main/java/org/apache/accumulo/test/ZooKeeperPropertiesIT.java
index 7a4d17d..a7db535 100644
--- a/test/src/main/java/org/apache/accumulo/test/ZooKeeperPropertiesIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/ZooKeeperPropertiesIT.java
@@ -16,6 +16,7 @@
*/
package org.apache.accumulo.test;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.AccumuloException;
import org.apache.accumulo.core.conf.Property;
@@ -26,7 +27,7 @@ public class ZooKeeperPropertiesIT extends AccumuloClusterHarness {
@Test(expected = AccumuloException.class)
public void testNoFiles() throws Exception {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
// Should throw an error as this property can't be changed in ZooKeeper
client.instanceOperations().setProperty(Property.GENERAL_RPC_TIMEOUT.getKey(), "60s");
}
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/AccumuloClientIT.java b/test/src/main/java/org/apache/accumulo/test/functional/AccumuloClientIT.java
index 12e18f2..321e3d4 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/AccumuloClientIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/AccumuloClientIT.java
@@ -62,7 +62,7 @@ public class AccumuloClientIT extends AccumuloClusterHarness {
@SuppressWarnings("deprecation")
@Test
public void testGetConnectorFromAccumuloClient() throws Exception {
- AccumuloClient client = createAccumuloClient();
+ AccumuloClient client = Accumulo.newClient().from(getClientProps()).build();
org.apache.accumulo.core.client.Connector c = org.apache.accumulo.core.client.Connector
.from(client);
assertEquals(client.whoami(), c.whoami());
@@ -75,7 +75,7 @@ public class AccumuloClientIT extends AccumuloClusterHarness {
@Test
public void testAccumuloClientBuilder() throws Exception {
- AccumuloClient c = createAccumuloClient();
+ AccumuloClient c = Accumulo.newClient().from(getClientProps()).build();
String instanceName = getClientInfo().getInstanceName();
String zookeepers = getClientInfo().getZooKeepers();
final String user = "testuser";
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/AddSplitIT.java b/test/src/main/java/org/apache/accumulo/test/functional/AddSplitIT.java
index 7ee3e3c..29d6fae 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/AddSplitIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/AddSplitIT.java
@@ -25,6 +25,7 @@ import java.util.Map.Entry;
import java.util.TreeSet;
import java.util.concurrent.TimeUnit;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchWriter;
import org.apache.accumulo.core.client.Scanner;
@@ -47,7 +48,7 @@ public class AddSplitIT extends AccumuloClusterHarness {
public void addSplitTest() throws Exception {
String tableName = getUniqueNames(1)[0];
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
c.tableOperations().create(tableName);
insertData(c, tableName, 1L);
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/BadIteratorMincIT.java b/test/src/main/java/org/apache/accumulo/test/functional/BadIteratorMincIT.java
index 08b176e..c4d6e2c 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/BadIteratorMincIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/BadIteratorMincIT.java
@@ -23,6 +23,7 @@ import static org.junit.Assert.assertEquals;
import java.util.EnumSet;
import java.util.concurrent.TimeUnit;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchWriter;
import org.apache.accumulo.core.client.IteratorSetting;
@@ -46,7 +47,7 @@ public class BadIteratorMincIT extends AccumuloClusterHarness {
@Test
public void test() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(1)[0];
c.tableOperations().create(tableName);
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/BadLocalityGroupMincIT.java b/test/src/main/java/org/apache/accumulo/test/functional/BadLocalityGroupMincIT.java
index e47fd66..18c884c 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/BadLocalityGroupMincIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/BadLocalityGroupMincIT.java
@@ -21,6 +21,7 @@ import static org.junit.Assert.assertEquals;
import java.util.Map.Entry;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchWriter;
import org.apache.accumulo.core.client.Scanner;
@@ -44,7 +45,7 @@ public class BadLocalityGroupMincIT extends AccumuloClusterHarness {
@Test
public void test() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(1)[0];
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/BalanceInPresenceOfOfflineTableIT.java b/test/src/main/java/org/apache/accumulo/test/functional/BalanceInPresenceOfOfflineTableIT.java
index a86962f..aae5559 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/BalanceInPresenceOfOfflineTableIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/BalanceInPresenceOfOfflineTableIT.java
@@ -25,6 +25,7 @@ import java.util.SortedSet;
import java.util.TreeSet;
import java.util.concurrent.TimeUnit;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.AccumuloException;
import org.apache.accumulo.core.client.AccumuloSecurityException;
@@ -90,7 +91,7 @@ public class BalanceInPresenceOfOfflineTableIT extends AccumuloClusterHarness {
@Before
public void setupTables() throws AccumuloException, AccumuloSecurityException,
TableExistsException, TableNotFoundException {
- accumuloClient = createAccumuloClient();
+ accumuloClient = Accumulo.newClient().from(getClientProps()).build();
// Need at least two tservers
Assume.assumeTrue("Not enough tservers to run test",
accumuloClient.instanceOperations().getTabletServers().size() >= 2);
@@ -129,7 +130,7 @@ public class BalanceInPresenceOfOfflineTableIT extends AccumuloClusterHarness {
log.debug("starting test ingestion");
- VerifyParams params = new VerifyParams(getClientProperties(), TEST_TABLE, 200_000);
+ VerifyParams params = new VerifyParams(getClientProps(), TEST_TABLE, 200_000);
TestIngest.ingest(accumuloClient, params);
accumuloClient.tableOperations().flush(TEST_TABLE, null, null, true);
VerifyIngest.verifyIngest(accumuloClient, params);
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/BatchScanSplitIT.java b/test/src/main/java/org/apache/accumulo/test/functional/BatchScanSplitIT.java
index b7952a1..7819cbd 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/BatchScanSplitIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/BatchScanSplitIT.java
@@ -27,6 +27,7 @@ import java.util.Map.Entry;
import java.util.Random;
import java.util.concurrent.TimeUnit;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchScanner;
import org.apache.accumulo.core.client.BatchWriter;
@@ -58,7 +59,7 @@ public class BatchScanSplitIT extends AccumuloClusterHarness {
@Test
public void test() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(1)[0];
c.tableOperations().create(tableName);
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/BatchWriterFlushIT.java b/test/src/main/java/org/apache/accumulo/test/functional/BatchWriterFlushIT.java
index bd3a3d3..cc32eff 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/BatchWriterFlushIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/BatchWriterFlushIT.java
@@ -35,6 +35,7 @@ import java.util.Set;
import java.util.TreeSet;
import java.util.concurrent.TimeUnit;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchWriter;
import org.apache.accumulo.core.client.BatchWriterConfig;
@@ -64,7 +65,7 @@ public class BatchWriterFlushIT extends AccumuloClusterHarness {
@Test
public void run() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
String[] tableNames = getUniqueNames(2);
String bwft = tableNames[0];
c.tableOperations().create(bwft);
@@ -179,7 +180,7 @@ public class BatchWriterFlushIT extends AccumuloClusterHarness {
@Test
public void runMultiThreadedBinningTest() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
String[] tableNames = getUniqueNames(1);
String tableName = tableNames[0];
c.tableOperations().create(tableName);
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/BigRootTabletIT.java b/test/src/main/java/org/apache/accumulo/test/functional/BigRootTabletIT.java
index 3a26d1f..3f9c7af 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/BigRootTabletIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/BigRootTabletIT.java
@@ -20,6 +20,7 @@ import static org.junit.Assert.assertTrue;
import java.util.Map;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.conf.Property;
import org.apache.accumulo.core.metadata.MetadataTable;
@@ -51,7 +52,7 @@ public class BigRootTabletIT extends AccumuloClusterHarness {
@Test
public void test() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
c.tableOperations().addSplits(MetadataTable.NAME,
FunctionalTestUtils.splits("0 1 2 3 4 5 6 7 8 9 a".split(" ")));
String[] names = getUniqueNames(10);
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/BinaryIT.java b/test/src/main/java/org/apache/accumulo/test/functional/BinaryIT.java
index bc3b2ab..8a7605d 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/BinaryIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/BinaryIT.java
@@ -19,6 +19,7 @@ package org.apache.accumulo.test.functional;
import java.util.SortedSet;
import java.util.TreeSet;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.harness.AccumuloClusterHarness;
import org.apache.accumulo.test.TestBinaryRows;
@@ -34,7 +35,7 @@ public class BinaryIT extends AccumuloClusterHarness {
@Test
public void test() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(1)[0];
c.tableOperations().create(tableName);
runTest(c, tableName);
@@ -44,7 +45,7 @@ public class BinaryIT extends AccumuloClusterHarness {
@Test
public void testPreSplit() throws Exception {
String tableName = getUniqueNames(1)[0];
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
c.tableOperations().create(tableName);
SortedSet<Text> splits = new TreeSet<>();
splits.add(new Text("8"));
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/BinaryStressIT.java b/test/src/main/java/org/apache/accumulo/test/functional/BinaryStressIT.java
index d5d159c..813d652 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/BinaryStressIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/BinaryStressIT.java
@@ -23,6 +23,7 @@ import java.util.Map;
import java.util.Map.Entry;
import java.util.Set;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.Scanner;
import org.apache.accumulo.core.client.admin.InstanceOperations;
@@ -62,7 +63,7 @@ public class BinaryStressIT extends AccumuloClusterHarness {
if (getClusterType() == ClusterType.MINI) {
return;
}
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
InstanceOperations iops = client.instanceOperations();
Map<String,String> conf = iops.getSystemConfiguration();
majcDelay = conf.get(Property.TSERV_MAJC_DELAY.getKey());
@@ -79,7 +80,7 @@ public class BinaryStressIT extends AccumuloClusterHarness {
@After
public void resetConfig() throws Exception {
if (majcDelay != null) {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
InstanceOperations iops = client.instanceOperations();
iops.setProperty(Property.TSERV_MAJC_DELAY.getKey(), majcDelay);
iops.setProperty(Property.TSERV_MAXMEM.getKey(), maxMem);
@@ -91,7 +92,7 @@ public class BinaryStressIT extends AccumuloClusterHarness {
@Test
public void binaryStressTest() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(1)[0];
c.tableOperations().create(tableName);
c.tableOperations().setProperty(tableName, Property.TABLE_SPLIT_THRESHOLD.getKey(), "10K");
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/BloomFilterIT.java b/test/src/main/java/org/apache/accumulo/test/functional/BloomFilterIT.java
index 0605e59..e102770 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/BloomFilterIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/BloomFilterIT.java
@@ -25,6 +25,7 @@ import java.util.Map;
import java.util.Map.Entry;
import java.util.Random;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchScanner;
import org.apache.accumulo.core.client.BatchWriter;
@@ -69,7 +70,7 @@ public class BloomFilterIT extends AccumuloClusterHarness {
@Test
public void test() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
final String readAhead = c.instanceOperations().getSystemConfiguration()
.get(Property.TSERV_SCAN_EXECUTORS_DEFAULT_THREADS.getKey());
c.instanceOperations().setProperty(Property.TSERV_SCAN_EXECUTORS_DEFAULT_THREADS.getKey(),
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/BulkFailureIT.java b/test/src/main/java/org/apache/accumulo/test/functional/BulkFailureIT.java
index f0e9d64..5fcaca6 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/BulkFailureIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/BulkFailureIT.java
@@ -31,6 +31,7 @@ import java.util.SortedMap;
import java.util.TreeMap;
import org.apache.accumulo.core.Constants;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.AccumuloException;
import org.apache.accumulo.core.client.AccumuloSecurityException;
@@ -106,7 +107,7 @@ public class BulkFailureIT extends AccumuloClusterHarness {
protected void runTest(String table, long fateTxid, Loader loader) throws IOException,
AccumuloException, AccumuloSecurityException, TableExistsException, KeeperException,
InterruptedException, Exception, FileNotFoundException, TableNotFoundException {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
SortedMap<Key,Value> testData = createTestData();
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/BulkFileIT.java b/test/src/main/java/org/apache/accumulo/test/functional/BulkFileIT.java
index c10f268..fa96815 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/BulkFileIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/BulkFileIT.java
@@ -24,6 +24,7 @@ import java.util.Map.Entry;
import java.util.SortedSet;
import java.util.TreeSet;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.Scanner;
import org.apache.accumulo.core.conf.AccumuloConfiguration;
@@ -63,7 +64,7 @@ public class BulkFileIT extends AccumuloClusterHarness {
@SuppressWarnings("deprecation")
@Test
public void testBulkFile() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(1)[0];
c.tableOperations().create(tableName);
SortedSet<Text> splits = new TreeSet<>();
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/BulkIT.java b/test/src/main/java/org/apache/accumulo/test/functional/BulkIT.java
index 1828c1a..71fb322 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/BulkIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/BulkIT.java
@@ -18,6 +18,7 @@ package org.apache.accumulo.test.functional;
import java.io.IOException;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.AccumuloException;
import org.apache.accumulo.core.client.AccumuloSecurityException;
@@ -44,7 +45,7 @@ public class BulkIT extends AccumuloClusterHarness {
@Test
public void test() throws Exception {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
runTest(client, getClientInfo(), getCluster().getFileSystem(),
getCluster().getTemporaryPath(), getUniqueNames(1)[0], this.getClass().getName(),
testName.getMethodName(), false);
@@ -53,7 +54,7 @@ public class BulkIT extends AccumuloClusterHarness {
@Test
public void testOld() throws Exception {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
runTest(client, getClientInfo(), getCluster().getFileSystem(),
getCluster().getTemporaryPath(), getUniqueNames(1)[0], this.getClass().getName(),
testName.getMethodName(), true);
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/BulkLoadIT.java b/test/src/main/java/org/apache/accumulo/test/functional/BulkLoadIT.java
index 04887e2..2c4bfd4 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/BulkLoadIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/BulkLoadIT.java
@@ -39,6 +39,7 @@ import java.util.SortedSet;
import java.util.TreeSet;
import java.util.stream.Collectors;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.AccumuloException;
import org.apache.accumulo.core.client.Scanner;
@@ -104,7 +105,7 @@ public class BulkLoadIT extends AccumuloClusterHarness {
@Before
public void setupBulkTest() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
tableName = getUniqueNames(1)[0];
c.tableOperations().create(tableName);
aconf = getCluster().getServerContext().getConfiguration();
@@ -142,14 +143,14 @@ public class BulkLoadIT extends AccumuloClusterHarness {
@Test
public void testSingleTabletSingleFile() throws Exception {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
testSingleTabletSingleFile(client, false, false);
}
}
@Test
public void testSetTime() throws Exception {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
tableName = "testSetTime_table1";
NewTableConfiguration newTableConf = new NewTableConfiguration();
// set logical time type so we can set time on bulk import
@@ -161,7 +162,7 @@ public class BulkLoadIT extends AccumuloClusterHarness {
@Test
public void testSingleTabletSingleFileOffline() throws Exception {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
testSingleTabletSingleFile(client, true, false);
}
}
@@ -186,21 +187,21 @@ public class BulkLoadIT extends AccumuloClusterHarness {
@Test
public void testSingleTabletSingleFileNoSplits() throws Exception {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
testSingleTabletSingleFileNoSplits(client, false);
}
}
@Test
public void testSingleTabletSingleFileNoSplitsOffline() throws Exception {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
testSingleTabletSingleFileNoSplits(client, true);
}
}
@Test
public void testBadPermissions() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
addSplits(c, tableName, "0333");
String dir = getDir("/testBadPermissions-");
@@ -235,7 +236,7 @@ public class BulkLoadIT extends AccumuloClusterHarness {
}
private void testBulkFile(boolean offline, boolean usePlan) throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
addSplits(c, tableName, "0333 0666 0999 1333 1666");
if (offline)
@@ -312,7 +313,7 @@ public class BulkLoadIT extends AccumuloClusterHarness {
@Test
public void testBadLoadPlans() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
addSplits(c, tableName, "0333 0666 0999 1333 1666");
String dir = getDir("/testBulkFile-");
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/BulkSplitOptimizationIT.java b/test/src/main/java/org/apache/accumulo/test/functional/BulkSplitOptimizationIT.java
index defb91d..e785bbe 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/BulkSplitOptimizationIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/BulkSplitOptimizationIT.java
@@ -20,6 +20,7 @@ import static org.apache.accumulo.fate.util.UtilWaitThread.sleepUninterruptibly;
import java.util.concurrent.TimeUnit;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.conf.Property;
import org.apache.accumulo.harness.AccumuloClusterHarness;
@@ -55,7 +56,7 @@ public class BulkSplitOptimizationIT extends AccumuloClusterHarness {
@Before
public void alterConfig() throws Exception {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
majcDelay = client.instanceOperations().getSystemConfiguration()
.get(Property.TSERV_MAJC_DELAY.getKey());
if (!"1s".equals(majcDelay)) {
@@ -69,7 +70,7 @@ public class BulkSplitOptimizationIT extends AccumuloClusterHarness {
@After
public void resetConfig() throws Exception {
if (majcDelay != null) {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
client.instanceOperations().setProperty(Property.TSERV_MAJC_DELAY.getKey(), majcDelay);
getClusterControl().stopAllServers(ServerType.TABLET_SERVER);
getClusterControl().startAllServers(ServerType.TABLET_SERVER);
@@ -82,7 +83,7 @@ public class BulkSplitOptimizationIT extends AccumuloClusterHarness {
@Test
public void testBulkSplitOptimization() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ 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(), "1000");
@@ -109,7 +110,7 @@ public class BulkSplitOptimizationIT extends AccumuloClusterHarness {
}
FunctionalTestUtils.checkSplits(c, tableName, 50, 100);
- VerifyParams params = new VerifyParams(getClientProperties(), tableName, ROWS);
+ VerifyParams params = new VerifyParams(getClientProps(), tableName, ROWS);
params.timestamp = 1;
params.dataSize = 50;
params.random = 56;
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/ChaoticBalancerIT.java b/test/src/main/java/org/apache/accumulo/test/functional/ChaoticBalancerIT.java
index 2fbb038..deb398c 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/ChaoticBalancerIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/ChaoticBalancerIT.java
@@ -20,6 +20,7 @@ import java.util.Map;
import java.util.stream.Collectors;
import java.util.stream.Stream;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.admin.NewTableConfiguration;
import org.apache.accumulo.core.conf.Property;
@@ -52,7 +53,7 @@ public class ChaoticBalancerIT extends AccumuloClusterHarness {
@Test
public void test() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
String[] names = getUniqueNames(1);
String tableName = names[0];
NewTableConfiguration ntc = new NewTableConfiguration();
@@ -62,7 +63,7 @@ public class ChaoticBalancerIT extends AccumuloClusterHarness {
.collect(Collectors.toMap(Pair::getFirst, Pair::getSecond)));
c.tableOperations().create(tableName, ntc);
- VerifyParams params = new VerifyParams(getClientProperties(), tableName, 20_000);
+ VerifyParams params = new VerifyParams(getClientProps(), tableName, 20_000);
TestIngest.ingest(c, params);
c.tableOperations().flush(tableName, null, null, true);
VerifyIngest.verifyIngest(c, params);
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/ClassLoaderIT.java b/test/src/main/java/org/apache/accumulo/test/functional/ClassLoaderIT.java
index c10a7cf..d768592 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/ClassLoaderIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/ClassLoaderIT.java
@@ -29,6 +29,7 @@ import java.util.Iterator;
import java.util.Map.Entry;
import java.util.concurrent.TimeUnit;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchWriter;
import org.apache.accumulo.core.client.IteratorSetting;
@@ -87,7 +88,7 @@ public class ClassLoaderIT extends AccumuloClusterHarness {
@Test
public void test() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(1)[0];
c.tableOperations().create(tableName);
try (BatchWriter bw = c.createBatchWriter(tableName)) {
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/CloneTestIT.java b/test/src/main/java/org/apache/accumulo/test/functional/CloneTestIT.java
index 7b8fbbe..0e414bd 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/CloneTestIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/CloneTestIT.java
@@ -33,6 +33,7 @@ import java.util.Set;
import java.util.TreeSet;
import org.apache.accumulo.cluster.AccumuloCluster;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchWriter;
import org.apache.accumulo.core.client.Scanner;
@@ -69,7 +70,7 @@ public class CloneTestIT extends AccumuloClusterHarness {
String table1 = tableNames[0];
String table2 = tableNames[1];
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
c.tableOperations().create(table1);
@@ -205,7 +206,7 @@ public class CloneTestIT extends AccumuloClusterHarness {
String table2 = tableNames[1];
String table3 = tableNames[2];
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
AccumuloCluster cluster = getCluster();
Assume.assumeTrue(cluster instanceof MiniAccumuloClusterImpl);
MiniAccumuloClusterImpl mac = (MiniAccumuloClusterImpl) cluster;
@@ -252,7 +253,7 @@ public class CloneTestIT extends AccumuloClusterHarness {
@Test
public void testCloneWithSplits() throws Exception {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
List<Mutation> mutations = new ArrayList<>();
TreeSet<Text> splits = new TreeSet<>();
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/CombinerIT.java b/test/src/main/java/org/apache/accumulo/test/functional/CombinerIT.java
index 82eef85..7f621ba 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/CombinerIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/CombinerIT.java
@@ -24,6 +24,7 @@ import java.util.Collections;
import java.util.Iterator;
import java.util.Map.Entry;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchWriter;
import org.apache.accumulo.core.client.IteratorSetting;
@@ -56,7 +57,7 @@ public class CombinerIT extends AccumuloClusterHarness {
@Test
public void aggregationTest() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(1)[0];
c.tableOperations().create(tableName);
IteratorSetting setting = new IteratorSetting(10, SummingCombiner.class);
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/CompactionIT.java b/test/src/main/java/org/apache/accumulo/test/functional/CompactionIT.java
index 33ca650..0a06a2c 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/CompactionIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/CompactionIT.java
@@ -25,6 +25,7 @@ import java.util.concurrent.Executors;
import java.util.concurrent.TimeUnit;
import java.util.concurrent.atomic.AtomicBoolean;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.Scanner;
import org.apache.accumulo.core.client.admin.InstanceOperations;
@@ -73,7 +74,7 @@ public class CompactionIT extends AccumuloClusterHarness {
@Before
public void alterConfig() throws Exception {
if (getClusterType() == ClusterType.STANDALONE) {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
InstanceOperations iops = client.instanceOperations();
Map<String,String> config = iops.getSystemConfiguration();
majcThreadMaxOpen = config.get(Property.TSERV_MAJC_THREAD_MAXOPEN.getKey());
@@ -94,7 +95,7 @@ public class CompactionIT extends AccumuloClusterHarness {
public void resetConfig() throws Exception {
// We set the values..
if (majcThreadMaxOpen != null) {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
InstanceOperations iops = client.instanceOperations();
iops.setProperty(Property.TSERV_MAJC_THREAD_MAXOPEN.getKey(), majcThreadMaxOpen);
@@ -109,7 +110,7 @@ public class CompactionIT extends AccumuloClusterHarness {
@Test
public void test() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ 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(), "1.0");
@@ -130,7 +131,7 @@ public class CompactionIT extends AccumuloClusterHarness {
final int finalI = i;
Runnable r = () -> {
try {
- VerifyParams params = new VerifyParams(getClientProperties(), tableName, span);
+ VerifyParams params = new VerifyParams(getClientProps(), tableName, span);
params.startRow = finalI;
params.random = 56;
params.dataSize = 50;
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/ConcurrencyIT.java b/test/src/main/java/org/apache/accumulo/test/functional/ConcurrencyIT.java
index 43e2639..4a3d5b2 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/ConcurrencyIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/ConcurrencyIT.java
@@ -23,6 +23,7 @@ import java.util.EnumSet;
import java.util.Map;
import java.util.concurrent.TimeUnit;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchWriter;
import org.apache.accumulo.core.client.IteratorSetting;
@@ -94,7 +95,7 @@ public class ConcurrencyIT extends AccumuloClusterHarness {
// @formatter:on
@Test
public void run() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
runTest(c, getUniqueNames(1)[0]);
}
}
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/ConcurrentDeleteTableIT.java b/test/src/main/java/org/apache/accumulo/test/functional/ConcurrentDeleteTableIT.java
index 03a3ec3..d7b4ac1 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/ConcurrentDeleteTableIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/ConcurrentDeleteTableIT.java
@@ -33,6 +33,7 @@ import java.util.concurrent.ExecutorService;
import java.util.concurrent.Executors;
import java.util.concurrent.Future;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.AccumuloException;
import org.apache.accumulo.core.client.AccumuloSecurityException;
@@ -52,7 +53,7 @@ public class ConcurrentDeleteTableIT extends AccumuloClusterHarness {
@Test
public void testConcurrentDeleteTablesOps() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
String[] tables = getUniqueNames(2);
TreeSet<Text> splits = createSplits();
@@ -150,7 +151,7 @@ public class ConcurrentDeleteTableIT extends AccumuloClusterHarness {
@Test
public void testConcurrentFateOpsWithDelete() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
String[] tables = getUniqueNames(2);
TreeSet<Text> splits = createSplits();
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/ConstraintIT.java b/test/src/main/java/org/apache/accumulo/test/functional/ConstraintIT.java
index c308cef..56663f8 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/ConstraintIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/ConstraintIT.java
@@ -26,6 +26,7 @@ import java.util.Map;
import java.util.Map.Entry;
import java.util.concurrent.TimeUnit;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchWriter;
import org.apache.accumulo.core.client.MutationsRejectedException;
@@ -56,7 +57,7 @@ public class ConstraintIT extends AccumuloClusterHarness {
@Test
public void run() throws Exception {
String[] tableNames = getUniqueNames(3);
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
for (String table : tableNames) {
c.tableOperations().create(table);
c.tableOperations().addConstraint(table, NumericValueConstraint.class.getName());
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/CreateAndUseIT.java b/test/src/main/java/org/apache/accumulo/test/functional/CreateAndUseIT.java
index 3d189a4..a536394 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/CreateAndUseIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/CreateAndUseIT.java
@@ -25,6 +25,7 @@ import java.util.Map.Entry;
import java.util.SortedSet;
import java.util.TreeSet;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchScanner;
import org.apache.accumulo.core.client.BatchWriter;
@@ -62,7 +63,7 @@ public class CreateAndUseIT extends AccumuloClusterHarness {
@Test
public void verifyDataIsPresent() throws Exception {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
Text cf = new Text("cf1");
Text cq = new Text("cq1");
@@ -95,7 +96,7 @@ public class CreateAndUseIT extends AccumuloClusterHarness {
@Test
public void createTableAndScan() throws Exception {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
String table2 = getUniqueNames(1)[0];
client.tableOperations().create(table2);
client.tableOperations().addSplits(table2, splits);
@@ -115,7 +116,7 @@ public class CreateAndUseIT extends AccumuloClusterHarness {
@Test
public void createTableAndBatchScan() throws Exception {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
ArrayList<Range> ranges = new ArrayList<>();
for (int i = 1; i < 257; i++) {
ranges.add(new Range(new Text(String.format("%08x", (i << 8) - 16))));
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/CreateInitialSplitsIT.java b/test/src/main/java/org/apache/accumulo/test/functional/CreateInitialSplitsIT.java
index 3522151..012e10d 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/CreateInitialSplitsIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/CreateInitialSplitsIT.java
@@ -27,6 +27,7 @@ import java.util.SortedSet;
import java.util.TreeSet;
import java.util.UUID;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.AccumuloException;
import org.apache.accumulo.core.client.AccumuloSecurityException;
@@ -67,7 +68,7 @@ public class CreateInitialSplitsIT extends AccumuloClusterHarness {
@Before
public void setupInitialSplits() {
- client = createAccumuloClient();
+ client = Accumulo.newClient().from(getClientProps()).build();
}
@After
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/CreateManyScannersIT.java b/test/src/main/java/org/apache/accumulo/test/functional/CreateManyScannersIT.java
index f38c6d3..7388284 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/CreateManyScannersIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/CreateManyScannersIT.java
@@ -16,6 +16,7 @@
*/
package org.apache.accumulo.test.functional;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.security.Authorizations;
import org.apache.accumulo.harness.AccumuloClusterHarness;
@@ -30,7 +31,7 @@ public class CreateManyScannersIT extends AccumuloClusterHarness {
@Test
public void run() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(1)[0];
c.tableOperations().create(tableName);
for (int i = 0; i < 100000; i++) {
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/CredentialsIT.java b/test/src/main/java/org/apache/accumulo/test/functional/CredentialsIT.java
index c6f499d..7f3f9d5 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/CredentialsIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/CredentialsIT.java
@@ -57,7 +57,7 @@ public class CredentialsIT extends AccumuloClusterHarness {
@Before
public void createLocalUser() throws AccumuloException, AccumuloSecurityException {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
ClusterUser user = getUser(0);
username = user.getPrincipal();
saslEnabled = saslEnabled();
@@ -81,7 +81,7 @@ public class CredentialsIT extends AccumuloClusterHarness {
UserGroupInformation.loginUserFromKeytab(root.getPrincipal(),
root.getKeytab().getAbsolutePath());
}
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
client.securityOperations().dropLocalUser(username);
}
}
@@ -102,7 +102,7 @@ public class CredentialsIT extends AccumuloClusterHarness {
@Test
public void testDestroyTokenBeforeRPC() throws Exception {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
AuthenticationToken token = getUser(0).getToken();
try (
AccumuloClient userAccumuloClient = Accumulo.newClient().from(client.properties())
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/DeleteEverythingIT.java b/test/src/main/java/org/apache/accumulo/test/functional/DeleteEverythingIT.java
index 6679e8c..52ec087 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/DeleteEverythingIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/DeleteEverythingIT.java
@@ -23,6 +23,7 @@ import static org.junit.Assert.assertEquals;
import java.util.Map;
import java.util.concurrent.TimeUnit;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchWriter;
import org.apache.accumulo.core.client.Scanner;
@@ -61,7 +62,7 @@ public class DeleteEverythingIT extends AccumuloClusterHarness {
@Before
public void updateMajcDelay() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
majcDelay = c.instanceOperations().getSystemConfiguration()
.get(Property.TSERV_MAJC_DELAY.getKey());
c.instanceOperations().setProperty(Property.TSERV_MAJC_DELAY.getKey(), "1s");
@@ -74,14 +75,14 @@ public class DeleteEverythingIT extends AccumuloClusterHarness {
@After
public void resetMajcDelay() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
c.instanceOperations().setProperty(Property.TSERV_MAJC_DELAY.getKey(), majcDelay);
}
}
@Test
public void run() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(1)[0];
c.tableOperations().create(tableName);
BatchWriter bw = c.createBatchWriter(tableName);
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/DeleteFailIT.java b/test/src/main/java/org/apache/accumulo/test/functional/DeleteFailIT.java
index bfd3eca..cbf6321 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/DeleteFailIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/DeleteFailIT.java
@@ -20,6 +20,7 @@ import static org.junit.Assert.fail;
import java.util.Collections;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchWriter;
import org.apache.accumulo.core.client.Scanner;
@@ -35,7 +36,7 @@ public class DeleteFailIT extends AccumuloClusterHarness {
@Test
public void testFail() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(1)[0];
NewTableConfiguration ntc = new NewTableConfiguration();
ntc.setProperties(
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/DeleteIT.java b/test/src/main/java/org/apache/accumulo/test/functional/DeleteIT.java
index 0f5aa22..a1f9724 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/DeleteIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/DeleteIT.java
@@ -19,6 +19,7 @@ package org.apache.accumulo.test.functional;
import static org.junit.Assert.assertEquals;
import org.apache.accumulo.cluster.AccumuloCluster;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.harness.AccumuloClusterHarness;
import org.apache.accumulo.test.TestIngest;
@@ -36,7 +37,7 @@ public class DeleteIT extends AccumuloClusterHarness {
@Test
public void test() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(1)[0];
c.tableOperations().create(tableName);
deleteTest(c, getCluster(), tableName);
@@ -45,7 +46,7 @@ public class DeleteIT extends AccumuloClusterHarness {
public static void deleteTest(AccumuloClient c, AccumuloCluster cluster, String tableName)
throws Exception {
- VerifyParams params = new VerifyParams(getClientProperties(), tableName, 1000);
+ VerifyParams params = new VerifyParams(getClientProps(), tableName, 1000);
params.cols = 1;
params.random = 56;
TestIngest.ingest(c, params);
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/DeleteRowsIT.java b/test/src/main/java/org/apache/accumulo/test/functional/DeleteRowsIT.java
index 8e6689b..4e6018c 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/DeleteRowsIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/DeleteRowsIT.java
@@ -27,6 +27,7 @@ import java.util.Map.Entry;
import java.util.SortedSet;
import java.util.TreeSet;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchWriter;
import org.apache.accumulo.core.client.Scanner;
@@ -69,7 +70,7 @@ public class DeleteRowsIT extends AccumuloClusterHarness {
@Test(timeout = 5 * 60 * 1000)
public void testDeleteAllRows() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
String[] tableNames = this.getUniqueNames(20);
for (String tableName : tableNames) {
c.tableOperations().create(tableName);
@@ -83,7 +84,7 @@ public class DeleteRowsIT extends AccumuloClusterHarness {
@Test
public void testManyRows() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
// Delete ranges of rows, and verify the tablets are removed.
int i = 0;
// Eliminate whole tablets
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/DeleteRowsSplitIT.java b/test/src/main/java/org/apache/accumulo/test/functional/DeleteRowsSplitIT.java
index 24a8bc9..5c3c897 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/DeleteRowsSplitIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/DeleteRowsSplitIT.java
@@ -28,6 +28,7 @@ import java.util.SortedSet;
import java.util.TreeSet;
import java.util.concurrent.TimeUnit;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchWriter;
import org.apache.accumulo.core.client.Scanner;
@@ -66,7 +67,7 @@ public class DeleteRowsSplitIT extends AccumuloClusterHarness {
// Delete ranges of rows, and verify the are removed
// Do this while adding many splits
final String tableName = getUniqueNames(1)[0];
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
// Eliminate whole tablets
for (int test = 0; test < 10; test++) {
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/DeleteTableDuringSplitIT.java b/test/src/main/java/org/apache/accumulo/test/functional/DeleteTableDuringSplitIT.java
index f1e889a..2cc58ee 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/DeleteTableDuringSplitIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/DeleteTableDuringSplitIT.java
@@ -26,6 +26,7 @@ import java.util.SortedSet;
import java.util.TreeSet;
import java.util.concurrent.Future;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.TableNotFoundException;
import org.apache.accumulo.core.util.SimpleThreadPool;
@@ -49,7 +50,7 @@ public class DeleteTableDuringSplitIT extends AccumuloClusterHarness {
@Test
public void test() throws Exception {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
// 96 invocations, 8 at a time
int batches = 12, batchSize = 8;
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/DeletedTablesDontFlushIT.java b/test/src/main/java/org/apache/accumulo/test/functional/DeletedTablesDontFlushIT.java
index f7fc0ec..7d3d1a9 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/DeletedTablesDontFlushIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/DeletedTablesDontFlushIT.java
@@ -18,6 +18,7 @@ package org.apache.accumulo.test.functional;
import java.util.EnumSet;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchWriter;
import org.apache.accumulo.core.client.IteratorSetting;
@@ -50,7 +51,7 @@ public class DeletedTablesDontFlushIT extends SharedMiniClusterBase {
@Test
public void test() throws Exception {
- try (AccumuloClient c = createClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(1)[0];
c.tableOperations().create(tableName);
IteratorSetting setting = new IteratorSetting(100, SlowIterator.class);
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/DynamicThreadPoolsIT.java b/test/src/main/java/org/apache/accumulo/test/functional/DynamicThreadPoolsIT.java
index 3de219e..5707d02 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/DynamicThreadPoolsIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/DynamicThreadPoolsIT.java
@@ -22,6 +22,7 @@ import static org.junit.Assert.fail;
import java.util.Map;
import java.util.concurrent.TimeUnit;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.clientImpl.ClientContext;
import org.apache.accumulo.core.clientImpl.Credentials;
@@ -62,7 +63,7 @@ public class DynamicThreadPoolsIT extends AccumuloClusterHarness {
@Before
public void updateMajcDelay() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
majcDelay = c.instanceOperations().getSystemConfiguration()
.get(Property.TSERV_MAJC_DELAY.getKey());
c.instanceOperations().setProperty(Property.TSERV_MAJC_DELAY.getKey(), "100ms");
@@ -74,7 +75,7 @@ public class DynamicThreadPoolsIT extends AccumuloClusterHarness {
@After
public void resetMajcDelay() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
c.instanceOperations().setProperty(Property.TSERV_MAJC_DELAY.getKey(), majcDelay);
}
}
@@ -83,9 +84,9 @@ public class DynamicThreadPoolsIT extends AccumuloClusterHarness {
public void test() throws Exception {
final String[] tables = getUniqueNames(15);
String firstTable = tables[0];
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
c.instanceOperations().setProperty(Property.TSERV_MAJC_MAXCONCURRENT.getKey(), "5");
- IngestParams params = new IngestParams(getClientProperties(), firstTable, 500_000);
+ IngestParams params = new IngestParams(getClientProps(), firstTable, 500_000);
params.createTable = true;
TestIngest.ingest(c, params);
c.tableOperations().flush(firstTable, null, null, true);
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/FateConcurrencyIT.java b/test/src/main/java/org/apache/accumulo/test/functional/FateConcurrencyIT.java
index b670683..df8399f 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/FateConcurrencyIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/FateConcurrencyIT.java
@@ -30,6 +30,7 @@ import java.util.concurrent.Future;
import java.util.concurrent.TimeUnit;
import org.apache.accumulo.core.Constants;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.AccumuloException;
import org.apache.accumulo.core.client.AccumuloSecurityException;
@@ -92,7 +93,7 @@ public class FateConcurrencyIT extends AccumuloClusterHarness {
@Before
public void setup() {
- accumuloClient = createAccumuloClient();
+ accumuloClient = Accumulo.newClient().from(getClientProps()).build();
context = (ClientContext) accumuloClient;
tableName = getUniqueNames(1)[0];
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/FateStarvationIT.java b/test/src/main/java/org/apache/accumulo/test/functional/FateStarvationIT.java
index 5745ad0..e91f776 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/FateStarvationIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/FateStarvationIT.java
@@ -21,6 +21,7 @@ import java.util.ArrayList;
import java.util.List;
import java.util.Random;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.clientImpl.ClientContext;
import org.apache.accumulo.harness.AccumuloClusterHarness;
@@ -42,12 +43,12 @@ public class FateStarvationIT extends AccumuloClusterHarness {
@Test
public void run() throws Exception {
String tableName = getUniqueNames(1)[0];
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
c.tableOperations().create(tableName);
c.tableOperations().addSplits(tableName, TestIngest.getSplitPoints(0, 100000, 50));
- IngestParams params = new IngestParams(getClientProperties(), tableName, 100_000);
+ IngestParams params = new IngestParams(getClientProps(), tableName, 100_000);
params.random = 89;
params.timestamp = 7;
params.dataSize = 50;
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/LargeRowIT.java b/test/src/main/java/org/apache/accumulo/test/functional/LargeRowIT.java
index 42521c9..5ccba4e 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/LargeRowIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/LargeRowIT.java
@@ -26,6 +26,7 @@ import java.util.Random;
import java.util.TreeSet;
import java.util.concurrent.TimeUnit;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchWriter;
import org.apache.accumulo.core.client.Scanner;
@@ -93,7 +94,7 @@ public class LargeRowIT extends AccumuloClusterHarness {
REG_TABLE_NAME = names[0];
PRE_SPLIT_TABLE_NAME = names[1];
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
tservMajcDelay = c.instanceOperations().getSystemConfiguration()
.get(Property.TSERV_MAJC_DELAY.getKey());
c.instanceOperations().setProperty(Property.TSERV_MAJC_DELAY.getKey(), "10ms");
@@ -103,7 +104,7 @@ public class LargeRowIT extends AccumuloClusterHarness {
@After
public void resetMajcDelay() throws Exception {
if (tservMajcDelay != null) {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
client.instanceOperations().setProperty(Property.TSERV_MAJC_DELAY.getKey(), tservMajcDelay);
}
}
@@ -122,7 +123,7 @@ public class LargeRowIT extends AccumuloClusterHarness {
TestIngest.toPrintableChars(rowData);
splitPoints.add(new Text(rowData));
}
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
c.tableOperations().create(REG_TABLE_NAME);
c.tableOperations().create(PRE_SPLIT_TABLE_NAME);
c.tableOperations().setProperty(PRE_SPLIT_TABLE_NAME,
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/LogicalTimeIT.java b/test/src/main/java/org/apache/accumulo/test/functional/LogicalTimeIT.java
index 11ca793..67ee035 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/LogicalTimeIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/LogicalTimeIT.java
@@ -18,6 +18,7 @@ package org.apache.accumulo.test.functional;
import java.util.TreeSet;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchWriter;
import org.apache.accumulo.core.client.Scanner;
@@ -44,7 +45,7 @@ public class LogicalTimeIT extends AccumuloClusterHarness {
public void run() throws Exception {
int tc = 0;
String tableName = getUniqueNames(1)[0];
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
runMergeTest(c, tableName + tc++, new String[] {"m"}, new String[] {"a"}, null, null, "b",
2L);
runMergeTest(c, tableName + tc++, new String[] {"m"}, new String[] {"z"}, null, null, "b",
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/ManyWriteAheadLogsIT.java b/test/src/main/java/org/apache/accumulo/test/functional/ManyWriteAheadLogsIT.java
index e9c8fb6..b64199c 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/ManyWriteAheadLogsIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/ManyWriteAheadLogsIT.java
@@ -29,6 +29,7 @@ import java.util.Set;
import java.util.SortedSet;
import java.util.TreeSet;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchWriter;
import org.apache.accumulo.core.conf.Property;
@@ -84,7 +85,7 @@ public class ManyWriteAheadLogsIT extends AccumuloClusterHarness {
ServerContext ctx = getServerContext();
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
String[] tableNames = getUniqueNames(2);
String manyWALsTable = tableNames[0];
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/MasterAssignmentIT.java b/test/src/main/java/org/apache/accumulo/test/functional/MasterAssignmentIT.java
index 6a5d830..cd1af04 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/MasterAssignmentIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/MasterAssignmentIT.java
@@ -20,6 +20,7 @@ import static org.junit.Assert.assertEquals;
import static org.junit.Assert.assertNotNull;
import static org.junit.Assert.assertNull;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchWriter;
import org.apache.accumulo.core.clientImpl.ClientContext;
@@ -42,7 +43,7 @@ public class MasterAssignmentIT extends AccumuloClusterHarness {
@Test
public void test() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = super.getUniqueNames(1)[0];
c.tableOperations().create(tableName);
String tableId = c.tableOperations().tableIdMap().get(tableName);
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/MasterFailoverIT.java b/test/src/main/java/org/apache/accumulo/test/functional/MasterFailoverIT.java
index d92bcd1..61bbc05 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/MasterFailoverIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/MasterFailoverIT.java
@@ -19,6 +19,7 @@ package org.apache.accumulo.test.functional;
import java.util.Map;
import org.apache.accumulo.cluster.ClusterControl;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.conf.ClientProperty;
import org.apache.accumulo.core.conf.Property;
@@ -48,10 +49,10 @@ public class MasterFailoverIT extends AccumuloClusterHarness {
@Test
public void test() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
String[] names = getUniqueNames(2);
c.tableOperations().create(names[0]);
- VerifyParams params = new VerifyParams(getClientProperties(), names[0]);
+ VerifyParams params = new VerifyParams(getClientProps(), names[0]);
TestIngest.ingest(c, params);
ClusterControl control = cluster.getClusterControl();
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/MaxOpenIT.java b/test/src/main/java/org/apache/accumulo/test/functional/MaxOpenIT.java
index 5bedf8d..29f6200 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/MaxOpenIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/MaxOpenIT.java
@@ -22,6 +22,7 @@ import java.util.Map;
import java.util.Map.Entry;
import java.util.Random;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchScanner;
import org.apache.accumulo.core.client.admin.InstanceOperations;
@@ -65,7 +66,7 @@ public class MaxOpenIT extends AccumuloClusterHarness {
@Before
public void alterConfig() throws Exception {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
InstanceOperations iops = client.instanceOperations();
Map<String,String> sysConfig = iops.getSystemConfiguration();
scanMaxOpenFiles = sysConfig.get(Property.TSERV_SCAN_MAX_OPENFILES.getKey());
@@ -76,7 +77,7 @@ public class MaxOpenIT extends AccumuloClusterHarness {
@After
public void restoreConfig() throws Exception {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
InstanceOperations iops = client.instanceOperations();
if (scanMaxOpenFiles != null) {
iops.setProperty(Property.TSERV_SCAN_MAX_OPENFILES.getKey(), scanMaxOpenFiles);
@@ -95,7 +96,7 @@ public class MaxOpenIT extends AccumuloClusterHarness {
@Test
public void run() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ 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(), "10");
@@ -104,7 +105,7 @@ public class MaxOpenIT extends AccumuloClusterHarness {
// the following loop should create three tablets in each map file
for (int i = 0; i < 3; i++) {
- IngestParams params = new IngestParams(getClientProperties(), tableName, NUM_TO_INGEST);
+ IngestParams params = new IngestParams(getClientProps(), tableName, NUM_TO_INGEST);
params.timestamp = i;
params.dataSize = 50;
params.rows = NUM_TO_INGEST;
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/MergeIT.java b/test/src/main/java/org/apache/accumulo/test/functional/MergeIT.java
index 4178f65..7b32811 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/MergeIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/MergeIT.java
@@ -26,6 +26,7 @@ import java.util.Map.Entry;
import java.util.SortedSet;
import java.util.TreeSet;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchWriter;
import org.apache.accumulo.core.client.Scanner;
@@ -56,7 +57,7 @@ public class MergeIT extends AccumuloClusterHarness {
@Test
public void merge() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(1)[0];
c.tableOperations().create(tableName);
c.tableOperations().addSplits(tableName, splits("a b c d e f g h i j k".split(" ")));
@@ -75,7 +76,7 @@ public class MergeIT extends AccumuloClusterHarness {
@Test
public void mergeSize() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(1)[0];
c.tableOperations().create(tableName);
c.tableOperations().addSplits(tableName,
@@ -113,7 +114,7 @@ public class MergeIT extends AccumuloClusterHarness {
@Test
public void mergeTest() throws Exception {
int tc = 0;
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(1)[0];
runMergeTest(c, tableName + tc++, ns(), ns(), ns("l", "m", "n"), ns(null, "l"),
ns(null, "n"));
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/MetadataIT.java b/test/src/main/java/org/apache/accumulo/test/functional/MetadataIT.java
index 1070d17..0c37840 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/MetadataIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/MetadataIT.java
@@ -29,6 +29,7 @@ import java.util.SortedSet;
import java.util.TreeSet;
import java.util.concurrent.TimeUnit;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchScanner;
import org.apache.accumulo.core.client.Scanner;
@@ -61,7 +62,7 @@ public class MetadataIT extends AccumuloClusterHarness {
@Test
public void testFlushAndCompact() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
String[] tableNames = getUniqueNames(2);
// create a table to write some data to metadata table
@@ -100,7 +101,7 @@ public class MetadataIT extends AccumuloClusterHarness {
@Test
public void mergeMeta() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
String[] names = getUniqueNames(5);
SortedSet<Text> splits = new TreeSet<>();
for (String id : "1 2 3 4 5".split(" ")) {
@@ -123,7 +124,7 @@ public class MetadataIT extends AccumuloClusterHarness {
@Test
public void batchScanTest() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(1)[0];
c.tableOperations().create(tableName);
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/PermissionsIT.java b/test/src/main/java/org/apache/accumulo/test/functional/PermissionsIT.java
index eefff65..5f89c30 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/PermissionsIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/PermissionsIT.java
@@ -76,7 +76,7 @@ public class PermissionsIT extends AccumuloClusterHarness {
@Before
public void limitToMini() throws Exception {
Assume.assumeTrue(getClusterType() == ClusterType.MINI);
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
Set<String> users = c.securityOperations().listLocalUsers();
ClusterUser user = getUser(0);
if (users.contains(user.getPrincipal())) {
@@ -95,7 +95,7 @@ public class PermissionsIT extends AccumuloClusterHarness {
ClusterUser testUser = getUser(0), rootUser = getAdminUser();
// verify that the test is being run by root
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
verifyHasOnlyTheseSystemPermissions(c, c.whoami(), SystemPermission.values());
// create the test user
@@ -567,7 +567,7 @@ public class PermissionsIT extends AccumuloClusterHarness {
passwordToken = (PasswordToken) token;
}
loginAs(rootUser);
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
c.securityOperations().createLocalUser(principal, passwordToken);
loginAs(testUser);
try (AccumuloClient test_user_client = Accumulo.newClient().from(c.properties())
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/ReadWriteIT.java b/test/src/main/java/org/apache/accumulo/test/functional/ReadWriteIT.java
index 0c58c24..1c10bb1 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/ReadWriteIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/ReadWriteIT.java
@@ -133,7 +133,7 @@ public class ReadWriteIT extends AccumuloClusterHarness {
// Shutdown cleanly.
log.debug("Starting Monitor");
cluster.getClusterControl().startAllServers(ServerType.MONITOR);
- try (AccumuloClient accumuloClient = createAccumuloClient()) {
+ try (AccumuloClient accumuloClient = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(1)[0];
ingest(accumuloClient, getClientInfo(), ROWS, COLS, 50, 0, tableName);
verify(accumuloClient, getClientInfo(), ROWS, COLS, 50, 0, tableName);
@@ -272,7 +272,7 @@ public class ReadWriteIT extends AccumuloClusterHarness {
@Test
public void largeTest() throws Exception {
// write a few large values
- try (AccumuloClient accumuloClient = createAccumuloClient()) {
+ try (AccumuloClient accumuloClient = Accumulo.newClient().from(getClientProps()).build()) {
String table = getUniqueNames(1)[0];
ingest(accumuloClient, getClientInfo(), 2, 1, 500000, 0, table);
verify(accumuloClient, getClientInfo(), 2, 1, 500000, 0, table);
@@ -282,7 +282,7 @@ public class ReadWriteIT extends AccumuloClusterHarness {
@Test
public void interleaved() throws Exception {
// read and write concurrently
- try (AccumuloClient accumuloClient = createAccumuloClient()) {
+ try (AccumuloClient accumuloClient = Accumulo.newClient().from(getClientProps()).build()) {
final String tableName = getUniqueNames(1)[0];
interleaveTest(accumuloClient, tableName);
}
@@ -324,7 +324,7 @@ public class ReadWriteIT extends AccumuloClusterHarness {
@Test
public void localityGroupPerf() throws Exception {
// verify that locality groups can make look-ups faster
- try (AccumuloClient accumuloClient = createAccumuloClient()) {
+ try (AccumuloClient accumuloClient = Accumulo.newClient().from(getClientProps()).build()) {
final String tableName = getUniqueNames(1)[0];
accumuloClient.tableOperations().create(tableName);
accumuloClient.tableOperations().setProperty(tableName, "table.group.g1", "colf");
@@ -356,7 +356,7 @@ public class ReadWriteIT extends AccumuloClusterHarness {
*/
@Test
public void sunnyLG() throws Exception {
- try (AccumuloClient accumuloClient = createAccumuloClient()) {
+ try (AccumuloClient accumuloClient = Accumulo.newClient().from(getClientProps()).build()) {
final String tableName = getUniqueNames(1)[0];
accumuloClient.tableOperations().create(tableName);
Map<String,Set<Text>> groups = new TreeMap<>();
@@ -373,7 +373,7 @@ public class ReadWriteIT extends AccumuloClusterHarness {
@Test
public void sunnyLGUsingNewTableConfiguration() throws Exception {
// create a locality group, write to it and ensure it exists in the RFiles that result
- try (AccumuloClient accumuloClient = createAccumuloClient()) {
+ try (AccumuloClient accumuloClient = Accumulo.newClient().from(getClientProps()).build()) {
final String tableName = getUniqueNames(1)[0];
NewTableConfiguration ntc = new NewTableConfiguration();
Map<String,Set<Text>> groups = new HashMap<>();
@@ -430,7 +430,7 @@ public class ReadWriteIT extends AccumuloClusterHarness {
@Test
public void localityGroupChange() throws Exception {
// Make changes to locality groups and ensure nothing is lost
- try (AccumuloClient accumuloClient = createAccumuloClient()) {
+ try (AccumuloClient accumuloClient = Accumulo.newClient().from(getClientProps()).build()) {
String table = getUniqueNames(1)[0];
TableOperations to = accumuloClient.tableOperations();
to.create(table);
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/RenameIT.java b/test/src/main/java/org/apache/accumulo/test/functional/RenameIT.java
index 0697070..6c986af 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/RenameIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/RenameIT.java
@@ -16,6 +16,7 @@
*/
package org.apache.accumulo.test.functional;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.clientImpl.ClientContext;
import org.apache.accumulo.harness.AccumuloClusterHarness;
@@ -39,7 +40,7 @@ public class RenameIT extends AccumuloClusterHarness {
VerifyParams params = new VerifyParams(cluster.getClientProperties(), name1);
params.createTable = true;
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
TestIngest.ingest(c, params);
c.tableOperations().rename(name1, name2);
TestIngest.ingest(c, params);
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/RestartIT.java b/test/src/main/java/org/apache/accumulo/test/functional/RestartIT.java
index fc778e0..a4dd5f5 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/RestartIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/RestartIT.java
@@ -29,6 +29,7 @@ import java.util.concurrent.TimeUnit;
import org.apache.accumulo.cluster.ClusterControl;
import org.apache.accumulo.core.Constants;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.clientImpl.ClientInfo;
import org.apache.accumulo.core.conf.ClientProperty;
@@ -94,12 +95,12 @@ public class RestartIT extends AccumuloClusterHarness {
@Test
public void restartMaster() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
final String tableName = getUniqueNames(1)[0];
c.tableOperations().create(tableName);
final ClusterControl control = getCluster().getClusterControl();
- VerifyParams params = new VerifyParams(getClientProperties(), tableName, 10_000);
+ VerifyParams params = new VerifyParams(getClientProps(), tableName, 10_000);
Future<Integer> ret = svc.submit(() -> {
try {
@@ -120,10 +121,10 @@ public class RestartIT extends AccumuloClusterHarness {
@Test
public void restartMasterRecovery() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(1)[0];
c.tableOperations().create(tableName);
- VerifyParams params = new VerifyParams(getClientProperties(), tableName, 10_000);
+ VerifyParams params = new VerifyParams(getClientProps(), tableName, 10_000);
TestIngest.ingest(c, params);
ClusterControl control = getCluster().getClusterControl();
@@ -168,13 +169,13 @@ public class RestartIT extends AccumuloClusterHarness {
@Test
public void restartMasterSplit() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
final String tableName = getUniqueNames(1)[0];
final ClusterControl control = getCluster().getClusterControl();
c.tableOperations().create(tableName);
c.tableOperations().setProperty(tableName, Property.TABLE_SPLIT_THRESHOLD.getKey(), "5K");
- VerifyParams params = new VerifyParams(getClientProperties(), tableName, 10_000);
+ VerifyParams params = new VerifyParams(getClientProps(), tableName, 10_000);
Future<Integer> ret = svc.submit(() -> {
try {
@@ -209,10 +210,10 @@ public class RestartIT extends AccumuloClusterHarness {
@Test
public void killedTabletServer() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(1)[0];
c.tableOperations().create(tableName);
- VerifyParams params = new VerifyParams(getClientProperties(), tableName, 10_000);
+ VerifyParams params = new VerifyParams(getClientProps(), tableName, 10_000);
TestIngest.ingest(c, params);
VerifyIngest.verifyIngest(c, params);
cluster.getClusterControl().stopAllServers(ServerType.TABLET_SERVER);
@@ -223,7 +224,7 @@ public class RestartIT extends AccumuloClusterHarness {
@Test
public void killedTabletServer2() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
final String[] names = getUniqueNames(2);
final String tableName = names[0];
final ClusterControl control = getCluster().getClusterControl();
@@ -239,10 +240,10 @@ public class RestartIT extends AccumuloClusterHarness {
@Test
public void killedTabletServerDuringShutdown() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(1)[0];
c.tableOperations().create(tableName);
- IngestParams params = new IngestParams(getClientProperties(), tableName, 10_000);
+ IngestParams params = new IngestParams(getClientProps(), tableName, 10_000);
TestIngest.ingest(c, params);
try {
getCluster().getClusterControl().stopAllServers(ServerType.TABLET_SERVER);
@@ -255,9 +256,9 @@ public class RestartIT extends AccumuloClusterHarness {
@Test
public void shutdownDuringCompactingSplitting() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(1)[0];
- VerifyParams params = new VerifyParams(getClientProperties(), tableName, 10_000);
+ VerifyParams params = new VerifyParams(getClientProps(), tableName, 10_000);
c.tableOperations().create(tableName);
c.tableOperations().setProperty(tableName, Property.TABLE_SPLIT_THRESHOLD.getKey(), "10K");
String splitThreshold = null;
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/RestartStressIT.java b/test/src/main/java/org/apache/accumulo/test/functional/RestartStressIT.java
index 9335d8d..afe742e 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/RestartStressIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/RestartStressIT.java
@@ -26,6 +26,7 @@ import java.util.concurrent.Future;
import java.util.concurrent.TimeUnit;
import org.apache.accumulo.cluster.ClusterControl;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.conf.Property;
import org.apache.accumulo.harness.AccumuloClusterHarness;
@@ -86,13 +87,13 @@ public class RestartStressIT extends AccumuloClusterHarness {
@Test
public void test() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
final String tableName = getUniqueNames(1)[0];
c.tableOperations().create(tableName);
c.tableOperations().setProperty(tableName, Property.TABLE_SPLIT_THRESHOLD.getKey(), "500K");
final ClusterControl control = getCluster().getClusterControl();
- VerifyParams params = new VerifyParams(getClientProperties(), tableName, 10_000);
+ VerifyParams params = new VerifyParams(getClientProps(), tableName, 10_000);
Future<Integer> retCode = svc.submit(() -> {
try {
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/RowDeleteIT.java b/test/src/main/java/org/apache/accumulo/test/functional/RowDeleteIT.java
index bf5c65f..6d307fb 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/RowDeleteIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/RowDeleteIT.java
@@ -26,6 +26,7 @@ import java.util.HashMap;
import java.util.Map;
import java.util.Set;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchWriter;
import org.apache.accumulo.core.client.IteratorSetting;
@@ -58,7 +59,7 @@ public class RowDeleteIT extends AccumuloClusterHarness {
@Test
public void run() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(1)[0];
c.tableOperations().create(tableName);
Map<String,Set<Text>> groups = new HashMap<>();
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/ScanIdIT.java b/test/src/main/java/org/apache/accumulo/test/functional/ScanIdIT.java
index 4219cd4..953bbc1 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/ScanIdIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/ScanIdIT.java
@@ -40,6 +40,7 @@ import java.util.concurrent.Executors;
import java.util.concurrent.TimeUnit;
import java.util.concurrent.atomic.AtomicBoolean;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.AccumuloException;
import org.apache.accumulo.core.client.AccumuloSecurityException;
@@ -111,7 +112,7 @@ public class ScanIdIT extends AccumuloClusterHarness {
public void testScanId() throws Exception {
final String tableName = getUniqueNames(1)[0];
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
client.tableOperations().create(tableName);
addSplits(client, tableName);
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/ScanIteratorIT.java b/test/src/main/java/org/apache/accumulo/test/functional/ScanIteratorIT.java
index 8b11373..81f295f 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/ScanIteratorIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/ScanIteratorIT.java
@@ -26,6 +26,7 @@ import java.util.Map;
import java.util.Map.Entry;
import org.apache.accumulo.cluster.ClusterUser;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchScanner;
import org.apache.accumulo.core.client.BatchWriter;
@@ -65,7 +66,7 @@ public class ScanIteratorIT extends AccumuloClusterHarness {
@Before
public void setup() throws Exception {
- accumuloClient = createAccumuloClient();
+ accumuloClient = Accumulo.newClient().from(getClientProps()).build();
tableName = getUniqueNames(1)[0];
accumuloClient.tableOperations().create(tableName);
@@ -107,7 +108,7 @@ public class ScanIteratorIT extends AccumuloClusterHarness {
@Test
public void run() throws Exception {
String tableName = getUniqueNames(1)[0];
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
try (BatchWriter bw = c.createBatchWriter(tableName)) {
for (int i = 0; i < 1000; i++) {
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/ScanRangeIT.java b/test/src/main/java/org/apache/accumulo/test/functional/ScanRangeIT.java
index 3a55342..1803374 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/ScanRangeIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/ScanRangeIT.java
@@ -21,6 +21,7 @@ import static java.nio.charset.StandardCharsets.UTF_8;
import java.util.Map.Entry;
import java.util.TreeSet;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchWriter;
import org.apache.accumulo.core.client.Scanner;
@@ -47,7 +48,7 @@ public class ScanRangeIT extends AccumuloClusterHarness {
@Test
public void run() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
String[] tableNames = getUniqueNames(2);
String table1 = tableNames[0];
c.tableOperations().create(table1);
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/ScanSessionTimeOutIT.java b/test/src/main/java/org/apache/accumulo/test/functional/ScanSessionTimeOutIT.java
index f355743..097c74a 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/ScanSessionTimeOutIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/ScanSessionTimeOutIT.java
@@ -24,6 +24,7 @@ import java.util.Map;
import java.util.Map.Entry;
import java.util.concurrent.TimeUnit;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchWriter;
import org.apache.accumulo.core.client.Scanner;
@@ -63,7 +64,7 @@ public class ScanSessionTimeOutIT extends AccumuloClusterHarness {
@Before
public void reduceSessionIdle() throws Exception {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
InstanceOperations ops = client.instanceOperations();
sessionIdle = ops.getSystemConfiguration().get(Property.TSERV_SESSION_MAXIDLE.getKey());
ops.setProperty(Property.TSERV_SESSION_MAXIDLE.getKey(), getMaxIdleTimeString());
@@ -85,7 +86,7 @@ public class ScanSessionTimeOutIT extends AccumuloClusterHarness {
@After
public void resetSessionIdle() throws Exception {
if (sessionIdle != null) {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
client.instanceOperations().setProperty(Property.TSERV_SESSION_MAXIDLE.getKey(),
sessionIdle);
}
@@ -94,7 +95,7 @@ public class ScanSessionTimeOutIT extends AccumuloClusterHarness {
@Test
public void run() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(1)[0];
c.tableOperations().create(tableName);
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/ScannerContextIT.java b/test/src/main/java/org/apache/accumulo/test/functional/ScannerContextIT.java
index 5fad3a1..6419fad 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/ScannerContextIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/ScannerContextIT.java
@@ -26,6 +26,7 @@ import java.util.Collections;
import java.util.Iterator;
import java.util.Map.Entry;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchScanner;
import org.apache.accumulo.core.client.BatchWriter;
@@ -85,7 +86,7 @@ public class ScannerContextIT extends AccumuloClusterHarness {
@Test
public void test() throws Exception {
Path dstPath = copyTestIteratorsJarToTmp();
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
// Set the classloader context property on the table to point to the test iterators jar file.
c.instanceOperations().setProperty(CONTEXT_PROPERTY, CONTEXT_CLASSPATH);
@@ -134,7 +135,7 @@ public class ScannerContextIT extends AccumuloClusterHarness {
@Test
public void testScanContextOverridesTableContext() throws Exception {
Path dstPath = copyTestIteratorsJarToTmp();
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
// Create two contexts FOO and ScanContextIT. The FOO context will point to a classpath
// that contains nothing. The ScanContextIT context will point to the test iterators jar
String tableContext = "FOO";
@@ -190,7 +191,7 @@ public class ScannerContextIT extends AccumuloClusterHarness {
@Test
public void testOneScannerDoesntInterfereWithAnother() throws Exception {
Path dstPath = copyTestIteratorsJarToTmp();
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
// Set the classloader context property on the table to point to the test iterators jar file.
c.instanceOperations().setProperty(CONTEXT_PROPERTY, CONTEXT_CLASSPATH);
@@ -236,7 +237,7 @@ public class ScannerContextIT extends AccumuloClusterHarness {
@Test
public void testClearContext() throws Exception {
Path dstPath = copyTestIteratorsJarToTmp();
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
// Set the classloader context property on the table to point to the test iterators jar file.
c.instanceOperations().setProperty(CONTEXT_PROPERTY, CONTEXT_CLASSPATH);
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/ScannerIT.java b/test/src/main/java/org/apache/accumulo/test/functional/ScannerIT.java
index 7ed16a0..7717a92 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/ScannerIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/ScannerIT.java
@@ -22,6 +22,7 @@ import java.util.Iterator;
import java.util.Map.Entry;
import java.util.concurrent.TimeUnit;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchWriter;
import org.apache.accumulo.core.client.IteratorSetting;
@@ -47,7 +48,7 @@ public class ScannerIT extends AccumuloClusterHarness {
@Test
public void testScannerReadaheadConfiguration() throws Exception {
final String table = getUniqueNames(1)[0];
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
c.tableOperations().create(table);
try (BatchWriter bw = c.createBatchWriter(table)) {
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/ServerSideErrorIT.java b/test/src/main/java/org/apache/accumulo/test/functional/ServerSideErrorIT.java
index 6e9f35f..ab020ea 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/ServerSideErrorIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/ServerSideErrorIT.java
@@ -22,6 +22,7 @@ import java.util.Collections;
import java.util.Map.Entry;
import java.util.concurrent.TimeUnit;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchScanner;
import org.apache.accumulo.core.client.BatchWriter;
@@ -47,7 +48,7 @@ public class ServerSideErrorIT extends AccumuloClusterHarness {
@Test
public void run() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(1)[0];
c.tableOperations().create(tableName);
IteratorSetting is = new IteratorSetting(5, "Bad Aggregator", BadCombiner.class);
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/SessionBlockVerifyIT.java b/test/src/main/java/org/apache/accumulo/test/functional/SessionBlockVerifyIT.java
index 73a48cb..9ab63b9 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/SessionBlockVerifyIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/SessionBlockVerifyIT.java
@@ -30,6 +30,7 @@ import java.util.concurrent.ExecutorService;
import java.util.concurrent.Executors;
import java.util.concurrent.Future;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchWriter;
import org.apache.accumulo.core.client.IteratorSetting;
@@ -81,7 +82,7 @@ public class SessionBlockVerifyIT extends ScanSessionTimeOutIT {
@Test
@Override
public void run() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(1)[0];
c.tableOperations().create(tableName);
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/SparseColumnFamilyIT.java b/test/src/main/java/org/apache/accumulo/test/functional/SparseColumnFamilyIT.java
index 3390052..6298641 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/SparseColumnFamilyIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/SparseColumnFamilyIT.java
@@ -19,6 +19,7 @@ package org.apache.accumulo.test.functional;
import java.util.Iterator;
import java.util.Map.Entry;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchWriter;
import org.apache.accumulo.core.client.Scanner;
@@ -44,7 +45,7 @@ public class SparseColumnFamilyIT extends AccumuloClusterHarness {
@Test
public void sparceColumnFamily() throws Exception {
String scftt = getUniqueNames(1)[0];
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
c.tableOperations().create(scftt);
try (BatchWriter bw = c.createBatchWriter(scftt)) {
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/SplitIT.java b/test/src/main/java/org/apache/accumulo/test/functional/SplitIT.java
index 002a594..2fd3412 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/SplitIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/SplitIT.java
@@ -24,6 +24,7 @@ import java.util.Map;
import java.util.Map.Entry;
import java.util.concurrent.TimeUnit;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.Scanner;
import org.apache.accumulo.core.client.admin.InstanceOperations;
@@ -70,7 +71,7 @@ public class SplitIT extends AccumuloClusterHarness {
@Before
public void alterConfig() throws Exception {
Assume.assumeTrue(getClusterType() == ClusterType.MINI);
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
InstanceOperations iops = client.instanceOperations();
Map<String,String> config = iops.getSystemConfiguration();
tservMaxMem = config.get(Property.TSERV_MAXMEM.getKey());
@@ -101,7 +102,7 @@ public class SplitIT extends AccumuloClusterHarness {
@After
public void resetConfig() throws Exception {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
if (tservMaxMem != null) {
log.info("Resetting {}={}", Property.TSERV_MAXMEM.getKey(), tservMaxMem);
client.instanceOperations().setProperty(Property.TSERV_MAXMEM.getKey(), tservMaxMem);
@@ -119,13 +120,13 @@ public class SplitIT extends AccumuloClusterHarness {
@Test
public void tabletShouldSplit() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
String table = getUniqueNames(1)[0];
c.tableOperations().create(table);
c.tableOperations().setProperty(table, Property.TABLE_SPLIT_THRESHOLD.getKey(), "256K");
c.tableOperations().setProperty(table, Property.TABLE_FILE_COMPRESSED_BLOCK_SIZE.getKey(),
"1K");
- VerifyParams params = new VerifyParams(getClientProperties(), table, 100_000);
+ VerifyParams params = new VerifyParams(getClientProps(), table, 100_000);
TestIngest.ingest(c, params);
VerifyIngest.verifyIngest(c, params);
while (c.tableOperations().listSplits(table).size() < 10) {
@@ -156,7 +157,7 @@ public class SplitIT extends AccumuloClusterHarness {
@Test
public void interleaveSplit() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(1)[0];
c.tableOperations().create(tableName);
c.tableOperations().setProperty(tableName, Property.TABLE_SPLIT_THRESHOLD.getKey(), "10K");
@@ -177,7 +178,7 @@ public class SplitIT extends AccumuloClusterHarness {
@Test
public void deleteSplit() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(1)[0];
c.tableOperations().create(tableName);
c.tableOperations().setProperty(tableName, Property.TABLE_SPLIT_THRESHOLD.getKey(), "10K");
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/SummaryIT.java b/test/src/main/java/org/apache/accumulo/test/functional/SummaryIT.java
index bd3e8bb..4a08d8a 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/SummaryIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/SummaryIT.java
@@ -137,7 +137,7 @@ public class SummaryIT extends AccumuloClusterHarness {
@Test
public void basicSummaryTest() throws Exception {
final String table = getUniqueNames(1)[0];
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
NewTableConfiguration ntc = new NewTableConfiguration();
SummarizerConfiguration sc1 = SummarizerConfiguration.builder(BasicSummarizer.class.getName())
.build();
@@ -314,7 +314,7 @@ public class SummaryIT extends AccumuloClusterHarness {
@Test
public void selectionTest() throws Exception {
final String table = getUniqueNames(1)[0];
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
NewTableConfiguration ntc = new NewTableConfiguration();
SummarizerConfiguration sc1 = SummarizerConfiguration.builder(BasicSummarizer.class).build();
SummarizerConfiguration sc2 = SummarizerConfiguration.builder(KeySizeSummarizer.class)
@@ -478,7 +478,7 @@ public class SummaryIT extends AccumuloClusterHarness {
@Test
public void compactionTest() throws Exception {
final String table = getUniqueNames(1)[0];
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
NewTableConfiguration ntc = new NewTableConfiguration();
SummarizerConfiguration sc1 = SummarizerConfiguration.builder(FooCounter.class.getName())
.build();
@@ -548,7 +548,7 @@ public class SummaryIT extends AccumuloClusterHarness {
@Test
public void testBuggySummarizer() throws Exception {
final String table = getUniqueNames(1)[0];
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
NewTableConfiguration ntc = new NewTableConfiguration();
SummarizerConfiguration sc1 = SummarizerConfiguration.builder(BuggySummarizer.class).build();
ntc.enableSummarization(sc1);
@@ -575,7 +575,7 @@ public class SummaryIT extends AccumuloClusterHarness {
@Test
public void testPermissions() throws Exception {
final String table = getUniqueNames(1)[0];
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
NewTableConfiguration ntc = new NewTableConfiguration();
SummarizerConfiguration sc1 = SummarizerConfiguration.builder(FooCounter.class).build();
ntc.enableSummarization(sc1);
@@ -651,7 +651,7 @@ public class SummaryIT extends AccumuloClusterHarness {
@Test
public void tooLargeTest() throws Exception {
final String table = getUniqueNames(1)[0];
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
NewTableConfiguration ntc = new NewTableConfiguration();
SummarizerConfiguration sc1 = SummarizerConfiguration.builder(BigSummarizer.class).build();
ntc.enableSummarization(sc1);
@@ -722,7 +722,7 @@ public class SummaryIT extends AccumuloClusterHarness {
@Test
public void testLocalityGroups() throws Exception {
final String table = getUniqueNames(1)[0];
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
NewTableConfiguration ntc = new NewTableConfiguration();
SummarizerConfiguration sc1 = SummarizerConfiguration.builder(FamilySummarizer.class).build();
SummarizerConfiguration sc2 = SummarizerConfiguration.builder(BasicSummarizer.class).build();
@@ -785,7 +785,7 @@ public class SummaryIT extends AccumuloClusterHarness {
@Test
public void testExceptions() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
try {
c.tableOperations().summaries("foo").retrieve();
@@ -843,7 +843,7 @@ public class SummaryIT extends AccumuloClusterHarness {
@Test
public void testManyFiles() throws Exception {
final String table = getUniqueNames(1)[0];
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
NewTableConfiguration ntc = new NewTableConfiguration();
ntc.enableSummarization(SummarizerConfiguration.builder(FamilySummarizer.class).build());
c.tableOperations().create(table, ntc);
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/TableIT.java b/test/src/main/java/org/apache/accumulo/test/functional/TableIT.java
index c385a18..b6f5a87 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/TableIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/TableIT.java
@@ -23,6 +23,7 @@ import static org.junit.Assert.assertTrue;
import java.io.FileNotFoundException;
import org.apache.accumulo.cluster.AccumuloCluster;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.Scanner;
import org.apache.accumulo.core.client.admin.TableOperations;
@@ -62,12 +63,12 @@ public class TableIT extends AccumuloClusterHarness {
MiniAccumuloClusterImpl mac = (MiniAccumuloClusterImpl) cluster;
String rootPath = mac.getConfig().getDir().getAbsolutePath();
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
TableOperations to = c.tableOperations();
String tableName = getUniqueNames(1)[0];
to.create(tableName);
- VerifyParams params = new VerifyParams(getClientProperties(), tableName);
+ VerifyParams params = new VerifyParams(getClientProps(), tableName);
TestIngest.ingest(c, params);
to.flush(tableName, null, null, true);
VerifyIngest.verifyIngest(c, params);
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/TabletIT.java b/test/src/main/java/org/apache/accumulo/test/functional/TabletIT.java
index 84e6712..4d125fc 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/TabletIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/TabletIT.java
@@ -23,6 +23,7 @@ import java.util.Map;
import java.util.Map.Entry;
import java.util.TreeSet;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchWriter;
import org.apache.accumulo.core.client.Scanner;
@@ -57,7 +58,7 @@ public class TabletIT extends AccumuloClusterHarness {
@Test
public void createTableTest() throws Exception {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(1)[0];
createTableTest(client, tableName, false);
createTableTest(client, tableName, true);
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/TabletStateChangeIteratorIT.java b/test/src/main/java/org/apache/accumulo/test/functional/TabletStateChangeIteratorIT.java
index 8180bb7..fc12a77 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/TabletStateChangeIteratorIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/TabletStateChangeIteratorIT.java
@@ -28,6 +28,7 @@ import java.util.SortedSet;
import java.util.TreeSet;
import org.apache.accumulo.core.Constants;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.AccumuloException;
import org.apache.accumulo.core.client.AccumuloSecurityException;
@@ -81,7 +82,7 @@ public class TabletStateChangeIteratorIT extends AccumuloClusterHarness {
public void test() throws AccumuloException, AccumuloSecurityException, TableExistsException,
TableNotFoundException {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
String[] tables = getUniqueNames(4);
final String t1 = tables[0];
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/TimeoutIT.java b/test/src/main/java/org/apache/accumulo/test/functional/TimeoutIT.java
index 0667213..49d4a60 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/TimeoutIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/TimeoutIT.java
@@ -23,6 +23,7 @@ import java.util.Collections;
import java.util.Map.Entry;
import java.util.concurrent.TimeUnit;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchScanner;
import org.apache.accumulo.core.client.BatchWriter;
@@ -46,7 +47,7 @@ public class TimeoutIT extends AccumuloClusterHarness {
@Test
public void run() throws Exception {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
String[] tableNames = getUniqueNames(2);
testBatchWriterTimeout(client, tableNames[0]);
testBatchScannerTimeout(client, tableNames[1]);
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/TooManyDeletesIT.java b/test/src/main/java/org/apache/accumulo/test/functional/TooManyDeletesIT.java
index 50949bb..df8a686 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/TooManyDeletesIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/TooManyDeletesIT.java
@@ -22,6 +22,7 @@ import static org.junit.Assert.assertEquals;
import java.util.HashMap;
import java.util.List;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchWriter;
import org.apache.accumulo.core.client.admin.NewTableConfiguration;
@@ -38,7 +39,7 @@ import org.junit.Test;
public class TooManyDeletesIT extends AccumuloClusterHarness {
@Test
public void tooManyDeletesCompactionStrategyIT() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
String table = getUniqueNames(1)[0];
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/VisibilityIT.java b/test/src/main/java/org/apache/accumulo/test/functional/VisibilityIT.java
index 0a9445d..cccd82e 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/VisibilityIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/VisibilityIT.java
@@ -30,6 +30,7 @@ import java.util.Set;
import java.util.SortedSet;
import java.util.TreeSet;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchScanner;
import org.apache.accumulo.core.client.BatchWriter;
@@ -61,14 +62,14 @@ public class VisibilityIT extends AccumuloClusterHarness {
@Before
public void emptyAuths() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
origAuths = c.securityOperations().getUserAuthorizations(getAdminPrincipal());
}
}
@After
public void resetAuths() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
if (origAuths != null) {
c.securityOperations().changeUserAuthorizations(getAdminPrincipal(), origAuths);
}
@@ -77,7 +78,7 @@ public class VisibilityIT extends AccumuloClusterHarness {
@Test
public void run() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
String[] tableNames = getUniqueNames(2);
String table = tableNames[0];
c.tableOperations().create(table);
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/WriteAheadLogEncryptedIT.java b/test/src/main/java/org/apache/accumulo/test/functional/WriteAheadLogEncryptedIT.java
index 19b7121..03feba7 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/WriteAheadLogEncryptedIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/WriteAheadLogEncryptedIT.java
@@ -19,6 +19,7 @@ package org.apache.accumulo.test.functional;
import static org.apache.accumulo.core.conf.Property.INSTANCE_CRYPTO_PREFIX;
import static org.apache.accumulo.test.functional.WriteAheadLogIT.testWAL;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.conf.Property;
import org.apache.accumulo.harness.AccumuloClusterHarness;
@@ -70,7 +71,7 @@ public class WriteAheadLogEncryptedIT extends AccumuloClusterHarness {
@Test
public void test() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
testWAL(c, getUniqueNames(1)[0]);
}
}
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/WriteAheadLogIT.java b/test/src/main/java/org/apache/accumulo/test/functional/WriteAheadLogIT.java
index f738eb1..731a7e3 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/WriteAheadLogIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/WriteAheadLogIT.java
@@ -16,6 +16,7 @@
*/
package org.apache.accumulo.test.functional;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.conf.Property;
import org.apache.accumulo.harness.AccumuloClusterHarness;
@@ -52,7 +53,7 @@ public class WriteAheadLogIT extends AccumuloClusterHarness {
@Test
public void test() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
testWAL(c, getUniqueNames(1)[0]);
}
}
@@ -60,7 +61,7 @@ public class WriteAheadLogIT extends AccumuloClusterHarness {
public static void testWAL(AccumuloClient c, String tableName) throws Exception {
c.tableOperations().create(tableName);
c.tableOperations().setProperty(tableName, Property.TABLE_SPLIT_THRESHOLD.getKey(), "750K");
- VerifyParams params = new VerifyParams(getClientProperties(), tableName);
+ VerifyParams params = new VerifyParams(getClientProps(), tableName);
TestIngest.ingest(c, params);
VerifyIngest.verifyIngest(c, params);
getCluster().getClusterControl().stopAllServers(ServerType.TABLET_SERVER);
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/WriteLotsIT.java b/test/src/main/java/org/apache/accumulo/test/functional/WriteLotsIT.java
index a10595e..de7ab2b 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/WriteLotsIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/WriteLotsIT.java
@@ -43,8 +43,8 @@ public class WriteLotsIT extends AccumuloClusterHarness {
BatchWriterConfig bwConfig = new BatchWriterConfig();
bwConfig.setMaxMemory(1024L * 1024);
bwConfig.setMaxWriteThreads(2);
- try (AccumuloClient c = Accumulo.newClient().from(getClientProperties())
- .batchWriterConfig(bwConfig).build()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).batchWriterConfig(bwConfig)
+ .build()) {
final String tableName = getUniqueNames(1)[0];
c.tableOperations().create(tableName);
final AtomicReference<Exception> ref = new AtomicReference<>();
@@ -55,7 +55,7 @@ public class WriteLotsIT extends AccumuloClusterHarness {
final int index = i;
Runnable r = () -> {
try {
- IngestParams ingestParams = new IngestParams(getClientProperties(), tableName, 10_000);
+ IngestParams ingestParams = new IngestParams(getClientProps(), tableName, 10_000);
ingestParams.startRow = index * 10000;
TestIngest.ingest(c, ingestParams);
} catch (Exception ex) {
@@ -69,7 +69,7 @@ public class WriteLotsIT extends AccumuloClusterHarness {
if (ref.get() != null) {
throw ref.get();
}
- VerifyParams params = new VerifyParams(getClientProperties(), tableName, 10_000 * THREADS);
+ VerifyParams params = new VerifyParams(getClientProps(), tableName, 10_000 * THREADS);
VerifyIngest.verifyIngest(c, params);
}
}
diff --git a/test/src/main/java/org/apache/accumulo/test/mapred/AccumuloFileOutputFormatIT.java b/test/src/main/java/org/apache/accumulo/test/mapred/AccumuloFileOutputFormatIT.java
index 9a77c9a..60d5b77 100644
--- a/test/src/main/java/org/apache/accumulo/test/mapred/AccumuloFileOutputFormatIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/mapred/AccumuloFileOutputFormatIT.java
@@ -24,6 +24,7 @@ import static org.junit.Assert.fail;
import java.io.File;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchWriter;
import org.apache.accumulo.core.client.sample.RowSampler;
@@ -80,7 +81,7 @@ public class AccumuloFileOutputFormatIT extends AccumuloClusterHarness {
@Test
public void testEmptyWrite() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
c.tableOperations().create(EMPTY_TABLE);
handleWriteTests(false);
}
@@ -88,7 +89,7 @@ public class AccumuloFileOutputFormatIT extends AccumuloClusterHarness {
@Test
public void testRealWrite() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
c.tableOperations().create(TEST_TABLE);
try (BatchWriter bw = c.createBatchWriter(TEST_TABLE)) {
Mutation m = new Mutation("Key");
@@ -210,7 +211,7 @@ public class AccumuloFileOutputFormatIT extends AccumuloClusterHarness {
@Test
public void writeBadVisibility() throws Exception {
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
c.tableOperations().create(BAD_TABLE);
try (BatchWriter bw = c.createBatchWriter(BAD_TABLE)) {
Mutation m = new Mutation("r1");
diff --git a/test/src/main/java/org/apache/accumulo/test/mapred/AccumuloInputFormatIT.java b/test/src/main/java/org/apache/accumulo/test/mapred/AccumuloInputFormatIT.java
index 5a4644e..04f2676 100644
--- a/test/src/main/java/org/apache/accumulo/test/mapred/AccumuloInputFormatIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/mapred/AccumuloInputFormatIT.java
@@ -23,6 +23,7 @@ import java.io.File;
import java.util.Collection;
import java.util.Collections;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchWriter;
import org.apache.accumulo.core.client.admin.NewTableConfiguration;
@@ -157,7 +158,7 @@ public class AccumuloInputFormatIT extends AccumuloClusterHarness {
@Test
public void testMap() throws Exception {
String table = getUniqueNames(1)[0];
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
c.tableOperations().create(table);
try (BatchWriter bw = c.createBatchWriter(table)) {
for (int i = 0; i < 100; i++) {
@@ -183,7 +184,7 @@ public class AccumuloInputFormatIT extends AccumuloClusterHarness {
public void testSample() throws Exception {
final String TEST_TABLE_3 = getUniqueNames(1)[0];
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
c.tableOperations().create(TEST_TABLE_3,
new NewTableConfiguration().enableSampling(SAMPLER_CONFIG));
try (BatchWriter bw = c.createBatchWriter(TEST_TABLE_3)) {
@@ -221,7 +222,7 @@ public class AccumuloInputFormatIT extends AccumuloClusterHarness {
boolean isolated = true, localIters = true;
Level level = Level.WARN;
- try (AccumuloClient accumuloClient = createAccumuloClient()) {
+ try (AccumuloClient accumuloClient = Accumulo.newClient().from(getClientProps()).build()) {
accumuloClient.tableOperations().create(table);
ClientInfo ci = getClientInfo();
diff --git a/test/src/main/java/org/apache/accumulo/test/mapred/AccumuloMultiTableInputFormatIT.java b/test/src/main/java/org/apache/accumulo/test/mapred/AccumuloMultiTableInputFormatIT.java
index a60fa4b..16781cb 100644
--- a/test/src/main/java/org/apache/accumulo/test/mapred/AccumuloMultiTableInputFormatIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/mapred/AccumuloMultiTableInputFormatIT.java
@@ -23,6 +23,7 @@ import java.io.File;
import java.util.HashMap;
import java.util.Map;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchWriter;
import org.apache.accumulo.core.clientImpl.ClientInfo;
@@ -144,7 +145,7 @@ public class AccumuloMultiTableInputFormatIT extends AccumuloClusterHarness {
String[] tableNames = getUniqueNames(2);
String table1 = tableNames[0];
String table2 = tableNames[1];
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
c.tableOperations().create(table1);
c.tableOperations().create(table2);
try (BatchWriter bw = c.createBatchWriter(table1);
diff --git a/test/src/main/java/org/apache/accumulo/test/mapred/AccumuloRowInputFormatIT.java b/test/src/main/java/org/apache/accumulo/test/mapred/AccumuloRowInputFormatIT.java
index 087257c..3349d09 100644
--- a/test/src/main/java/org/apache/accumulo/test/mapred/AccumuloRowInputFormatIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/mapred/AccumuloRowInputFormatIT.java
@@ -26,6 +26,7 @@ import java.util.Iterator;
import java.util.List;
import java.util.Map.Entry;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchWriter;
import org.apache.accumulo.core.client.MutationsRejectedException;
@@ -189,7 +190,7 @@ public class AccumuloRowInputFormatIT extends AccumuloClusterHarness {
@Test
public void test() throws Exception {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(1)[0];
client.tableOperations().create(tableName);
try (BatchWriter writer = client.createBatchWriter(tableName)) {
diff --git a/test/src/main/java/org/apache/accumulo/test/mapred/TokenFileIT.java b/test/src/main/java/org/apache/accumulo/test/mapred/TokenFileIT.java
index e15f287..75db691 100644
--- a/test/src/main/java/org/apache/accumulo/test/mapred/TokenFileIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/mapred/TokenFileIT.java
@@ -27,6 +27,7 @@ import java.io.PrintStream;
import java.util.Iterator;
import java.util.Map.Entry;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchWriter;
import org.apache.accumulo.core.client.Scanner;
@@ -156,7 +157,7 @@ public class TokenFileIT extends AccumuloClusterHarness {
String[] tableNames = getUniqueNames(2);
String table1 = tableNames[0];
String table2 = tableNames[1];
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
c.tableOperations().create(table1);
c.tableOperations().create(table2);
try (BatchWriter bw = c.createBatchWriter(table1)) {
diff --git a/test/src/main/java/org/apache/accumulo/test/mapreduce/AccumuloFileOutputFormatIT.java b/test/src/main/java/org/apache/accumulo/test/mapreduce/AccumuloFileOutputFormatIT.java
index a1220db..0f9584d 100644
--- a/test/src/main/java/org/apache/accumulo/test/mapreduce/AccumuloFileOutputFormatIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/mapreduce/AccumuloFileOutputFormatIT.java
@@ -23,6 +23,7 @@ import static org.junit.Assert.fail;
import java.io.File;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchWriter;
import org.apache.accumulo.core.client.sample.RowSampler;
@@ -83,7 +84,7 @@ public class AccumuloFileOutputFormatIT extends AccumuloClusterHarness {
TEST_TABLE = PREFIX + "_mapreduce_test_table";
EMPTY_TABLE = PREFIX + "_mapreduce_empty_table";
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
c.tableOperations().create(EMPTY_TABLE);
c.tableOperations().create(TEST_TABLE);
c.tableOperations().create(BAD_TABLE);
diff --git a/test/src/main/java/org/apache/accumulo/test/mapreduce/AccumuloInputFormatIT.java b/test/src/main/java/org/apache/accumulo/test/mapreduce/AccumuloInputFormatIT.java
index 4ee4e31..ae4b81e 100644
--- a/test/src/main/java/org/apache/accumulo/test/mapreduce/AccumuloInputFormatIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/mapreduce/AccumuloInputFormatIT.java
@@ -31,6 +31,7 @@ import java.util.List;
import java.util.TreeSet;
import java.util.concurrent.TimeUnit;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.AccumuloException;
import org.apache.accumulo.core.client.BatchWriter;
@@ -94,7 +95,7 @@ public class AccumuloInputFormatIT extends AccumuloClusterHarness {
*/
@Test
public void testGetSplits() throws Exception {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
String table = getUniqueNames(1)[0];
client.tableOperations().create(table);
insertData(client, table, currentTimeMillis());
@@ -321,7 +322,7 @@ public class AccumuloInputFormatIT extends AccumuloClusterHarness {
public void testMap() throws Exception {
final String TEST_TABLE_1 = getUniqueNames(1)[0];
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
c.tableOperations().create(TEST_TABLE_1);
AccumuloOutputFormatIT.insertData(c, TEST_TABLE_1);
assertEquals(0, MRTester.main(new String[] {TEST_TABLE_1,
@@ -338,7 +339,7 @@ public class AccumuloInputFormatIT extends AccumuloClusterHarness {
public void testSample() throws Exception {
final String TEST_TABLE_3 = getUniqueNames(1)[0];
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
c.tableOperations().create(TEST_TABLE_3,
new NewTableConfiguration().enableSampling(SAMPLER_CONFIG));
AccumuloOutputFormatIT.insertData(c, TEST_TABLE_3);
@@ -371,7 +372,7 @@ public class AccumuloInputFormatIT extends AccumuloClusterHarness {
public void testMapWithBatchScanner() throws Exception {
final String TEST_TABLE_2 = getUniqueNames(1)[0];
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
c.tableOperations().create(TEST_TABLE_2);
AccumuloOutputFormatIT.insertData(c, TEST_TABLE_2);
assertEquals(0,
@@ -394,7 +395,7 @@ public class AccumuloInputFormatIT extends AccumuloClusterHarness {
boolean isolated = true, localIters = true;
Level level = Level.WARN;
- try (AccumuloClient accumuloClient = createAccumuloClient()) {
+ try (AccumuloClient accumuloClient = Accumulo.newClient().from(getClientProps()).build()) {
accumuloClient.tableOperations().create(table);
ClientInfo ci = getClientInfo();
@@ -435,7 +436,7 @@ public class AccumuloInputFormatIT extends AccumuloClusterHarness {
@Test
public void testPartialInputSplitDelegationToConfiguration() throws Exception {
String table = getUniqueNames(1)[0];
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
c.tableOperations().create(table);
AccumuloOutputFormatIT.insertData(c, table);
assertEquals(0,
diff --git a/test/src/main/java/org/apache/accumulo/test/mapreduce/AccumuloMultiTableInputFormatIT.java b/test/src/main/java/org/apache/accumulo/test/mapreduce/AccumuloMultiTableInputFormatIT.java
index 91b8e76..3d7d1cb 100644
--- a/test/src/main/java/org/apache/accumulo/test/mapreduce/AccumuloMultiTableInputFormatIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/mapreduce/AccumuloMultiTableInputFormatIT.java
@@ -23,6 +23,7 @@ import java.io.File;
import java.util.HashMap;
import java.util.Map;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchWriter;
import org.apache.accumulo.core.client.BatchWriterConfig;
@@ -146,7 +147,7 @@ public class AccumuloMultiTableInputFormatIT extends AccumuloClusterHarness {
String[] tableNames = getUniqueNames(2);
String table1 = tableNames[0];
String table2 = tableNames[1];
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
c.tableOperations().create(table1);
c.tableOperations().create(table2);
BatchWriter bw = c.createBatchWriter(table1, new BatchWriterConfig());
diff --git a/test/src/main/java/org/apache/accumulo/test/mapreduce/AccumuloOutputFormatIT.java b/test/src/main/java/org/apache/accumulo/test/mapreduce/AccumuloOutputFormatIT.java
index 392bf50..9a20959 100644
--- a/test/src/main/java/org/apache/accumulo/test/mapreduce/AccumuloOutputFormatIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/mapreduce/AccumuloOutputFormatIT.java
@@ -26,6 +26,7 @@ import java.io.IOException;
import java.util.Iterator;
import java.util.Map.Entry;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchWriter;
import org.apache.accumulo.core.client.MutationsRejectedException;
@@ -152,7 +153,7 @@ public class AccumuloOutputFormatIT extends AccumuloClusterHarness {
String[] tableNames = getUniqueNames(2);
String table1 = tableNames[0];
String table2 = tableNames[1];
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
c.tableOperations().create(table1);
c.tableOperations().create(table2);
insertData(c, table1);
diff --git a/test/src/main/java/org/apache/accumulo/test/mapreduce/AccumuloRowInputFormatIT.java b/test/src/main/java/org/apache/accumulo/test/mapreduce/AccumuloRowInputFormatIT.java
index e83ef0e..65366fb 100644
--- a/test/src/main/java/org/apache/accumulo/test/mapreduce/AccumuloRowInputFormatIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/mapreduce/AccumuloRowInputFormatIT.java
@@ -26,6 +26,7 @@ import java.util.Iterator;
import java.util.List;
import java.util.Map.Entry;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchWriter;
import org.apache.accumulo.core.client.BatchWriterConfig;
@@ -187,7 +188,7 @@ public class AccumuloRowInputFormatIT extends AccumuloClusterHarness {
@Test
public void test() throws Exception {
- try (AccumuloClient client = createAccumuloClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
String tableName = getUniqueNames(1)[0];
client.tableOperations().create(tableName);
BatchWriter writer = null;
diff --git a/test/src/main/java/org/apache/accumulo/test/mapreduce/TokenFileIT.java b/test/src/main/java/org/apache/accumulo/test/mapreduce/TokenFileIT.java
index a3dd49c..c2439d1 100644
--- a/test/src/main/java/org/apache/accumulo/test/mapreduce/TokenFileIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/mapreduce/TokenFileIT.java
@@ -27,6 +27,7 @@ import java.io.PrintStream;
import java.util.Iterator;
import java.util.Map.Entry;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchWriter;
import org.apache.accumulo.core.client.BatchWriterConfig;
@@ -151,7 +152,7 @@ public class TokenFileIT extends AccumuloClusterHarness {
String[] tableNames = getUniqueNames(2);
String table1 = tableNames[0];
String table2 = tableNames[1];
- try (AccumuloClient c = createAccumuloClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
c.tableOperations().create(table1);
c.tableOperations().create(table2);
BatchWriter bw = c.createBatchWriter(table1, new BatchWriterConfig());
diff --git a/test/src/main/java/org/apache/accumulo/test/proxy/SimpleProxyBase.java b/test/src/main/java/org/apache/accumulo/test/proxy/SimpleProxyBase.java
index 09f9357..b9f3a8f 100644
--- a/test/src/main/java/org/apache/accumulo/test/proxy/SimpleProxyBase.java
+++ b/test/src/main/java/org/apache/accumulo/test/proxy/SimpleProxyBase.java
@@ -46,6 +46,7 @@ import java.util.UUID;
import java.util.concurrent.TimeUnit;
import org.apache.accumulo.cluster.ClusterUser;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.security.tokens.KerberosToken;
import org.apache.accumulo.core.client.security.tokens.PasswordToken;
@@ -178,7 +179,7 @@ public abstract class SimpleProxyBase extends SharedMiniClusterBase {
public static void setUpProxy() throws Exception {
assertNotNull("Implementations must initialize the TProtocolFactory", factory);
- try (AccumuloClient c = SharedMiniClusterBase.createClient()) {
+ try (AccumuloClient c = Accumulo.newClient().from(getClientProps()).build()) {
waitForAccumulo(c);
hostname = InetAddress.getLocalHost().getCanonicalHostName();
diff --git a/test/src/main/java/org/apache/accumulo/test/replication/StatusCombinerMacIT.java b/test/src/main/java/org/apache/accumulo/test/replication/StatusCombinerMacIT.java
index 75a06da..aa33903 100644
--- a/test/src/main/java/org/apache/accumulo/test/replication/StatusCombinerMacIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/replication/StatusCombinerMacIT.java
@@ -25,6 +25,7 @@ import java.util.Map;
import java.util.Map.Entry;
import org.apache.accumulo.cluster.ClusterUser;
+import org.apache.accumulo.core.client.Accumulo;
import org.apache.accumulo.core.client.AccumuloClient;
import org.apache.accumulo.core.client.BatchWriter;
import org.apache.accumulo.core.client.Scanner;
@@ -70,7 +71,7 @@ public class StatusCombinerMacIT extends SharedMiniClusterBase {
@Test
public void testCombinerSetOnMetadata() throws Exception {
- try (AccumuloClient client = createClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
TableOperations tops = client.tableOperations();
Map<String,EnumSet<IteratorScope>> iterators = tops.listIterators(MetadataTable.NAME);
@@ -98,7 +99,7 @@ public class StatusCombinerMacIT extends SharedMiniClusterBase {
@Test
public void test() throws Exception {
- try (AccumuloClient client = createClient()) {
+ try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
ClusterUser user = getAdminUser();
ReplicationTable.setOnline(client);