accumulo-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ctubb...@apache.org
Subject [4/5] accumulo git commit: ACCUMULO-4145 Eliminate Text wrapping of tableIDs
Date Sat, 20 Feb 2016 02:58:38 GMT
http://git-wip-us.apache.org/repos/asf/accumulo/blob/a14bc292/core/src/test/java/org/apache/accumulo/core/data/KeyExtentTest.java
----------------------------------------------------------------------
diff --git a/core/src/test/java/org/apache/accumulo/core/data/KeyExtentTest.java b/core/src/test/java/org/apache/accumulo/core/data/KeyExtentTest.java
index b1ac1c5..724bfee 100644
--- a/core/src/test/java/org/apache/accumulo/core/data/KeyExtentTest.java
+++ b/core/src/test/java/org/apache/accumulo/core/data/KeyExtentTest.java
@@ -44,7 +44,7 @@ import org.junit.Test;
 
 public class KeyExtentTest {
   KeyExtent nke(String t, String er, String per) {
-    return new KeyExtent(new Text(t), er == null ? null : new Text(er), per == null ? null : new Text(per));
+    return new KeyExtent(t, er == null ? null : new Text(er), per == null ? null : new Text(per));
   }
 
   KeyExtent ke;
@@ -62,7 +62,7 @@ public class KeyExtentTest {
     ke = new KeyExtent(flattenedExtent, (Text) null);
 
     assertEquals(new Text("bar"), ke.getEndRow());
-    assertEquals(new Text("foo"), ke.getTableId());
+    assertEquals("foo", ke.getTableId());
     assertNull(ke.getPrevEndRow());
 
     flattenedExtent = new Text("foo<");
@@ -70,7 +70,7 @@ public class KeyExtentTest {
     ke = new KeyExtent(flattenedExtent, (Text) null);
 
     assertNull(ke.getEndRow());
-    assertEquals(new Text("foo"), ke.getTableId());
+    assertEquals("foo", ke.getTableId());
     assertNull(ke.getPrevEndRow());
 
     flattenedExtent = new Text("foo;bar;");
@@ -78,7 +78,7 @@ public class KeyExtentTest {
     ke = new KeyExtent(flattenedExtent, (Text) null);
 
     assertEquals(new Text("bar;"), ke.getEndRow());
-    assertEquals(new Text("foo"), ke.getTableId());
+    assertEquals("foo", ke.getTableId());
     assertNull(ke.getPrevEndRow());
 
   }

http://git-wip-us.apache.org/repos/asf/accumulo/blob/a14bc292/core/src/test/java/org/apache/accumulo/core/data/RangeTest.java
----------------------------------------------------------------------
diff --git a/core/src/test/java/org/apache/accumulo/core/data/RangeTest.java b/core/src/test/java/org/apache/accumulo/core/data/RangeTest.java
index 1e5e985..2641ef1 100644
--- a/core/src/test/java/org/apache/accumulo/core/data/RangeTest.java
+++ b/core/src/test/java/org/apache/accumulo/core/data/RangeTest.java
@@ -191,31 +191,30 @@ public class RangeTest extends TestCase {
 
   public void testMergeOverlapping22() {
 
-    Range ke1 = new KeyExtent(new Text("tab1"), new Text("Bank"), null).toMetadataRange();
-    Range ke2 = new KeyExtent(new Text("tab1"), new Text("Fails"), new Text("Bank")).toMetadataRange();
-    Range ke3 = new KeyExtent(new Text("tab1"), new Text("Sam"), new Text("Fails")).toMetadataRange();
-    Range ke4 = new KeyExtent(new Text("tab1"), new Text("bails"), new Text("Sam")).toMetadataRange();
-    Range ke5 = new KeyExtent(new Text("tab1"), null, new Text("bails")).toMetadataRange();
+    Range ke1 = new KeyExtent("tab1", new Text("Bank"), null).toMetadataRange();
+    Range ke2 = new KeyExtent("tab1", new Text("Fails"), new Text("Bank")).toMetadataRange();
+    Range ke3 = new KeyExtent("tab1", new Text("Sam"), new Text("Fails")).toMetadataRange();
+    Range ke4 = new KeyExtent("tab1", new Text("bails"), new Text("Sam")).toMetadataRange();
+    Range ke5 = new KeyExtent("tab1", null, new Text("bails")).toMetadataRange();
 
     List<Range> rl = nrl(ke1, ke2, ke3, ke4, ke5);
-    List<Range> expected = nrl(new KeyExtent(new Text("tab1"), null, null).toMetadataRange());
+    List<Range> expected = nrl(new KeyExtent("tab1", null, null).toMetadataRange());
     check(Range.mergeOverlapping(rl), expected);
 
     rl = nrl(ke1, ke2, ke4, ke5);
-    expected = nrl(new KeyExtent(new Text("tab1"), new Text("Fails"), null).toMetadataRange(),
-        new KeyExtent(new Text("tab1"), null, new Text("Sam")).toMetadataRange());
+    expected = nrl(new KeyExtent("tab1", new Text("Fails"), null).toMetadataRange(), new KeyExtent("tab1", null, new Text("Sam")).toMetadataRange());
     check(Range.mergeOverlapping(rl), expected);
 
     rl = nrl(ke2, ke3, ke4, ke5);
-    expected = nrl(new KeyExtent(new Text("tab1"), null, new Text("Bank")).toMetadataRange());
+    expected = nrl(new KeyExtent("tab1", null, new Text("Bank")).toMetadataRange());
     check(Range.mergeOverlapping(rl), expected);
 
     rl = nrl(ke1, ke2, ke3, ke4);
-    expected = nrl(new KeyExtent(new Text("tab1"), new Text("bails"), null).toMetadataRange());
+    expected = nrl(new KeyExtent("tab1", new Text("bails"), null).toMetadataRange());
     check(Range.mergeOverlapping(rl), expected);
 
     rl = nrl(ke2, ke3, ke4);
-    expected = nrl(new KeyExtent(new Text("tab1"), new Text("bails"), new Text("Bank")).toMetadataRange());
+    expected = nrl(new KeyExtent("tab1", new Text("bails"), new Text("Bank")).toMetadataRange());
     check(Range.mergeOverlapping(rl), expected);
   }
 

http://git-wip-us.apache.org/repos/asf/accumulo/blob/a14bc292/core/src/test/java/org/apache/accumulo/core/file/rfile/RFileTest.java
----------------------------------------------------------------------
diff --git a/core/src/test/java/org/apache/accumulo/core/file/rfile/RFileTest.java b/core/src/test/java/org/apache/accumulo/core/file/rfile/RFileTest.java
index ab98f49..a442347 100644
--- a/core/src/test/java/org/apache/accumulo/core/file/rfile/RFileTest.java
+++ b/core/src/test/java/org/apache/accumulo/core/file/rfile/RFileTest.java
@@ -2132,7 +2132,7 @@ public class RFileTest {
 
     // mfw.startDefaultLocalityGroup();
 
-    Text tableExtent = new Text(KeyExtent.getMetadataEntry(new Text(MetadataTable.ID), MetadataSchema.TabletsSection.getRange().getEndKey().getRow()));
+    Text tableExtent = new Text(KeyExtent.getMetadataEntry(MetadataTable.ID, MetadataSchema.TabletsSection.getRange().getEndKey().getRow()));
 
     // table tablet's directory
     Key tableDirKey = new Key(tableExtent, TabletsSection.ServerColumnFamily.DIRECTORY_COLUMN.getColumnFamily(),
@@ -2150,7 +2150,7 @@ public class RFileTest {
     mfw.append(tablePrevRowKey, KeyExtent.encodePrevEndRow(null));
 
     // ----------] default tablet info
-    Text defaultExtent = new Text(KeyExtent.getMetadataEntry(new Text(MetadataTable.ID), null));
+    Text defaultExtent = new Text(KeyExtent.getMetadataEntry(MetadataTable.ID, null));
 
     // default's directory
     Key defaultDirKey = new Key(defaultExtent, TabletsSection.ServerColumnFamily.DIRECTORY_COLUMN.getColumnFamily(),

http://git-wip-us.apache.org/repos/asf/accumulo/blob/a14bc292/core/src/test/java/org/apache/accumulo/core/iterators/IteratorUtilTest.java
----------------------------------------------------------------------
diff --git a/core/src/test/java/org/apache/accumulo/core/iterators/IteratorUtilTest.java b/core/src/test/java/org/apache/accumulo/core/iterators/IteratorUtilTest.java
index 87ad392..4c4303c 100644
--- a/core/src/test/java/org/apache/accumulo/core/iterators/IteratorUtilTest.java
+++ b/core/src/test/java/org/apache/accumulo/core/iterators/IteratorUtilTest.java
@@ -40,7 +40,6 @@ import org.apache.accumulo.core.iterators.IteratorUtil.IteratorScope;
 import org.apache.accumulo.core.iterators.system.MultiIteratorTest;
 import org.apache.accumulo.core.iterators.user.AgeOffFilter;
 import org.apache.accumulo.core.iterators.user.SummingCombiner;
-import org.apache.hadoop.io.Text;
 import org.junit.Assert;
 import org.junit.Test;
 
@@ -139,7 +138,7 @@ public class IteratorUtilTest {
 
     SortedMapIterator source = new SortedMapIterator(tm);
 
-    SortedKeyValueIterator<Key,Value> iter = IteratorUtil.loadIterators(IteratorScope.minc, source, new KeyExtent(new Text("tab"), null, null), conf,
+    SortedKeyValueIterator<Key,Value> iter = IteratorUtil.loadIterators(IteratorScope.minc, source, new KeyExtent("tab", null, null), conf,
         new DefaultIteratorEnvironment(conf));
     iter.seek(new Range(), EMPTY_COL_FAMS, false);
 
@@ -171,7 +170,7 @@ public class IteratorUtilTest {
 
     SortedMapIterator source = new SortedMapIterator(tm);
 
-    SortedKeyValueIterator<Key,Value> iter = IteratorUtil.loadIterators(IteratorScope.majc, source, new KeyExtent(new Text("tab"), null, null), conf,
+    SortedKeyValueIterator<Key,Value> iter = IteratorUtil.loadIterators(IteratorScope.majc, source, new KeyExtent("tab", null, null), conf,
         new DefaultIteratorEnvironment(conf));
     iter.seek(new Range(), EMPTY_COL_FAMS, false);
 
@@ -207,7 +206,7 @@ public class IteratorUtilTest {
     conf.set(Property.TABLE_ITERATOR_PREFIX + IteratorScope.minc.name() + ".addIter", "2," + AddingIter.class.getName());
     conf.set(Property.TABLE_ITERATOR_PREFIX + IteratorScope.minc.name() + ".sqIter", "1," + SquaringIter.class.getName());
 
-    SortedKeyValueIterator<Key,Value> iter = IteratorUtil.loadIterators(IteratorScope.minc, source, new KeyExtent(new Text("tab"), null, null), conf,
+    SortedKeyValueIterator<Key,Value> iter = IteratorUtil.loadIterators(IteratorScope.minc, source, new KeyExtent("tab", null, null), conf,
         new DefaultIteratorEnvironment(conf));
     iter.seek(new Range(), EMPTY_COL_FAMS, false);
 
@@ -243,7 +242,7 @@ public class IteratorUtilTest {
 
     SortedMapIterator source = new SortedMapIterator(tm);
 
-    SortedKeyValueIterator<Key,Value> iter = IteratorUtil.loadIterators(IteratorScope.minc, source, new KeyExtent(new Text("tab"), null, null), conf,
+    SortedKeyValueIterator<Key,Value> iter = IteratorUtil.loadIterators(IteratorScope.minc, source, new KeyExtent("tab", null, null), conf,
         new DefaultIteratorEnvironment(conf));
     iter.seek(new Range(), EMPTY_COL_FAMS, false);
 
@@ -279,7 +278,7 @@ public class IteratorUtilTest {
 
     SortedMapIterator source = new SortedMapIterator(tm);
 
-    SortedKeyValueIterator<Key,Value> iter = IteratorUtil.loadIterators(IteratorScope.minc, source, new KeyExtent(new Text("tab"), null, null), conf,
+    SortedKeyValueIterator<Key,Value> iter = IteratorUtil.loadIterators(IteratorScope.minc, source, new KeyExtent("tab", null, null), conf,
         new DefaultIteratorEnvironment(conf));
     iter.seek(new Range(), EMPTY_COL_FAMS, false);
 

http://git-wip-us.apache.org/repos/asf/accumulo/blob/a14bc292/core/src/test/java/org/apache/accumulo/core/iterators/system/MultiIteratorTest.java
----------------------------------------------------------------------
diff --git a/core/src/test/java/org/apache/accumulo/core/iterators/system/MultiIteratorTest.java b/core/src/test/java/org/apache/accumulo/core/iterators/system/MultiIteratorTest.java
index 3fbf92d..bbf87e5 100644
--- a/core/src/test/java/org/apache/accumulo/core/iterators/system/MultiIteratorTest.java
+++ b/core/src/test/java/org/apache/accumulo/core/iterators/system/MultiIteratorTest.java
@@ -22,8 +22,6 @@ import java.util.Collection;
 import java.util.List;
 import java.util.TreeMap;
 
-import junit.framework.TestCase;
-
 import org.apache.accumulo.core.data.ByteSequence;
 import org.apache.accumulo.core.data.Key;
 import org.apache.accumulo.core.data.Range;
@@ -34,6 +32,8 @@ import org.apache.accumulo.core.iterators.SortedMapIterator;
 import org.apache.accumulo.core.util.LocalityGroupUtil;
 import org.apache.hadoop.io.Text;
 
+import junit.framework.TestCase;
+
 public class MultiIteratorTest extends TestCase {
 
   private static final Collection<ByteSequence> EMPTY_COL_FAMS = new ArrayList<ByteSequence>();
@@ -344,7 +344,7 @@ public class MultiIteratorTest extends TestCase {
     List<SortedKeyValueIterator<Key,Value>> skvil = new ArrayList<SortedKeyValueIterator<Key,Value>>(1);
     skvil.add(new SortedMapIterator(tm1));
 
-    KeyExtent extent = new KeyExtent(new Text("tablename"), nr(1), nr(0));
+    KeyExtent extent = new KeyExtent("tablename", nr(1), nr(0));
     MultiIterator mi = new MultiIterator(skvil, extent);
 
     Range r1 = new Range((Text) null, (Text) null);

http://git-wip-us.apache.org/repos/asf/accumulo/blob/a14bc292/core/src/test/java/org/apache/accumulo/core/replication/ReplicationConfigurationUtilTest.java
----------------------------------------------------------------------
diff --git a/core/src/test/java/org/apache/accumulo/core/replication/ReplicationConfigurationUtilTest.java b/core/src/test/java/org/apache/accumulo/core/replication/ReplicationConfigurationUtilTest.java
index c060917..6d87005 100644
--- a/core/src/test/java/org/apache/accumulo/core/replication/ReplicationConfigurationUtilTest.java
+++ b/core/src/test/java/org/apache/accumulo/core/replication/ReplicationConfigurationUtilTest.java
@@ -46,39 +46,39 @@ public class ReplicationConfigurationUtilTest {
 
   @Test
   public void rootTableExtent() {
-    KeyExtent extent = new KeyExtent(new Text(RootTable.ID), null, null);
+    KeyExtent extent = new KeyExtent(RootTable.ID, null, null);
     Assert.assertFalse("The root table should never be replicated", ReplicationConfigurationUtil.isEnabled(extent, conf));
   }
 
   @Test
   public void metadataTableExtent() {
-    KeyExtent extent = new KeyExtent(new Text(MetadataTable.ID), null, null);
+    KeyExtent extent = new KeyExtent(MetadataTable.ID, null, null);
     Assert.assertFalse("The metadata table should never be replicated", ReplicationConfigurationUtil.isEnabled(extent, conf));
   }
 
   @Test
   public void rootTableExtentEmptyConf() {
-    KeyExtent extent = new KeyExtent(new Text(RootTable.ID), null, null);
+    KeyExtent extent = new KeyExtent(RootTable.ID, null, null);
     Assert.assertFalse("The root table should never be replicated",
         ReplicationConfigurationUtil.isEnabled(extent, new ConfigurationCopy(new HashMap<String,String>())));
   }
 
   @Test
   public void metadataTableExtentEmptyConf() {
-    KeyExtent extent = new KeyExtent(new Text(MetadataTable.ID), null, null);
+    KeyExtent extent = new KeyExtent(MetadataTable.ID, null, null);
     Assert.assertFalse("The metadata table should never be replicated",
         ReplicationConfigurationUtil.isEnabled(extent, new ConfigurationCopy(new HashMap<String,String>())));
   }
 
   @Test
   public void regularTable() {
-    KeyExtent extent = new KeyExtent(new Text("1"), new Text("b"), new Text("a"));
+    KeyExtent extent = new KeyExtent("1", new Text("b"), new Text("a"));
     Assert.assertTrue("Table should be replicated", ReplicationConfigurationUtil.isEnabled(extent, conf));
   }
 
   @Test
   public void regularNonEnabledTable() {
-    KeyExtent extent = new KeyExtent(new Text("1"), new Text("b"), new Text("a"));
+    KeyExtent extent = new KeyExtent("1", new Text("b"), new Text("a"));
     Assert.assertFalse("Table should not be replicated", ReplicationConfigurationUtil.isEnabled(extent, new ConfigurationCopy(new HashMap<String,String>())));
   }
 }

http://git-wip-us.apache.org/repos/asf/accumulo/blob/a14bc292/core/src/test/java/org/apache/accumulo/core/replication/ReplicationSchemaTest.java
----------------------------------------------------------------------
diff --git a/core/src/test/java/org/apache/accumulo/core/replication/ReplicationSchemaTest.java b/core/src/test/java/org/apache/accumulo/core/replication/ReplicationSchemaTest.java
index 3822641..ca5eaa4 100644
--- a/core/src/test/java/org/apache/accumulo/core/replication/ReplicationSchemaTest.java
+++ b/core/src/test/java/org/apache/accumulo/core/replication/ReplicationSchemaTest.java
@@ -61,18 +61,16 @@ public class ReplicationSchemaTest {
 
   @Test
   public void extractTableId() {
-    Text tableId = new Text("1");
-    Key k = new Key(new Text("foo"), StatusSection.NAME, tableId);
-    Assert.assertEquals(tableId.toString(), StatusSection.getTableId(k));
+    String tableId = "1";
+    Key k = new Key(new Text("foo"), StatusSection.NAME, new Text(tableId));
+    Assert.assertEquals(tableId, StatusSection.getTableId(k));
   }
 
   @Test
   public void extractTableIdUsingText() {
-    Text tableId = new Text("1");
-    Key k = new Key(new Text("foo"), StatusSection.NAME, tableId);
-    Text buffer = new Text();
-    StatusSection.getTableId(k, buffer);
-    Assert.assertEquals(tableId.toString(), buffer.toString());
+    String tableId = "1";
+    Key k = new Key(new Text("foo"), StatusSection.NAME, new Text(tableId));
+    Assert.assertEquals(tableId, StatusSection.getTableId(k));
   }
 
   @Test(expected = NullPointerException.class)

http://git-wip-us.apache.org/repos/asf/accumulo/blob/a14bc292/core/src/test/java/org/apache/accumulo/core/util/MergeTest.java
----------------------------------------------------------------------
diff --git a/core/src/test/java/org/apache/accumulo/core/util/MergeTest.java b/core/src/test/java/org/apache/accumulo/core/util/MergeTest.java
index 5b0dc55..6fe240a 100644
--- a/core/src/test/java/org/apache/accumulo/core/util/MergeTest.java
+++ b/core/src/test/java/org/apache/accumulo/core/util/MergeTest.java
@@ -43,7 +43,7 @@ public class MergeTest {
           end = null;
         else
           end = new Text(String.format("%05d", tablets.size()));
-        KeyExtent extent = new KeyExtent(new Text("table"), end, start);
+        KeyExtent extent = new KeyExtent("table", end, start);
         start = end;
         tablets.add(new Size(extent, size));
       }

http://git-wip-us.apache.org/repos/asf/accumulo/blob/a14bc292/examples/simple/src/main/java/org/apache/accumulo/examples/simple/client/RandomBatchWriter.java
----------------------------------------------------------------------
diff --git a/examples/simple/src/main/java/org/apache/accumulo/examples/simple/client/RandomBatchWriter.java b/examples/simple/src/main/java/org/apache/accumulo/examples/simple/client/RandomBatchWriter.java
index 05a737f..610eb5c 100644
--- a/examples/simple/src/main/java/org/apache/accumulo/examples/simple/client/RandomBatchWriter.java
+++ b/examples/simple/src/main/java/org/apache/accumulo/examples/simple/client/RandomBatchWriter.java
@@ -158,10 +158,11 @@ public class RandomBatchWriter {
       if (e.getSecurityErrorCodes().size() > 0) {
         HashMap<String,Set<SecurityErrorCode>> tables = new HashMap<String,Set<SecurityErrorCode>>();
         for (Entry<TabletId,Set<SecurityErrorCode>> ke : e.getSecurityErrorCodes().entrySet()) {
-          Set<SecurityErrorCode> secCodes = tables.get(ke.getKey().getTableId().toString());
+          String tableId = ke.getKey().getTableId().toString();
+          Set<SecurityErrorCode> secCodes = tables.get(tableId);
           if (secCodes == null) {
             secCodes = new HashSet<SecurityErrorCode>();
-            tables.put(ke.getKey().getTableId().toString(), secCodes);
+            tables.put(tableId, secCodes);
           }
           secCodes.addAll(ke.getValue());
         }

http://git-wip-us.apache.org/repos/asf/accumulo/blob/a14bc292/examples/simple/src/main/java/org/apache/accumulo/examples/simple/client/RowOperations.java
----------------------------------------------------------------------
diff --git a/examples/simple/src/main/java/org/apache/accumulo/examples/simple/client/RowOperations.java b/examples/simple/src/main/java/org/apache/accumulo/examples/simple/client/RowOperations.java
index d0898f0..007619d 100644
--- a/examples/simple/src/main/java/org/apache/accumulo/examples/simple/client/RowOperations.java
+++ b/examples/simple/src/main/java/org/apache/accumulo/examples/simple/client/RowOperations.java
@@ -48,7 +48,7 @@ public class RowOperations {
   private static final Logger log = LoggerFactory.getLogger(RowOperations.class);
 
   private static Connector connector;
-  private static String table = "example";
+  private static String tableName = "example";
   private static BatchWriter bw;
 
   public static void main(String[] args) throws AccumuloException, AccumuloSecurityException, TableExistsException, TableNotFoundException,
@@ -63,7 +63,7 @@ public class RowOperations {
     connector = opts.getConnector();
 
     // lets create an example table
-    connector.tableOperations().create(table);
+    connector.tableOperations().create(tableName);
 
     // lets create 3 rows of information
     Text row1 = new Text("row1");
@@ -98,7 +98,7 @@ public class RowOperations {
     mut3.put(new Text("column"), col4, System.currentTimeMillis(), new Value("This is the value for this key".getBytes(UTF_8)));
 
     // Now we'll make a Batch Writer
-    bw = connector.createBatchWriter(table, bwOpts.getBatchWriterConfig());
+    bw = connector.createBatchWriter(tableName, bwOpts.getBatchWriterConfig());
 
     // And add the mutations
     bw.addMutation(mut1);
@@ -160,7 +160,7 @@ public class RowOperations {
     bw.close();
 
     // and lets clean up our mess
-    connector.tableOperations().delete(table);
+    connector.tableOperations().delete(tableName);
 
     // fin~
 
@@ -204,7 +204,7 @@ public class RowOperations {
    */
   private static Scanner getRow(ScannerOpts scanOpts, Text row) throws AccumuloException, AccumuloSecurityException, TableNotFoundException {
     // Create a scanner
-    Scanner scanner = connector.createScanner(table, Authorizations.EMPTY);
+    Scanner scanner = connector.createScanner(tableName, Authorizations.EMPTY);
     scanner.setBatchSize(scanOpts.scanBatchSize);
     // Say start key is the one with key of row
     // and end key is the one that immediately follows the row

http://git-wip-us.apache.org/repos/asf/accumulo/blob/a14bc292/examples/simple/src/main/java/org/apache/accumulo/examples/simple/mapreduce/TeraSortIngest.java
----------------------------------------------------------------------
diff --git a/examples/simple/src/main/java/org/apache/accumulo/examples/simple/mapreduce/TeraSortIngest.java b/examples/simple/src/main/java/org/apache/accumulo/examples/simple/mapreduce/TeraSortIngest.java
index b535513..1005df4 100644
--- a/examples/simple/src/main/java/org/apache/accumulo/examples/simple/mapreduce/TeraSortIngest.java
+++ b/examples/simple/src/main/java/org/apache/accumulo/examples/simple/mapreduce/TeraSortIngest.java
@@ -225,7 +225,7 @@ public class TeraSortIngest extends Configured implements Tool {
    * The Mapper class that given a row number, will generate the appropriate output line.
    */
   public static class SortGenMapper extends Mapper<LongWritable,NullWritable,Text,Mutation> {
-    private Text table = null;
+    private Text tableName = null;
     private int minkeylength = 0;
     private int maxkeylength = 0;
     private int minvaluelength = 0;
@@ -329,7 +329,7 @@ public class TeraSortIngest extends Configured implements Tool {
           new Value(value.toString().getBytes())); // data
 
       context.setStatus("About to add to accumulo");
-      context.write(table, m);
+      context.write(tableName, m);
       context.setStatus("Added to accumulo " + key.toString());
     }
 
@@ -339,7 +339,7 @@ public class TeraSortIngest extends Configured implements Tool {
       maxkeylength = job.getConfiguration().getInt("cloudgen.maxkeylength", 0);
       minvaluelength = job.getConfiguration().getInt("cloudgen.minvaluelength", 0);
       maxvaluelength = job.getConfiguration().getInt("cloudgen.maxvaluelength", 0);
-      table = new Text(job.getConfiguration().get("cloudgen.tablename"));
+      tableName = new Text(job.getConfiguration().get("cloudgen.tablename"));
     }
   }
 

http://git-wip-us.apache.org/repos/asf/accumulo/blob/a14bc292/examples/simple/src/main/java/org/apache/accumulo/examples/simple/shard/ContinuousQuery.java
----------------------------------------------------------------------
diff --git a/examples/simple/src/main/java/org/apache/accumulo/examples/simple/shard/ContinuousQuery.java b/examples/simple/src/main/java/org/apache/accumulo/examples/simple/shard/ContinuousQuery.java
index 00ec5a3..6f0ceac 100644
--- a/examples/simple/src/main/java/org/apache/accumulo/examples/simple/shard/ContinuousQuery.java
+++ b/examples/simple/src/main/java/org/apache/accumulo/examples/simple/shard/ContinuousQuery.java
@@ -49,7 +49,7 @@ public class ContinuousQuery {
 
   static class Opts extends ClientOpts {
     @Parameter(names = "--shardTable", required = true, description = "name of the shard table")
-    String table = null;
+    String tableName = null;
     @Parameter(names = "--doc2Term", required = true, description = "name of the doc2Term table")
     String doc2Term;
     @Parameter(names = "--terms", required = true, description = "the number of terms in the query")
@@ -69,7 +69,7 @@ public class ContinuousQuery {
 
     Random rand = new Random();
 
-    BatchScanner bs = conn.createBatchScanner(opts.table, opts.auths, bsOpts.scanThreads);
+    BatchScanner bs = conn.createBatchScanner(opts.tableName, opts.auths, bsOpts.scanThreads);
     bs.setTimeout(bsOpts.scanTimeout, TimeUnit.MILLISECONDS);
 
     for (long i = 0; i < opts.iterations; i += 1) {

http://git-wip-us.apache.org/repos/asf/accumulo/blob/a14bc292/server/base/src/main/java/org/apache/accumulo/server/client/BulkImporter.java
----------------------------------------------------------------------
diff --git a/server/base/src/main/java/org/apache/accumulo/server/client/BulkImporter.java b/server/base/src/main/java/org/apache/accumulo/server/client/BulkImporter.java
index 7b1bfde..2656d4b 100644
--- a/server/base/src/main/java/org/apache/accumulo/server/client/BulkImporter.java
+++ b/server/base/src/main/java/org/apache/accumulo/server/client/BulkImporter.java
@@ -129,7 +129,7 @@ public class BulkImporter {
     final Map<Path,List<KeyExtent>> completeFailures = Collections.synchronizedSortedMap(new TreeMap<Path,List<KeyExtent>>());
 
     ClientService.Client client = null;
-    final TabletLocator locator = TabletLocator.getLocator(context, new Text(tableId));
+    final TabletLocator locator = TabletLocator.getLocator(context, tableId);
 
     try {
       final Map<Path,List<TabletLocation>> assignments = Collections.synchronizedSortedMap(new TreeMap<Path,List<TabletLocation>>());

http://git-wip-us.apache.org/repos/asf/accumulo/blob/a14bc292/server/base/src/main/java/org/apache/accumulo/server/conf/ServerConfigurationFactory.java
----------------------------------------------------------------------
diff --git a/server/base/src/main/java/org/apache/accumulo/server/conf/ServerConfigurationFactory.java b/server/base/src/main/java/org/apache/accumulo/server/conf/ServerConfigurationFactory.java
index 6976bab..2995fc8 100644
--- a/server/base/src/main/java/org/apache/accumulo/server/conf/ServerConfigurationFactory.java
+++ b/server/base/src/main/java/org/apache/accumulo/server/conf/ServerConfigurationFactory.java
@@ -177,7 +177,7 @@ public class ServerConfigurationFactory extends ServerConfiguration {
 
   @Override
   public TableConfiguration getTableConfiguration(KeyExtent extent) {
-    return getTableConfiguration(extent.getTableId().toString());
+    return getTableConfiguration(extent.getTableId());
   }
 
   public NamespaceConfiguration getNamespaceConfigurationForTable(String tableId) {

http://git-wip-us.apache.org/repos/asf/accumulo/blob/a14bc292/server/base/src/main/java/org/apache/accumulo/server/conf/TableConfiguration.java
----------------------------------------------------------------------
diff --git a/server/base/src/main/java/org/apache/accumulo/server/conf/TableConfiguration.java b/server/base/src/main/java/org/apache/accumulo/server/conf/TableConfiguration.java
index 915122b..d4712b9 100644
--- a/server/base/src/main/java/org/apache/accumulo/server/conf/TableConfiguration.java
+++ b/server/base/src/main/java/org/apache/accumulo/server/conf/TableConfiguration.java
@@ -42,11 +42,11 @@ public class TableConfiguration extends ObservableConfiguration {
   private final NamespaceConfiguration parent;
   private ZooCacheFactory zcf = new ZooCacheFactory();
 
-  private final String table;
+  private final String tableId;
 
-  public TableConfiguration(Instance instance, String table, NamespaceConfiguration parent) {
+  public TableConfiguration(Instance instance, String tableId, NamespaceConfiguration parent) {
     this.instance = instance;
-    this.table = table;
+    this.tableId = tableId;
     this.parent = parent;
   }
 
@@ -57,7 +57,7 @@ public class TableConfiguration extends ObservableConfiguration {
   private synchronized ZooCachePropertyAccessor getPropCacheAccessor() {
     if (propCacheAccessor == null) {
       synchronized (propCaches) {
-        PropCacheKey key = new PropCacheKey(instance.getInstanceID(), table);
+        PropCacheKey key = new PropCacheKey(instance.getInstanceID(), tableId);
         ZooCache propCache = propCaches.get(key);
         if (propCache == null) {
           propCache = zcf.getZooCache(instance.getZooKeepers(), instance.getZooKeepersSessionTimeOut(), new TableConfWatcher(instance));
@@ -71,7 +71,7 @@ public class TableConfiguration extends ObservableConfiguration {
 
   @Override
   public void addObserver(ConfigurationObserver co) {
-    if (table == null) {
+    if (tableId == null) {
       String err = "Attempt to add observer for non-table configuration";
       log.error(err);
       throw new RuntimeException(err);
@@ -82,7 +82,7 @@ public class TableConfiguration extends ObservableConfiguration {
 
   @Override
   public void removeObserver(ConfigurationObserver co) {
-    if (table == null) {
+    if (tableId == null) {
       String err = "Attempt to remove observer for non-table configuration";
       log.error(err);
       throw new RuntimeException(err);
@@ -91,7 +91,7 @@ public class TableConfiguration extends ObservableConfiguration {
   }
 
   private String getPath() {
-    return ZooUtil.getRoot(instance.getInstanceID()) + Constants.ZTABLES + "/" + table + Constants.ZTABLE_CONF;
+    return ZooUtil.getRoot(instance.getInstanceID()) + Constants.ZTABLES + "/" + tableId + Constants.ZTABLE_CONF;
   }
 
   @Override
@@ -105,7 +105,7 @@ public class TableConfiguration extends ObservableConfiguration {
   }
 
   public String getTableId() {
-    return table;
+    return tableId;
   }
 
   /**

http://git-wip-us.apache.org/repos/asf/accumulo/blob/a14bc292/server/base/src/main/java/org/apache/accumulo/server/fs/VolumeUtil.java
----------------------------------------------------------------------
diff --git a/server/base/src/main/java/org/apache/accumulo/server/fs/VolumeUtil.java b/server/base/src/main/java/org/apache/accumulo/server/fs/VolumeUtil.java
index 427d2c9..0c3092b 100644
--- a/server/base/src/main/java/org/apache/accumulo/server/fs/VolumeUtil.java
+++ b/server/base/src/main/java/org/apache/accumulo/server/fs/VolumeUtil.java
@@ -264,7 +264,7 @@ public class VolumeUtil {
       throw new IllegalArgumentException("Unexpected table dir " + dir);
     }
 
-    Path newDir = new Path(vm.choose(Optional.of(extent.getTableId().toString()), ServerConstants.getBaseUris()) + Path.SEPARATOR + ServerConstants.TABLE_DIR
+    Path newDir = new Path(vm.choose(Optional.of(extent.getTableId()), ServerConstants.getBaseUris()) + Path.SEPARATOR + ServerConstants.TABLE_DIR
         + Path.SEPARATOR + dir.getParent().getName() + Path.SEPARATOR + dir.getName());
 
     log.info("Updating directory for " + extent + " from " + dir + " to " + newDir);

http://git-wip-us.apache.org/repos/asf/accumulo/blob/a14bc292/server/base/src/main/java/org/apache/accumulo/server/init/Initialize.java
----------------------------------------------------------------------
diff --git a/server/base/src/main/java/org/apache/accumulo/server/init/Initialize.java b/server/base/src/main/java/org/apache/accumulo/server/init/Initialize.java
index 78fc66d..4378f2c 100644
--- a/server/base/src/main/java/org/apache/accumulo/server/init/Initialize.java
+++ b/server/base/src/main/java/org/apache/accumulo/server/init/Initialize.java
@@ -477,7 +477,7 @@ public class Initialize implements KeywordExecutable {
 
   private static void createEntriesForTablet(TreeMap<Key,Value> map, Tablet tablet) {
     Value EMPTY_SIZE = new DataFileValue(0, 0).encodeAsValue();
-    Text extent = new Text(KeyExtent.getMetadataEntry(new Text(tablet.tableId), tablet.endRow));
+    Text extent = new Text(KeyExtent.getMetadataEntry(tablet.tableId, tablet.endRow));
     addEntry(map, extent, DIRECTORY_COLUMN, new Value(tablet.dir.getBytes(UTF_8)));
     addEntry(map, extent, TIME_COLUMN, new Value((TabletTime.LOGICAL_TIME_ID + "0").getBytes(UTF_8)));
     addEntry(map, extent, PREV_ROW_COLUMN, KeyExtent.encodePrevEndRow(tablet.prevEndRow));

http://git-wip-us.apache.org/repos/asf/accumulo/blob/a14bc292/server/base/src/main/java/org/apache/accumulo/server/master/balancer/GroupBalancer.java
----------------------------------------------------------------------
diff --git a/server/base/src/main/java/org/apache/accumulo/server/master/balancer/GroupBalancer.java b/server/base/src/main/java/org/apache/accumulo/server/master/balancer/GroupBalancer.java
index 2ea8e71..b2b2ed5 100644
--- a/server/base/src/main/java/org/apache/accumulo/server/master/balancer/GroupBalancer.java
+++ b/server/base/src/main/java/org/apache/accumulo/server/master/balancer/GroupBalancer.java
@@ -48,7 +48,6 @@ import org.apache.accumulo.core.util.Pair;
 import org.apache.accumulo.server.master.state.TServerInstance;
 import org.apache.accumulo.server.master.state.TabletMigration;
 import org.apache.commons.lang.mutable.MutableInt;
-import org.apache.hadoop.io.Text;
 
 import com.google.common.base.Function;
 import com.google.common.collect.HashBasedTable;
@@ -72,7 +71,6 @@ import com.google.common.collect.Table;
 public abstract class GroupBalancer extends TabletBalancer {
 
   private final String tableId;
-  private final Text textTableId;
   private long lastRun = 0;
 
   /**
@@ -82,7 +80,6 @@ public abstract class GroupBalancer extends TabletBalancer {
 
   public GroupBalancer(String tableId) {
     this.tableId = tableId;
-    this.textTableId = new Text(tableId);
   }
 
   protected Iterable<Pair<KeyExtent,Location>> getLocationProvider() {
@@ -113,7 +110,7 @@ public abstract class GroupBalancer extends TabletBalancer {
     }
 
     for (KeyExtent keyExtent : migrations) {
-      if (keyExtent.getTableId().equals(textTableId)) {
+      if (keyExtent.getTableId().equals(tableId)) {
         return false;
       }
     }

http://git-wip-us.apache.org/repos/asf/accumulo/blob/a14bc292/server/base/src/main/java/org/apache/accumulo/server/master/balancer/TableLoadBalancer.java
----------------------------------------------------------------------
diff --git a/server/base/src/main/java/org/apache/accumulo/server/master/balancer/TableLoadBalancer.java b/server/base/src/main/java/org/apache/accumulo/server/master/balancer/TableLoadBalancer.java
index 7d76572..4bae545 100644
--- a/server/base/src/main/java/org/apache/accumulo/server/master/balancer/TableLoadBalancer.java
+++ b/server/base/src/main/java/org/apache/accumulo/server/master/balancer/TableLoadBalancer.java
@@ -116,10 +116,10 @@ public class TableLoadBalancer extends TabletBalancer {
     // separate the unassigned into tables
     Map<String,Map<KeyExtent,TServerInstance>> groupedUnassigned = new HashMap<String,Map<KeyExtent,TServerInstance>>();
     for (Entry<KeyExtent,TServerInstance> e : unassigned.entrySet()) {
-      Map<KeyExtent,TServerInstance> tableUnassigned = groupedUnassigned.get(e.getKey().getTableId().toString());
+      Map<KeyExtent,TServerInstance> tableUnassigned = groupedUnassigned.get(e.getKey().getTableId());
       if (tableUnassigned == null) {
         tableUnassigned = new HashMap<KeyExtent,TServerInstance>();
-        groupedUnassigned.put(e.getKey().getTableId().toString(), tableUnassigned);
+        groupedUnassigned.put(e.getKey().getTableId(), tableUnassigned);
       }
       tableUnassigned.put(e.getKey(), e.getValue());
     }

http://git-wip-us.apache.org/repos/asf/accumulo/blob/a14bc292/server/base/src/main/java/org/apache/accumulo/server/master/state/TabletStateChangeIterator.java
----------------------------------------------------------------------
diff --git a/server/base/src/main/java/org/apache/accumulo/server/master/state/TabletStateChangeIterator.java b/server/base/src/main/java/org/apache/accumulo/server/master/state/TabletStateChangeIterator.java
index 236b602..26d98a8 100644
--- a/server/base/src/main/java/org/apache/accumulo/server/master/state/TabletStateChangeIterator.java
+++ b/server/base/src/main/java/org/apache/accumulo/server/master/state/TabletStateChangeIterator.java
@@ -42,7 +42,6 @@ import org.apache.accumulo.core.util.Base64;
 import org.apache.accumulo.server.master.state.TabletLocationState.BadLocationStateException;
 import org.apache.hadoop.io.DataInputBuffer;
 import org.apache.hadoop.io.DataOutputBuffer;
-import org.apache.hadoop.io.Text;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
@@ -61,7 +60,7 @@ public class TabletStateChangeIterator extends SkippingIterator {
 
   private Set<TServerInstance> current;
   private Set<String> onlineTables;
-  private Map<Text,MergeInfo> merges;
+  private Map<String,MergeInfo> merges;
   private boolean debug = false;
   private Set<KeyExtent> migrations;
   private MasterState masterState = MasterState.NORMAL;
@@ -133,11 +132,11 @@ public class TabletStateChangeIterator extends SkippingIterator {
     return result;
   }
 
-  private Map<Text,MergeInfo> parseMerges(String merges) {
+  private Map<String,MergeInfo> parseMerges(String merges) {
     if (merges == null)
       return null;
     try {
-      Map<Text,MergeInfo> result = new HashMap<Text,MergeInfo>();
+      Map<String,MergeInfo> result = new HashMap<String,MergeInfo>();
       DataInputBuffer buffer = new DataInputBuffer();
       byte[] data = Base64.decodeBase64(merges.getBytes(UTF_8));
       buffer.reset(data, data.length);
@@ -182,7 +181,7 @@ public class TabletStateChangeIterator extends SkippingIterator {
       }
 
       // is the table supposed to be online or offline?
-      boolean shouldBeOnline = onlineTables.contains(tls.extent.getTableId().toString());
+      boolean shouldBeOnline = onlineTables.contains(tls.extent.getTableId());
 
       if (debug) {
         log.debug(tls.extent + " is " + tls.getState(current) + " and should be " + (shouldBeOnline ? "on" : "off") + "line");

http://git-wip-us.apache.org/repos/asf/accumulo/blob/a14bc292/server/base/src/main/java/org/apache/accumulo/server/problems/ProblemReport.java
----------------------------------------------------------------------
diff --git a/server/base/src/main/java/org/apache/accumulo/server/problems/ProblemReport.java b/server/base/src/main/java/org/apache/accumulo/server/problems/ProblemReport.java
index 4dc1eed..8685034 100644
--- a/server/base/src/main/java/org/apache/accumulo/server/problems/ProblemReport.java
+++ b/server/base/src/main/java/org/apache/accumulo/server/problems/ProblemReport.java
@@ -44,18 +44,18 @@ import org.apache.hadoop.io.Text;
 import org.apache.zookeeper.KeeperException;
 
 public class ProblemReport {
-  private String tableName;
+  private String tableId;
   private ProblemType problemType;
   private String resource;
   private String exception;
   private String server;
   private long creationTime;
 
-  public ProblemReport(String table, ProblemType problemType, String resource, String server, Throwable e, long creationTime) {
-    requireNonNull(table, "table is null");
+  public ProblemReport(String tableId, ProblemType problemType, String resource, String server, Throwable e, long creationTime) {
+    requireNonNull(tableId, "tableId is null");
     requireNonNull(problemType, "problemType is null");
     requireNonNull(resource, "resource is null");
-    this.tableName = table;
+    this.tableId = tableId;
 
     this.problemType = problemType;
     this.resource = resource;
@@ -76,19 +76,19 @@ public class ProblemReport {
     this.creationTime = creationTime;
   }
 
-  public ProblemReport(String table, ProblemType problemType, String resource, String server, Throwable e) {
-    this(table, problemType, resource, server, e, System.currentTimeMillis());
+  public ProblemReport(String tableId, ProblemType problemType, String resource, String server, Throwable e) {
+    this(tableId, problemType, resource, server, e, System.currentTimeMillis());
   }
 
-  public ProblemReport(String table, ProblemType problemType, String resource, Throwable e) {
-    this(table, problemType, resource, null, e);
+  public ProblemReport(String tableId, ProblemType problemType, String resource, Throwable e) {
+    this(tableId, problemType, resource, null, e);
   }
 
   private ProblemReport(String table, ProblemType problemType, String resource, byte enc[]) throws IOException {
     requireNonNull(table, "table is null");
     requireNonNull(problemType, "problemType is null");
     requireNonNull(resource, "resource is null");
-    this.tableName = table;
+    this.tableId = table;
     this.problemType = problemType;
     this.resource = resource;
 
@@ -137,13 +137,13 @@ public class ProblemReport {
   }
 
   void removeFromMetadataTable(AccumuloServerContext context) throws Exception {
-    Mutation m = new Mutation(new Text("~err_" + tableName));
+    Mutation m = new Mutation(new Text("~err_" + tableId));
     m.putDelete(new Text(problemType.name()), new Text(resource));
     MetadataTableUtil.getMetadataTable(context).update(m);
   }
 
   void saveToMetadataTable(AccumuloServerContext context) throws Exception {
-    Mutation m = new Mutation(new Text("~err_" + tableName));
+    Mutation m = new Mutation(new Text("~err_" + tableId));
     m.put(new Text(problemType.name()), new Text(resource), new Value(encode()));
     MetadataTableUtil.getMetadataTable(context).update(m);
   }
@@ -188,27 +188,27 @@ public class ProblemReport {
     ByteArrayInputStream bais = new ByteArrayInputStream(bytes);
     DataInputStream dis = new DataInputStream(bais);
 
-    String tableName = dis.readUTF();
+    String tableId = dis.readUTF();
     String problemType = dis.readUTF();
     String resource = dis.readUTF();
 
     String zpath = ZooUtil.getRoot(instance) + Constants.ZPROBLEMS + "/" + node;
     byte[] enc = zoorw.getData(zpath, null);
 
-    return new ProblemReport(tableName, ProblemType.valueOf(problemType), resource, enc);
+    return new ProblemReport(tableId, ProblemType.valueOf(problemType), resource, enc);
 
   }
 
   public static ProblemReport decodeMetadataEntry(Entry<Key,Value> entry) throws IOException {
-    String tableName = entry.getKey().getRow().toString().substring("~err_".length());
+    String tableId = entry.getKey().getRow().toString().substring("~err_".length());
     String problemType = entry.getKey().getColumnFamily().toString();
     String resource = entry.getKey().getColumnQualifier().toString();
 
-    return new ProblemReport(tableName, ProblemType.valueOf(problemType), resource, entry.getValue().get());
+    return new ProblemReport(tableId, ProblemType.valueOf(problemType), resource, entry.getValue().get());
   }
 
   public String getTableName() {
-    return tableName;
+    return tableId;
   }
 
   public ProblemType getProblemType() {
@@ -233,14 +233,14 @@ public class ProblemReport {
 
   @Override
   public int hashCode() {
-    return tableName.hashCode() + problemType.hashCode() + resource.hashCode();
+    return tableId.hashCode() + problemType.hashCode() + resource.hashCode();
   }
 
   @Override
   public boolean equals(Object o) {
     if (o instanceof ProblemReport) {
       ProblemReport opr = (ProblemReport) o;
-      return tableName.equals(opr.tableName) && problemType.equals(opr.problemType) && resource.equals(opr.resource);
+      return tableId.equals(opr.tableId) && problemType.equals(opr.problemType) && resource.equals(opr.resource);
     }
     return false;
   }

http://git-wip-us.apache.org/repos/asf/accumulo/blob/a14bc292/server/base/src/main/java/org/apache/accumulo/server/problems/ProblemReportingIterator.java
----------------------------------------------------------------------
diff --git a/server/base/src/main/java/org/apache/accumulo/server/problems/ProblemReportingIterator.java b/server/base/src/main/java/org/apache/accumulo/server/problems/ProblemReportingIterator.java
index 349ed20..83b4615 100644
--- a/server/base/src/main/java/org/apache/accumulo/server/problems/ProblemReportingIterator.java
+++ b/server/base/src/main/java/org/apache/accumulo/server/problems/ProblemReportingIterator.java
@@ -35,13 +35,13 @@ public class ProblemReportingIterator implements InterruptibleIterator {
   private boolean sawError = false;
   private boolean continueOnError;
   private String resource;
-  private String table;
+  private String tableId;
   private final AccumuloServerContext context;
 
-  public ProblemReportingIterator(AccumuloServerContext context, String table, String resource, boolean continueOnError,
+  public ProblemReportingIterator(AccumuloServerContext context, String tableId, String resource, boolean continueOnError,
       SortedKeyValueIterator<Key,Value> source) {
     this.context = context;
-    this.table = table;
+    this.tableId = tableId;
     this.resource = resource;
     this.continueOnError = continueOnError;
     this.source = source;
@@ -49,7 +49,7 @@ public class ProblemReportingIterator implements InterruptibleIterator {
 
   @Override
   public SortedKeyValueIterator<Key,Value> deepCopy(IteratorEnvironment env) {
-    return new ProblemReportingIterator(context, table, resource, continueOnError, source.deepCopy(env));
+    return new ProblemReportingIterator(context, tableId, resource, continueOnError, source.deepCopy(env));
   }
 
   @Override
@@ -81,7 +81,7 @@ public class ProblemReportingIterator implements InterruptibleIterator {
       source.next();
     } catch (IOException ioe) {
       sawError = true;
-      ProblemReports.getInstance(context).report(new ProblemReport(table, ProblemType.FILE_READ, resource, ioe));
+      ProblemReports.getInstance(context).report(new ProblemReport(tableId, ProblemType.FILE_READ, resource, ioe));
       if (!continueOnError) {
         throw ioe;
       }
@@ -98,7 +98,7 @@ public class ProblemReportingIterator implements InterruptibleIterator {
       source.seek(range, columnFamilies, inclusive);
     } catch (IOException ioe) {
       sawError = true;
-      ProblemReports.getInstance(context).report(new ProblemReport(table, ProblemType.FILE_READ, resource, ioe));
+      ProblemReports.getInstance(context).report(new ProblemReport(tableId, ProblemType.FILE_READ, resource, ioe));
       if (!continueOnError) {
         throw ioe;
       }

http://git-wip-us.apache.org/repos/asf/accumulo/blob/a14bc292/server/base/src/main/java/org/apache/accumulo/server/tabletserver/LargestFirstMemoryManager.java
----------------------------------------------------------------------
diff --git a/server/base/src/main/java/org/apache/accumulo/server/tabletserver/LargestFirstMemoryManager.java b/server/base/src/main/java/org/apache/accumulo/server/tabletserver/LargestFirstMemoryManager.java
index e49e1af..176b247 100644
--- a/server/base/src/main/java/org/apache/accumulo/server/tabletserver/LargestFirstMemoryManager.java
+++ b/server/base/src/main/java/org/apache/accumulo/server/tabletserver/LargestFirstMemoryManager.java
@@ -28,7 +28,6 @@ import org.apache.accumulo.core.client.impl.Tables;
 import org.apache.accumulo.core.conf.Property;
 import org.apache.accumulo.core.data.impl.KeyExtent;
 import org.apache.accumulo.server.conf.ServerConfiguration;
-import org.apache.hadoop.io.Text;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
@@ -52,7 +51,7 @@ public class LargestFirstMemoryManager implements MemoryManager {
   // The fraction of memory that needs to be used before we begin flushing.
   private double compactionThreshold;
   private long maxObserved;
-  private final HashMap<Text,Long> mincIdleThresholds = new HashMap<Text,Long>();
+  private final HashMap<String,Long> mincIdleThresholds = new HashMap<String,Long>();
   private ServerConfiguration config = null;
 
   private static class TabletInfo {
@@ -140,9 +139,9 @@ public class LargestFirstMemoryManager implements MemoryManager {
   }
 
   protected long getMinCIdleThreshold(KeyExtent extent) {
-    Text tableId = extent.getTableId();
+    String tableId = extent.getTableId();
     if (!mincIdleThresholds.containsKey(tableId))
-      mincIdleThresholds.put(tableId, config.getTableConfiguration(tableId.toString()).getTimeInMillis(Property.TABLE_MINC_COMPACT_IDLETIME));
+      mincIdleThresholds.put(tableId, config.getTableConfiguration(tableId).getTimeInMillis(Property.TABLE_MINC_COMPACT_IDLETIME));
     return mincIdleThresholds.get(tableId);
   }
 
@@ -173,7 +172,7 @@ public class LargestFirstMemoryManager implements MemoryManager {
     // find the largest and most idle tablets
     for (TabletState ts : tablets) {
       // Make sure that the table still exists
-      if (!tableExists(instance, ts.getExtent().getTableId().toString())) {
+      if (!tableExists(instance, ts.getExtent().getTableId())) {
         log.trace("Ignoring extent for deleted table: {}", ts.getExtent());
         continue;
       }

http://git-wip-us.apache.org/repos/asf/accumulo/blob/a14bc292/server/base/src/main/java/org/apache/accumulo/server/util/Admin.java
----------------------------------------------------------------------
diff --git a/server/base/src/main/java/org/apache/accumulo/server/util/Admin.java b/server/base/src/main/java/org/apache/accumulo/server/util/Admin.java
index 9a8f6ed..d43ce92 100644
--- a/server/base/src/main/java/org/apache/accumulo/server/util/Admin.java
+++ b/server/base/src/main/java/org/apache/accumulo/server/util/Admin.java
@@ -105,7 +105,7 @@ public class Admin implements KeywordExecutable {
     boolean fixFiles = false;
 
     @Parameter(names = {"-t", "--table"}, description = "Table to check, if not set checks all tables")
-    String table = null;
+    String tableName = null;
   }
 
   @Parameters(commandDescription = "stop the master")
@@ -147,7 +147,7 @@ public class Admin implements KeywordExecutable {
   @Parameters(commandDescription = "redistribute tablet directories across the current volume list")
   static class RandomizeVolumesCommand {
     @Parameter(names = {"-t"}, description = "table to update", required = true)
-    String table = null;
+    String tableName = null;
   }
 
   public static void main(String[] args) {
@@ -231,14 +231,14 @@ public class Admin implements KeywordExecutable {
           rc = 4;
       } else if (cl.getParsedCommand().equals("checkTablets")) {
         System.out.println("\n*** Looking for offline tablets ***\n");
-        if (FindOfflineTablets.findOffline(context, checkTabletsCommand.table) != 0)
+        if (FindOfflineTablets.findOffline(context, checkTabletsCommand.tableName) != 0)
           rc = 5;
         System.out.println("\n*** Looking for missing files ***\n");
-        if (checkTabletsCommand.table == null) {
+        if (checkTabletsCommand.tableName == null) {
           if (RemoveEntriesForMissingFiles.checkAllTables(context, checkTabletsCommand.fixFiles) != 0)
             rc = 6;
         } else {
-          if (RemoveEntriesForMissingFiles.checkTable(context, checkTabletsCommand.table, checkTabletsCommand.fixFiles) != 0)
+          if (RemoveEntriesForMissingFiles.checkTable(context, checkTabletsCommand.tableName, checkTabletsCommand.fixFiles) != 0)
             rc = 6;
         }
 
@@ -249,7 +249,7 @@ public class Admin implements KeywordExecutable {
       } else if (cl.getParsedCommand().equals("volumes")) {
         ListVolumesUsed.listVolumes(context);
       } else if (cl.getParsedCommand().equals("randomizeVolumes")) {
-        rc = RandomizeVolumes.randomize(context.getConnector(), randomizeVolumesOpts.table);
+        rc = RandomizeVolumes.randomize(context.getConnector(), randomizeVolumesOpts.tableName);
       } else {
         everything = cl.getParsedCommand().equals("stopAll");
 

http://git-wip-us.apache.org/repos/asf/accumulo/blob/a14bc292/server/base/src/main/java/org/apache/accumulo/server/util/CheckForMetadataProblems.java
----------------------------------------------------------------------
diff --git a/server/base/src/main/java/org/apache/accumulo/server/util/CheckForMetadataProblems.java b/server/base/src/main/java/org/apache/accumulo/server/util/CheckForMetadataProblems.java
index b081a60..867cd67 100644
--- a/server/base/src/main/java/org/apache/accumulo/server/util/CheckForMetadataProblems.java
+++ b/server/base/src/main/java/org/apache/accumulo/server/util/CheckForMetadataProblems.java
@@ -112,7 +112,7 @@ public class CheckForMetadataProblems {
 
       count++;
 
-      String tableName = (new KeyExtent(entry.getKey().getRow(), (Text) null)).getTableId().toString();
+      String tableName = (new KeyExtent(entry.getKey().getRow(), (Text) null)).getTableId();
 
       TreeSet<KeyExtent> tablets = tables.get(tableName);
       if (tablets == null) {

http://git-wip-us.apache.org/repos/asf/accumulo/blob/a14bc292/server/base/src/main/java/org/apache/accumulo/server/util/FindOfflineTablets.java
----------------------------------------------------------------------
diff --git a/server/base/src/main/java/org/apache/accumulo/server/util/FindOfflineTablets.java b/server/base/src/main/java/org/apache/accumulo/server/util/FindOfflineTablets.java
index 1db53a4..98101ec 100644
--- a/server/base/src/main/java/org/apache/accumulo/server/util/FindOfflineTablets.java
+++ b/server/base/src/main/java/org/apache/accumulo/server/util/FindOfflineTablets.java
@@ -42,7 +42,6 @@ import org.apache.accumulo.server.master.state.TabletLocationState;
 import org.apache.accumulo.server.master.state.TabletState;
 import org.apache.accumulo.server.master.state.ZooTabletStateStore;
 import org.apache.accumulo.server.tables.TableManager;
-import org.apache.hadoop.io.Text;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
@@ -101,7 +100,7 @@ public class FindOfflineTablets {
     Range range = MetadataSchema.TabletsSection.getRange();
     if (tableName != null) {
       String tableId = Tables.getTableId(context.getInstance(), tableName);
-      range = new KeyExtent(new Text(tableId), null, null).toMetadataRange();
+      range = new KeyExtent(tableId, null, null).toMetadataRange();
     }
 
     MetaDataTableScanner metaScanner = new MetaDataTableScanner(context, range, MetadataTable.NAME);
@@ -118,8 +117,7 @@ public class FindOfflineTablets {
     while (scanner.hasNext() && !System.out.checkError()) {
       TabletLocationState locationState = scanner.next();
       TabletState state = locationState.getState(tservers.getCurrentServers());
-      if (state != null && state != TabletState.HOSTED
-          && TableManager.getInstance().getTableState(locationState.extent.getTableId().toString()) != TableState.OFFLINE) {
+      if (state != null && state != TabletState.HOSTED && TableManager.getInstance().getTableState(locationState.extent.getTableId()) != TableState.OFFLINE) {
         System.out.println(locationState + " is " + state + "  #walogs:" + locationState.walogs.size());
         offline++;
       }

http://git-wip-us.apache.org/repos/asf/accumulo/blob/a14bc292/server/base/src/main/java/org/apache/accumulo/server/util/MasterMetadataUtil.java
----------------------------------------------------------------------
diff --git a/server/base/src/main/java/org/apache/accumulo/server/util/MasterMetadataUtil.java b/server/base/src/main/java/org/apache/accumulo/server/util/MasterMetadataUtil.java
index 5d84ee4..b9e52e3 100644
--- a/server/base/src/main/java/org/apache/accumulo/server/util/MasterMetadataUtil.java
+++ b/server/base/src/main/java/org/apache/accumulo/server/util/MasterMetadataUtil.java
@@ -136,12 +136,12 @@ public class MasterMetadataUtil {
 
     Text metadataPrevEndRow = KeyExtent.decodePrevEndRow(prevEndRowIBW);
 
-    Text table = (new KeyExtent(metadataEntry, (Text) null)).getTableId();
+    String table = (new KeyExtent(metadataEntry, (Text) null)).getTableId();
 
     return fixSplit(context, table, metadataEntry, metadataPrevEndRow, oper, splitRatio, tserver, time.toString(), initFlushID, initCompactID, lock);
   }
 
-  private static KeyExtent fixSplit(ClientContext context, Text table, Text metadataEntry, Text metadataPrevEndRow, Value oper, double splitRatio,
+  private static KeyExtent fixSplit(ClientContext context, String table, Text metadataEntry, Text metadataPrevEndRow, Value oper, double splitRatio,
       TServerInstance tserver, String time, long initFlushID, long initCompactID, ZooLock lock) throws AccumuloException, IOException {
     if (metadataPrevEndRow == null)
       // something is wrong, this should not happen... if a tablet is split, it will always have a

http://git-wip-us.apache.org/repos/asf/accumulo/blob/a14bc292/server/base/src/main/java/org/apache/accumulo/server/util/MetadataTableUtil.java
----------------------------------------------------------------------
diff --git a/server/base/src/main/java/org/apache/accumulo/server/util/MetadataTableUtil.java b/server/base/src/main/java/org/apache/accumulo/server/util/MetadataTableUtil.java
index 4b88c5b..5081a9c 100644
--- a/server/base/src/main/java/org/apache/accumulo/server/util/MetadataTableUtil.java
+++ b/server/base/src/main/java/org/apache/accumulo/server/util/MetadataTableUtil.java
@@ -343,7 +343,7 @@ public class MetadataTableUtil {
 
   public static void addDeleteEntries(KeyExtent extent, Set<FileRef> datafilesToDelete, ClientContext context) throws IOException {
 
-    String tableId = extent.getTableId().toString();
+    String tableId = extent.getTableId();
 
     // TODO could use batch writer,would need to handle failure and retry like update does - ACCUMULO-1294
     for (FileRef pathToRemove : datafilesToDelete) {
@@ -352,7 +352,7 @@ public class MetadataTableUtil {
   }
 
   public static void addDeleteEntry(AccumuloServerContext context, String tableId, String path) throws IOException {
-    update(context, createDeleteMutation(tableId, path), new KeyExtent(new Text(tableId), null, null));
+    update(context, createDeleteMutation(tableId, path), new KeyExtent(tableId, null, null));
   }
 
   public static Mutation createDeleteMutation(String tableId, String pathToRemove) throws IOException {
@@ -371,7 +371,7 @@ public class MetadataTableUtil {
     update(context, zooLock, m, extent);
   }
 
-  public static void splitDatafiles(Text table, Text midRow, double splitRatio, Map<FileRef,FileUtil.FileInfo> firstAndLastRows,
+  public static void splitDatafiles(String tableId, Text midRow, double splitRatio, Map<FileRef,FileUtil.FileInfo> firstAndLastRows,
       SortedMap<FileRef,DataFileValue> datafiles, SortedMap<FileRef,DataFileValue> lowDatafileSizes, SortedMap<FileRef,DataFileValue> highDatafileSizes,
       List<FileRef> highDatafilesToRemove) {
 
@@ -416,13 +416,12 @@ public class MetadataTableUtil {
 
   public static void deleteTable(String tableId, boolean insertDeletes, ClientContext context, ZooLock lock) throws AccumuloException, IOException {
     Scanner ms = new ScannerImpl(context, MetadataTable.ID, Authorizations.EMPTY);
-    Text tableIdText = new Text(tableId);
     BatchWriter bw = new BatchWriterImpl(context, MetadataTable.ID, new BatchWriterConfig().setMaxMemory(1000000).setMaxLatency(120000l, TimeUnit.MILLISECONDS)
         .setMaxWriteThreads(2));
 
     // scan metadata for our table and delete everything we find
     Mutation m = null;
-    ms.setRange(new KeyExtent(tableIdText, null, null).toMetadataRange());
+    ms.setRange(new KeyExtent(tableId, null, null).toMetadataRange());
 
     // insert deletes before deleting data from metadata... this makes the code fault tolerant
     if (insertDeletes) {
@@ -612,7 +611,7 @@ public class MetadataTableUtil {
 
     LogEntryIterator(ClientContext context) throws IOException, KeeperException, InterruptedException {
       zookeeperEntries = getLogEntries(context, RootTable.EXTENT).iterator();
-      rootTableEntries = getLogEntries(context, new KeyExtent(new Text(MetadataTable.ID), null, null)).iterator();
+      rootTableEntries = getLogEntries(context, new KeyExtent(MetadataTable.ID, null, null)).iterator();
       try {
         Scanner scanner = context.getConnector().createScanner(MetadataTable.NAME, Authorizations.EMPTY);
         log.info("Setting range to " + MetadataSchema.TabletsSection.getRange());
@@ -688,7 +687,7 @@ public class MetadataTableUtil {
   private static Mutation createCloneMutation(String srcTableId, String tableId, Map<Key,Value> tablet) {
 
     KeyExtent ke = new KeyExtent(tablet.keySet().iterator().next().getRow(), (Text) null);
-    Mutation m = new Mutation(KeyExtent.getMetadataEntry(new Text(tableId), ke.getEndRow()));
+    Mutation m = new Mutation(KeyExtent.getMetadataEntry(tableId, ke.getEndRow()));
 
     for (Entry<Key,Value> entry : tablet.entrySet()) {
       if (entry.getKey().getColumnFamily().equals(DataFileColumnFamily.NAME)) {
@@ -709,7 +708,7 @@ public class MetadataTableUtil {
 
   private static Scanner createCloneScanner(String tableName, String tableId, Connector conn) throws TableNotFoundException {
     Scanner mscanner = new IsolatedScanner(conn.createScanner(tableName, Authorizations.EMPTY));
-    mscanner.setRange(new KeyExtent(new Text(tableId), null, null).toMetadataRange());
+    mscanner.setRange(new KeyExtent(tableId, null, null).toMetadataRange());
     mscanner.fetchColumnFamily(DataFileColumnFamily.NAME);
     mscanner.fetchColumnFamily(TabletsSection.CurrentLocationColumnFamily.NAME);
     mscanner.fetchColumnFamily(TabletsSection.LastLocationColumnFamily.NAME);
@@ -726,7 +725,7 @@ public class MetadataTableUtil {
     if (srcTableId.equals(MetadataTable.ID))
       ti = new TabletIterator(createCloneScanner(tableName, srcTableId, conn), new Range(), true, true);
     else
-      ti = new TabletIterator(createCloneScanner(tableName, srcTableId, conn), new KeyExtent(new Text(srcTableId), null, null).toMetadataRange(), true, true);
+      ti = new TabletIterator(createCloneScanner(tableName, srcTableId, conn), new KeyExtent(srcTableId, null, null).toMetadataRange(), true, true);
 
     if (!ti.hasNext())
       throw new RuntimeException(" table deleted during clone?  srcTableId = " + srcTableId);
@@ -738,16 +737,16 @@ public class MetadataTableUtil {
   }
 
   private static int compareEndRows(Text endRow1, Text endRow2) {
-    return new KeyExtent(new Text("0"), endRow1, null).compareTo(new KeyExtent(new Text("0"), endRow2, null));
+    return new KeyExtent("0", endRow1, null).compareTo(new KeyExtent("0", endRow2, null));
   }
 
   @VisibleForTesting
   public static int checkClone(String tableName, String srcTableId, String tableId, Connector conn, BatchWriter bw) throws TableNotFoundException,
       MutationsRejectedException {
-    TabletIterator srcIter = new TabletIterator(createCloneScanner(tableName, srcTableId, conn),
-        new KeyExtent(new Text(srcTableId), null, null).toMetadataRange(), true, true);
-    TabletIterator cloneIter = new TabletIterator(createCloneScanner(tableName, tableId, conn), new KeyExtent(new Text(tableId), null, null).toMetadataRange(),
-        true, true);
+    TabletIterator srcIter = new TabletIterator(createCloneScanner(tableName, srcTableId, conn), new KeyExtent(srcTableId, null, null).toMetadataRange(), true,
+        true);
+    TabletIterator cloneIter = new TabletIterator(createCloneScanner(tableName, tableId, conn), new KeyExtent(tableId, null, null).toMetadataRange(), true,
+        true);
 
     if (!cloneIter.hasNext() || !srcIter.hasNext())
       throw new RuntimeException(" table deleted during clone?  srcTableId = " + srcTableId + " tableId=" + tableId);
@@ -863,7 +862,7 @@ public class MetadataTableUtil {
 
     // delete the clone markers and create directory entries
     Scanner mscanner = conn.createScanner(MetadataTable.NAME, Authorizations.EMPTY);
-    mscanner.setRange(new KeyExtent(new Text(tableId), null, null).toMetadataRange());
+    mscanner.setRange(new KeyExtent(tableId, null, null).toMetadataRange());
     mscanner.fetchColumnFamily(ClonedColumnFamily.NAME);
 
     int dirCount = 0;
@@ -891,7 +890,7 @@ public class MetadataTableUtil {
 
   public static void removeBulkLoadEntries(Connector conn, String tableId, long tid) throws Exception {
     Scanner mscanner = new IsolatedScanner(conn.createScanner(MetadataTable.NAME, Authorizations.EMPTY));
-    mscanner.setRange(new KeyExtent(new Text(tableId), null, null).toMetadataRange());
+    mscanner.setRange(new KeyExtent(tableId, null, null).toMetadataRange());
     mscanner.fetchColumnFamily(TabletsSection.BulkFileColumnFamily.NAME);
     BatchWriter bw = conn.createBatchWriter(MetadataTable.NAME, new BatchWriterConfig());
     for (Entry<Key,Value> entry : mscanner) {
@@ -951,7 +950,7 @@ public class MetadataTableUtil {
 
     // new KeyExtent is only added to force update to write to the metadata table, not the root table
     // because bulk loads aren't supported to the metadata table
-    update(context, m, new KeyExtent(new Text("anythingNotMetadata"), null, null));
+    update(context, m, new KeyExtent("anythingNotMetadata", null, null));
   }
 
   public static void removeBulkLoadInProgressFlag(AccumuloServerContext context, String path) {
@@ -961,7 +960,7 @@ public class MetadataTableUtil {
 
     // new KeyExtent is only added to force update to write to the metadata table, not the root table
     // because bulk loads aren't supported to the metadata table
-    update(context, m, new KeyExtent(new Text("anythingNotMetadata"), null, null));
+    update(context, m, new KeyExtent("anythingNotMetadata", null, null));
   }
 
   /**
@@ -971,7 +970,7 @@ public class MetadataTableUtil {
     String dir = VolumeManagerImpl.get().choose(Optional.of(ReplicationTable.ID), ServerConstants.getBaseUris()) + Constants.HDFS_TABLES_DIR + Path.SEPARATOR
         + ReplicationTable.ID + Constants.DEFAULT_TABLET_LOCATION;
 
-    Mutation m = new Mutation(new Text(KeyExtent.getMetadataEntry(new Text(ReplicationTable.ID), null)));
+    Mutation m = new Mutation(new Text(KeyExtent.getMetadataEntry(ReplicationTable.ID, null)));
     m.put(DIRECTORY_COLUMN.getColumnFamily(), DIRECTORY_COLUMN.getColumnQualifier(), 0, new Value(dir.getBytes(UTF_8)));
     m.put(TIME_COLUMN.getColumnFamily(), TIME_COLUMN.getColumnQualifier(), 0, new Value((TabletTime.LOGICAL_TIME_ID + "0").getBytes(UTF_8)));
     m.put(PREV_ROW_COLUMN.getColumnFamily(), PREV_ROW_COLUMN.getColumnQualifier(), 0, KeyExtent.encodePrevEndRow(null));
@@ -1000,7 +999,7 @@ public class MetadataTableUtil {
 
   public static void moveMetaDeleteMarkersFrom14(ClientContext context) {
     // new KeyExtent is only added to force update to write to the metadata table, not the root table
-    KeyExtent notMetadata = new KeyExtent(new Text("anythingNotMetadata"), null, null);
+    KeyExtent notMetadata = new KeyExtent("anythingNotMetadata", null, null);
 
     // move delete markers from the normal delete keyspace to the root tablet delete keyspace if the files are for the !METADATA table
     Scanner scanner = new ScannerImpl(context, MetadataTable.ID, Authorizations.EMPTY);

http://git-wip-us.apache.org/repos/asf/accumulo/blob/a14bc292/server/base/src/main/java/org/apache/accumulo/server/util/RemoveEntriesForMissingFiles.java
----------------------------------------------------------------------
diff --git a/server/base/src/main/java/org/apache/accumulo/server/util/RemoveEntriesForMissingFiles.java b/server/base/src/main/java/org/apache/accumulo/server/util/RemoveEntriesForMissingFiles.java
index c9d4dd5..ae59164 100644
--- a/server/base/src/main/java/org/apache/accumulo/server/util/RemoveEntriesForMissingFiles.java
+++ b/server/base/src/main/java/org/apache/accumulo/server/util/RemoveEntriesForMissingFiles.java
@@ -51,7 +51,6 @@ import org.apache.accumulo.server.fs.VolumeManager;
 import org.apache.accumulo.server.fs.VolumeManagerImpl;
 import org.apache.commons.collections.map.LRUMap;
 import org.apache.hadoop.fs.Path;
-import org.apache.hadoop.io.Text;
 
 import com.beust.jcommander.Parameter;
 
@@ -199,7 +198,7 @@ public class RemoveEntriesForMissingFiles {
       return checkTable(context, RootTable.NAME, MetadataSchema.TabletsSection.getRange(), fix);
     } else {
       String tableId = Tables.getTableId(context.getInstance(), tableName);
-      Range range = new KeyExtent(new Text(tableId), null, null).toMetadataRange();
+      Range range = new KeyExtent(tableId, null, null).toMetadataRange();
       return checkTable(context, MetadataTable.NAME, range, fix);
     }
   }

http://git-wip-us.apache.org/repos/asf/accumulo/blob/a14bc292/server/base/src/main/java/org/apache/accumulo/server/util/ReplicationTableUtil.java
----------------------------------------------------------------------
diff --git a/server/base/src/main/java/org/apache/accumulo/server/util/ReplicationTableUtil.java b/server/base/src/main/java/org/apache/accumulo/server/util/ReplicationTableUtil.java
index b57affe..a400e4f 100644
--- a/server/base/src/main/java/org/apache/accumulo/server/util/ReplicationTableUtil.java
+++ b/server/base/src/main/java/org/apache/accumulo/server/util/ReplicationTableUtil.java
@@ -16,6 +16,8 @@
  */
 package org.apache.accumulo.server.util;
 
+import static com.google.common.util.concurrent.Uninterruptibles.sleepUninterruptibly;
+
 import java.util.Collections;
 import java.util.EnumSet;
 import java.util.HashMap;
@@ -52,8 +54,6 @@ import org.apache.hadoop.io.Text;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
-import static com.google.common.util.concurrent.Uninterruptibles.sleepUninterruptibly;
-
 /**
  * provides a reference to the replication table for updates by tablet servers
  */
@@ -194,7 +194,7 @@ public class ReplicationTableUtil {
 
   private static Mutation createUpdateMutation(Text row, Value v, KeyExtent extent) {
     Mutation m = new Mutation(row);
-    m.put(MetadataSchema.ReplicationSection.COLF, extent.getTableId(), v);
+    m.put(MetadataSchema.ReplicationSection.COLF, new Text(extent.getTableId()), v);
     return m;
   }
 }

http://git-wip-us.apache.org/repos/asf/accumulo/blob/a14bc292/server/base/src/main/java/org/apache/accumulo/server/util/TableDiskUsage.java
----------------------------------------------------------------------
diff --git a/server/base/src/main/java/org/apache/accumulo/server/util/TableDiskUsage.java b/server/base/src/main/java/org/apache/accumulo/server/util/TableDiskUsage.java
index 235286b..1a630a9 100644
--- a/server/base/src/main/java/org/apache/accumulo/server/util/TableDiskUsage.java
+++ b/server/base/src/main/java/org/apache/accumulo/server/util/TableDiskUsage.java
@@ -48,7 +48,6 @@ import org.apache.accumulo.server.fs.VolumeManager;
 import org.apache.accumulo.server.fs.VolumeManagerImpl;
 import org.apache.hadoop.fs.FileStatus;
 import org.apache.hadoop.fs.Path;
-import org.apache.hadoop.io.Text;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
@@ -178,7 +177,7 @@ public class TableDiskUsage {
         throw new RuntimeException(e);
       }
       mdScanner.fetchColumnFamily(DataFileColumnFamily.NAME);
-      mdScanner.setRange(new KeyExtent(new Text(tableId), null, null).toMetadataRange());
+      mdScanner.setRange(new KeyExtent(tableId, null, null).toMetadataRange());
 
       if (!mdScanner.iterator().hasNext()) {
         emptyTableIds.add(tableId);

http://git-wip-us.apache.org/repos/asf/accumulo/blob/a14bc292/server/base/src/main/java/org/apache/accumulo/server/util/TabletIterator.java
----------------------------------------------------------------------
diff --git a/server/base/src/main/java/org/apache/accumulo/server/util/TabletIterator.java b/server/base/src/main/java/org/apache/accumulo/server/util/TabletIterator.java
index d6864c1..43345f2 100644
--- a/server/base/src/main/java/org/apache/accumulo/server/util/TabletIterator.java
+++ b/server/base/src/main/java/org/apache/accumulo/server/util/TabletIterator.java
@@ -16,6 +16,8 @@
  */
 package org.apache.accumulo.server.util;
 
+import static com.google.common.util.concurrent.Uninterruptibles.sleepUninterruptibly;
+
 import java.util.Iterator;
 import java.util.Map;
 import java.util.Map.Entry;
@@ -38,7 +40,6 @@ import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
 import com.google.common.collect.Iterators;
-import static com.google.common.util.concurrent.Uninterruptibles.sleepUninterruptibly;
 
 /**
  * This class iterates over the metadata table returning all key values for a tablet in one chunk. As it scans the metadata table it checks the correctness of
@@ -118,8 +119,8 @@ public class TabletIterator implements Iterator<Map<Key,Value>> {
         lastEndRow = new KeyExtent(lastTablet, (Text) null).getEndRow();
 
         // do table transition sanity check
-        String lastTable = new KeyExtent(lastTablet, (Text) null).getTableId().toString();
-        String currentTable = new KeyExtent(prevEndRowKey.getRow(), (Text) null).getTableId().toString();
+        String lastTable = new KeyExtent(lastTablet, (Text) null).getTableId();
+        String currentTable = new KeyExtent(prevEndRowKey.getRow(), (Text) null).getTableId();
 
         if (!lastTable.equals(currentTable) && (per != null || lastEndRow != null)) {
           log.info("Metadata inconsistency on table transition : " + lastTable + " " + currentTable + " " + per + " " + lastEndRow);

http://git-wip-us.apache.org/repos/asf/accumulo/blob/a14bc292/server/base/src/test/java/org/apache/accumulo/server/client/BulkImporterTest.java
----------------------------------------------------------------------
diff --git a/server/base/src/test/java/org/apache/accumulo/server/client/BulkImporterTest.java b/server/base/src/test/java/org/apache/accumulo/server/client/BulkImporterTest.java
index 50b996d..0116101 100644
--- a/server/base/src/test/java/org/apache/accumulo/server/client/BulkImporterTest.java
+++ b/server/base/src/test/java/org/apache/accumulo/server/client/BulkImporterTest.java
@@ -52,7 +52,8 @@ import org.junit.Test;
 public class BulkImporterTest {
 
   static final SortedSet<KeyExtent> fakeMetaData = new TreeSet<KeyExtent>();
-  static final Text tableId = new Text("1");
+  static final String tableId = "1";
+
   static {
     fakeMetaData.add(new KeyExtent(tableId, new Text("a"), null));
     for (String part : new String[] {"b", "bm", "c", "cm", "d", "dm", "e", "em", "f", "g", "h", "i", "j", "k", "l"}) {
@@ -161,19 +162,19 @@ public class BulkImporterTest {
     // a correct startRow so that findOverlappingTablets works as intended.
 
     // 1;2;1
-    KeyExtent extent = new KeyExtent(new Text("1"), new Text("2"), new Text("1"));
+    KeyExtent extent = new KeyExtent("1", new Text("2"), new Text("1"));
     Assert.assertEquals(new Text("1\0"), BulkImporter.getStartRowForExtent(extent));
 
     // 1;2<
-    extent = new KeyExtent(new Text("1"), new Text("2"), null);
+    extent = new KeyExtent("1", new Text("2"), null);
     Assert.assertEquals(null, BulkImporter.getStartRowForExtent(extent));
 
     // 1<<
-    extent = new KeyExtent(new Text("1"), null, null);
+    extent = new KeyExtent("1", null, null);
     Assert.assertEquals(null, BulkImporter.getStartRowForExtent(extent));
 
     // 1;8;7777777
-    extent = new KeyExtent(new Text("1"), new Text("8"), new Text("7777777"));
+    extent = new KeyExtent("1", new Text("8"), new Text("7777777"));
     Assert.assertEquals(new Text("7777777\0"), BulkImporter.getStartRowForExtent(extent));
   }
 }

http://git-wip-us.apache.org/repos/asf/accumulo/blob/a14bc292/server/base/src/test/java/org/apache/accumulo/server/master/balancer/ChaoticLoadBalancerTest.java
----------------------------------------------------------------------
diff --git a/server/base/src/test/java/org/apache/accumulo/server/master/balancer/ChaoticLoadBalancerTest.java b/server/base/src/test/java/org/apache/accumulo/server/master/balancer/ChaoticLoadBalancerTest.java
index 0fb9182..7101910 100644
--- a/server/base/src/test/java/org/apache/accumulo/server/master/balancer/ChaoticLoadBalancerTest.java
+++ b/server/base/src/test/java/org/apache/accumulo/server/master/balancer/ChaoticLoadBalancerTest.java
@@ -50,7 +50,7 @@ public class ChaoticLoadBalancerTest {
       TabletServerStatus result = new TabletServerStatus();
       result.tableMap = new HashMap<String,TableInfo>();
       for (KeyExtent extent : extents) {
-        String table = extent.getTableId().toString();
+        String table = extent.getTableId();
         TableInfo info = result.tableMap.get(table);
         if (info == null)
           result.tableMap.put(table, info = new TableInfo());
@@ -71,7 +71,7 @@ public class ChaoticLoadBalancerTest {
     public List<TabletStats> getOnlineTabletsForTable(TServerInstance tserver, String table) throws ThriftSecurityException, TException {
       List<TabletStats> result = new ArrayList<TabletStats>();
       for (KeyExtent extent : servers.get(tserver).extents) {
-        if (extent.getTableId().toString().equals(table)) {
+        if (extent.getTableId().equals(table)) {
           result.add(new TabletStats(extent.toThrift(), null, null, null, 0l, 0., 0., 0));
         }
       }
@@ -154,7 +154,7 @@ public class ChaoticLoadBalancerTest {
   }
 
   private static KeyExtent makeExtent(String table, String end, String prev) {
-    return new KeyExtent(new Text(table), toText(end), toText(prev));
+    return new KeyExtent(table, toText(end), toText(prev));
   }
 
   private static Text toText(String value) {

http://git-wip-us.apache.org/repos/asf/accumulo/blob/a14bc292/server/base/src/test/java/org/apache/accumulo/server/master/balancer/DefaultLoadBalancerTest.java
----------------------------------------------------------------------
diff --git a/server/base/src/test/java/org/apache/accumulo/server/master/balancer/DefaultLoadBalancerTest.java b/server/base/src/test/java/org/apache/accumulo/server/master/balancer/DefaultLoadBalancerTest.java
index aee1795..20d85fe 100644
--- a/server/base/src/test/java/org/apache/accumulo/server/master/balancer/DefaultLoadBalancerTest.java
+++ b/server/base/src/test/java/org/apache/accumulo/server/master/balancer/DefaultLoadBalancerTest.java
@@ -54,7 +54,7 @@ public class DefaultLoadBalancerTest {
       TabletServerStatus result = new TabletServerStatus();
       result.tableMap = new HashMap<String,TableInfo>();
       for (KeyExtent extent : extents) {
-        String table = extent.getTableId().toString();
+        String table = extent.getTableId();
         TableInfo info = result.tableMap.get(table);
         if (info == null)
           result.tableMap.put(table, info = new TableInfo());
@@ -76,7 +76,7 @@ public class DefaultLoadBalancerTest {
     public List<TabletStats> getOnlineTabletsForTable(TServerInstance tserver, String table) throws ThriftSecurityException, TException {
       List<TabletStats> result = new ArrayList<TabletStats>();
       for (KeyExtent extent : servers.get(tserver).extents) {
-        if (extent.getTableId().toString().equals(table)) {
+        if (extent.getTableId().equals(table)) {
           result.add(new TabletStats(extent.toThrift(), null, null, null, 0l, 0., 0., 0));
         }
       }
@@ -169,7 +169,7 @@ public class DefaultLoadBalancerTest {
   public void testUnevenAssignment() {
     for (char c : "abcdefghijklmnopqrstuvwxyz".toCharArray()) {
       String cString = Character.toString(c);
-      HostAndPort fakeAddress = HostAndPort.fromParts("127.0.0.1", (int) c);
+      HostAndPort fakeAddress = HostAndPort.fromParts("127.0.0.1", c);
       String fakeInstance = cString;
       TServerInstance tsi = new TServerInstance(fakeAddress, fakeInstance);
       FakeTServer fakeTServer = new FakeTServer();
@@ -210,7 +210,7 @@ public class DefaultLoadBalancerTest {
     // make 26 servers
     for (char c : "abcdefghijklmnopqrstuvwxyz".toCharArray()) {
       String cString = Character.toString(c);
-      HostAndPort fakeAddress = HostAndPort.fromParts("127.0.0.1", (int) c);
+      HostAndPort fakeAddress = HostAndPort.fromParts("127.0.0.1", c);
       String fakeInstance = cString;
       TServerInstance tsi = new TServerInstance(fakeAddress, fakeInstance);
       FakeTServer fakeTServer = new FakeTServer();
@@ -266,7 +266,7 @@ public class DefaultLoadBalancerTest {
       for (FakeTServer server : servers.values()) {
         Map<String,Integer> counts = new HashMap<String,Integer>();
         for (KeyExtent extent : server.extents) {
-          String t = extent.getTableId().toString();
+          String t = extent.getTableId();
           if (counts.get(t) == null)
             counts.put(t, 0);
           counts.put(t, counts.get(t) + 1);
@@ -279,7 +279,7 @@ public class DefaultLoadBalancerTest {
   }
 
   private static KeyExtent makeExtent(String table, String end, String prev) {
-    return new KeyExtent(new Text(table), toText(end), toText(prev));
+    return new KeyExtent(table, toText(end), toText(prev));
   }
 
   private static Text toText(String value) {

http://git-wip-us.apache.org/repos/asf/accumulo/blob/a14bc292/server/base/src/test/java/org/apache/accumulo/server/master/balancer/GroupBalancerTest.java
----------------------------------------------------------------------
diff --git a/server/base/src/test/java/org/apache/accumulo/server/master/balancer/GroupBalancerTest.java b/server/base/src/test/java/org/apache/accumulo/server/master/balancer/GroupBalancerTest.java
index 5de4923..65b43cc 100644
--- a/server/base/src/test/java/org/apache/accumulo/server/master/balancer/GroupBalancerTest.java
+++ b/server/base/src/test/java/org/apache/accumulo/server/master/balancer/GroupBalancerTest.java
@@ -67,7 +67,7 @@ public class GroupBalancerTest {
 
     public void addTablet(String er, String location) {
       TServerInstance tsi = new TServerInstance(location, 6);
-      tabletLocs.put(new KeyExtent(new Text("b"), er == null ? null : new Text(er), null), new TServerInstance(location, 6));
+      tabletLocs.put(new KeyExtent("b", er == null ? null : new Text(er), null), new TServerInstance(location, 6));
       tservers.add(tsi);
     }
 

http://git-wip-us.apache.org/repos/asf/accumulo/blob/a14bc292/server/base/src/test/java/org/apache/accumulo/server/master/balancer/TableLoadBalancerTest.java
----------------------------------------------------------------------
diff --git a/server/base/src/test/java/org/apache/accumulo/server/master/balancer/TableLoadBalancerTest.java b/server/base/src/test/java/org/apache/accumulo/server/master/balancer/TableLoadBalancerTest.java
index de853d5..7caa60b 100644
--- a/server/base/src/test/java/org/apache/accumulo/server/master/balancer/TableLoadBalancerTest.java
+++ b/server/base/src/test/java/org/apache/accumulo/server/master/balancer/TableLoadBalancerTest.java
@@ -82,8 +82,8 @@ public class TableLoadBalancerTest {
     // generate some fake tablets
     for (int i = 0; i < tableInfo.tableMap.get(tableId).onlineTablets; i++) {
       TabletStats stats = new TabletStats();
-      stats.extent = new KeyExtent(new Text(tableId), new Text(tserver.host() + String.format("%03d", i + 1)), new Text(tserver.host()
-          + String.format("%03d", i))).toThrift();
+      stats.extent = new KeyExtent(tableId, new Text(tserver.host() + String.format("%03d", i + 1)), new Text(tserver.host() + String.format("%03d", i)))
+          .toThrift();
       result.add(stats);
     }
     return result;
@@ -178,7 +178,7 @@ public class TableLoadBalancerTest {
     for (TabletMigration migration : migrationsOut) {
       if (migration.oldServer.equals(svr))
         count++;
-      String key = migration.tablet.getTableId().toString();
+      String key = migration.tablet.getTableId();
       movedByTable.put(key, movedByTable.get(key) + 1);
     }
     Assert.assertEquals(15, count);

http://git-wip-us.apache.org/repos/asf/accumulo/blob/a14bc292/server/base/src/test/java/org/apache/accumulo/server/master/state/MergeInfoTest.java
----------------------------------------------------------------------
diff --git a/server/base/src/test/java/org/apache/accumulo/server/master/state/MergeInfoTest.java b/server/base/src/test/java/org/apache/accumulo/server/master/state/MergeInfoTest.java
index 1ce5dd8..ae06e53 100644
--- a/server/base/src/test/java/org/apache/accumulo/server/master/state/MergeInfoTest.java
+++ b/server/base/src/test/java/org/apache/accumulo/server/master/state/MergeInfoTest.java
@@ -68,7 +68,7 @@ public class MergeInfoTest {
 
   @Test
   public void testSerialization() throws Exception {
-    Text table = new Text("table");
+    String table = "table";
     Text endRow = new Text("end");
     Text prevEndRow = new Text("begin");
     keyExtent = new KeyExtent(table, endRow, prevEndRow);
@@ -88,10 +88,10 @@ public class MergeInfoTest {
 
   @Test
   public void testNeedsToBeChopped_DifferentTables() {
-    expect(keyExtent.getTableId()).andReturn(new Text("table1"));
+    expect(keyExtent.getTableId()).andReturn("table1");
     replay(keyExtent);
     KeyExtent keyExtent2 = createMock(KeyExtent.class);
-    expect(keyExtent2.getTableId()).andReturn(new Text("table2"));
+    expect(keyExtent2.getTableId()).andReturn("table2");
     replay(keyExtent2);
     mi = new MergeInfo(keyExtent, MergeInfo.Operation.MERGE);
     assertFalse(mi.needsToBeChopped(keyExtent2));
@@ -99,9 +99,9 @@ public class MergeInfoTest {
 
   @Test
   public void testNeedsToBeChopped_NotDelete() {
-    expect(keyExtent.getTableId()).andReturn(new Text("table1"));
+    expect(keyExtent.getTableId()).andReturn("table1");
     KeyExtent keyExtent2 = createMock(KeyExtent.class);
-    expect(keyExtent2.getTableId()).andReturn(new Text("table1"));
+    expect(keyExtent2.getTableId()).andReturn("table1");
     replay(keyExtent2);
     expect(keyExtent.overlaps(keyExtent2)).andReturn(true);
     replay(keyExtent);
@@ -125,11 +125,11 @@ public class MergeInfoTest {
   }
 
   private void testNeedsToBeChopped_Delete(String prevEndRow, boolean expected) {
-    expect(keyExtent.getTableId()).andReturn(new Text("table1"));
+    expect(keyExtent.getTableId()).andReturn("table1");
     expect(keyExtent.getEndRow()).andReturn(new Text("prev"));
     replay(keyExtent);
     KeyExtent keyExtent2 = createMock(KeyExtent.class);
-    expect(keyExtent2.getTableId()).andReturn(new Text("table1"));
+    expect(keyExtent2.getTableId()).andReturn("table1");
     expect(keyExtent2.getPrevEndRow()).andReturn(prevEndRow != null ? new Text(prevEndRow) : null);
     expectLastCall().anyTimes();
     replay(keyExtent2);
@@ -150,9 +150,9 @@ public class MergeInfoTest {
   public void testOverlaps_DoesNotNeedChopping() {
     KeyExtent keyExtent2 = createMock(KeyExtent.class);
     expect(keyExtent.overlaps(keyExtent2)).andReturn(false);
-    expect(keyExtent.getTableId()).andReturn(new Text("table1"));
+    expect(keyExtent.getTableId()).andReturn("table1");
     replay(keyExtent);
-    expect(keyExtent2.getTableId()).andReturn(new Text("table2"));
+    expect(keyExtent2.getTableId()).andReturn("table2");
     replay(keyExtent2);
     mi = new MergeInfo(keyExtent, MergeInfo.Operation.MERGE);
     assertFalse(mi.overlaps(keyExtent2));
@@ -162,10 +162,10 @@ public class MergeInfoTest {
   public void testOverlaps_NeedsChopping() {
     KeyExtent keyExtent2 = createMock(KeyExtent.class);
     expect(keyExtent.overlaps(keyExtent2)).andReturn(false);
-    expect(keyExtent.getTableId()).andReturn(new Text("table1"));
+    expect(keyExtent.getTableId()).andReturn("table1");
     expect(keyExtent.getEndRow()).andReturn(new Text("prev"));
     replay(keyExtent);
-    expect(keyExtent2.getTableId()).andReturn(new Text("table1"));
+    expect(keyExtent2.getTableId()).andReturn("table1");
     expect(keyExtent2.getPrevEndRow()).andReturn(new Text("prev"));
     expectLastCall().anyTimes();
     replay(keyExtent2);
@@ -187,7 +187,7 @@ public class MergeInfoTest {
   }
 
   private static KeyExtent ke(String tableId, String endRow, String prevEndRow) {
-    return new KeyExtent(new Text(tableId), endRow == null ? null : new Text(endRow), prevEndRow == null ? null : new Text(prevEndRow));
+    return new KeyExtent(tableId, endRow == null ? null : new Text(endRow), prevEndRow == null ? null : new Text(prevEndRow));
   }
 
   @Test


Mime
View raw message