accumulo-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ctubb...@apache.org
Subject [15/66] [abbrv] accumulo git commit: ACCUMULO-3451 Format master branch (1.7.0-SNAPSHOT)
Date Fri, 09 Jan 2015 02:44:19 GMT
http://git-wip-us.apache.org/repos/asf/accumulo/blob/6bc67602/server/master/src/main/java/org/apache/accumulo/master/tableOps/ExportTable.java
----------------------------------------------------------------------
diff --git a/server/master/src/main/java/org/apache/accumulo/master/tableOps/ExportTable.java b/server/master/src/main/java/org/apache/accumulo/master/tableOps/ExportTable.java
index f309879..4661dea8 100644
--- a/server/master/src/main/java/org/apache/accumulo/master/tableOps/ExportTable.java
+++ b/server/master/src/main/java/org/apache/accumulo/master/tableOps/ExportTable.java
@@ -64,9 +64,9 @@ import org.apache.hadoop.fs.Path;
 import org.apache.hadoop.io.Text;
 
 class ExportInfo implements Serializable {
-  
+
   private static final long serialVersionUID = 1L;
-  
+
   public String tableName;
   public String tableID;
   public String exportDir;
@@ -74,14 +74,14 @@ class ExportInfo implements Serializable {
 }
 
 class WriteExportFiles extends MasterRepo {
-  
+
   private static final long serialVersionUID = 1L;
   private final ExportInfo tableInfo;
-  
+
   WriteExportFiles(ExportInfo tableInfo) {
     this.tableInfo = tableInfo;
   }
-  
+
   private void checkOffline(Connector conn) throws Exception {
     if (Tables.getTableState(conn.getInstance(), tableInfo.tableID) != TableState.OFFLINE) {
       Tables.clearCache(conn.getInstance());
@@ -91,43 +91,43 @@ class WriteExportFiles extends MasterRepo {
       }
     }
   }
-  
+
   @Override
   public long isReady(long tid, Master master) throws Exception {
-    
+
     long reserved = Utils.reserveNamespace(tableInfo.namespaceID, tid, false, true, TableOperation.EXPORT)
         + Utils.reserveTable(tableInfo.tableID, tid, false, true, TableOperation.EXPORT);
     if (reserved > 0)
       return reserved;
-    
+
     Connector conn = master.getConnector();
-    
+
     checkOffline(conn);
-    
+
     Scanner metaScanner = conn.createScanner(MetadataTable.NAME, Authorizations.EMPTY);
     metaScanner.setRange(new KeyExtent(new Text(tableInfo.tableID), null, null).toMetadataRange());
-    
+
     // scan for locations
     metaScanner.fetchColumnFamily(TabletsSection.CurrentLocationColumnFamily.NAME);
     metaScanner.fetchColumnFamily(TabletsSection.FutureLocationColumnFamily.NAME);
-    
+
     if (metaScanner.iterator().hasNext()) {
       return 500;
     }
-    
+
     // use the same range to check for walogs that we used to check for hosted (or future hosted) tablets
     // this is done as a separate scan after we check for locations, because walogs are okay only if there is no location
     metaScanner.clearColumns();
     metaScanner.fetchColumnFamily(LogColumnFamily.NAME);
-    
+
     if (metaScanner.iterator().hasNext()) {
       throw new ThriftTableOperationException(tableInfo.tableID, tableInfo.tableName, TableOperation.EXPORT, TableOperationExceptionType.OTHER,
           "Write ahead logs found for table");
     }
-    
+
     return 0;
   }
-  
+
   @Override
   public Repo<Master> call(long tid, Master master) throws Exception {
     try {
@@ -141,25 +141,25 @@ class WriteExportFiles extends MasterRepo {
     Utils.unreserveHdfsDirectory(new Path(tableInfo.exportDir).toString(), tid);
     return null;
   }
-  
+
   @Override
   public void undo(long tid, Master env) throws Exception {
     Utils.unreserveNamespace(tableInfo.namespaceID, tid, false);
     Utils.unreserveTable(tableInfo.tableID, tid, false);
   }
-  
+
   public static void exportTable(VolumeManager fs, AccumuloServerContext context, String tableName, String tableID, String exportDir) throws Exception {
-    
+
     fs.mkdirs(new Path(exportDir));
     Path exportMetaFilePath = fs.getVolumeByPath(new Path(exportDir)).getFileSystem().makeQualified(new Path(exportDir, Constants.EXPORT_FILE));
-    
+
     FSDataOutputStream fileOut = fs.create(exportMetaFilePath, false);
     ZipOutputStream zipOut = new ZipOutputStream(fileOut);
     BufferedOutputStream bufOut = new BufferedOutputStream(zipOut);
     DataOutputStream dataOut = new DataOutputStream(bufOut);
-    
+
     try {
-      
+
       zipOut.putNextEntry(new ZipEntry(Constants.EXPORT_INFO_FILE));
       OutputStreamWriter osw = new OutputStreamWriter(dataOut, UTF_8);
       osw.append(ExportTable.EXPORT_VERSION_PROP + ":" + ExportTable.VERSION + "\n");
@@ -170,72 +170,72 @@ class WriteExportFiles extends MasterRepo {
       osw.append("srcTableID:" + tableID + "\n");
       osw.append(ExportTable.DATA_VERSION_PROP + ":" + ServerConstants.DATA_VERSION + "\n");
       osw.append("srcCodeVersion:" + Constants.VERSION + "\n");
-      
+
       osw.flush();
       dataOut.flush();
-      
+
       exportConfig(context, tableID, zipOut, dataOut);
       dataOut.flush();
-      
+
       Map<String,String> uniqueFiles = exportMetadata(fs, context, tableID, zipOut, dataOut);
-      
+
       dataOut.close();
       dataOut = null;
-      
+
       createDistcpFile(fs, exportDir, exportMetaFilePath, uniqueFiles);
-      
+
     } finally {
       if (dataOut != null)
         dataOut.close();
     }
   }
-  
+
   private static void createDistcpFile(VolumeManager fs, String exportDir, Path exportMetaFilePath, Map<String,String> uniqueFiles) throws IOException {
     BufferedWriter distcpOut = new BufferedWriter(new OutputStreamWriter(fs.create(new Path(exportDir, "distcp.txt"), false), UTF_8));
-    
+
     try {
       for (String file : uniqueFiles.values()) {
         distcpOut.append(file);
         distcpOut.newLine();
       }
-      
+
       distcpOut.append(exportMetaFilePath.toString());
       distcpOut.newLine();
-      
+
       distcpOut.close();
       distcpOut = null;
-      
+
     } finally {
       if (distcpOut != null)
         distcpOut.close();
     }
   }
-  
+
   private static Map<String,String> exportMetadata(VolumeManager fs, AccumuloServerContext context, String tableID, ZipOutputStream zipOut,
       DataOutputStream dataOut) throws IOException, TableNotFoundException, AccumuloException, AccumuloSecurityException {
     zipOut.putNextEntry(new ZipEntry(Constants.EXPORT_METADATA_FILE));
-    
+
     Map<String,String> uniqueFiles = new HashMap<String,String>();
-    
+
     Scanner metaScanner = context.getConnector().createScanner(MetadataTable.NAME, Authorizations.EMPTY);
     metaScanner.fetchColumnFamily(DataFileColumnFamily.NAME);
     TabletsSection.TabletColumnFamily.PREV_ROW_COLUMN.fetch(metaScanner);
     TabletsSection.ServerColumnFamily.TIME_COLUMN.fetch(metaScanner);
     metaScanner.setRange(new KeyExtent(new Text(tableID), null, null).toMetadataRange());
-    
+
     for (Entry<Key,Value> entry : metaScanner) {
       entry.getKey().write(dataOut);
       entry.getValue().write(dataOut);
-      
+
       if (entry.getKey().getColumnFamily().equals(DataFileColumnFamily.NAME)) {
         String path = fs.getFullPath(entry.getKey()).toString();
         String tokens[] = path.split("/");
         if (tokens.length < 1) {
           throw new RuntimeException("Illegal path " + path);
         }
-        
+
         String filename = tokens[tokens.length - 1];
-        
+
         String existingPath = uniqueFiles.get(filename);
         if (existingPath == null) {
           uniqueFiles.put(filename, path);
@@ -243,30 +243,30 @@ class WriteExportFiles extends MasterRepo {
           // make sure file names are unique, should only apply for tables with file names generated by Accumulo 1.3 and earlier
           throw new IOException("Cannot export table with nonunique file names " + filename + ". Major compact table.");
         }
-        
+
       }
     }
     return uniqueFiles;
   }
-  
+
   private static void exportConfig(AccumuloServerContext context, String tableID, ZipOutputStream zipOut, DataOutputStream dataOut) throws AccumuloException,
       AccumuloSecurityException, TableNotFoundException, IOException {
     Connector conn = context.getConnector();
-    
+
     DefaultConfiguration defaultConfig = AccumuloConfiguration.getDefaultConfiguration();
     Map<String,String> siteConfig = conn.instanceOperations().getSiteConfiguration();
     Map<String,String> systemConfig = conn.instanceOperations().getSystemConfiguration();
-    
+
     TableConfiguration tableConfig = context.getServerConfigurationFactory().getTableConfiguration(tableID);
-    
+
     OutputStreamWriter osw = new OutputStreamWriter(dataOut, UTF_8);
-    
+
     // only put props that are different than defaults and higher level configurations
     zipOut.putNextEntry(new ZipEntry(Constants.EXPORT_TABLE_CONFIG_FILE));
     for (Entry<String,String> prop : tableConfig) {
       if (prop.getKey().startsWith(Property.TABLE_PREFIX.getKey())) {
         Property key = Property.getPropertyByKey(prop.getKey());
-        
+
         if (key == null || !defaultConfig.get(key).equals(prop.getValue())) {
           if (!prop.getValue().equals(siteConfig.get(prop.getKey())) && !prop.getValue().equals(systemConfig.get(prop.getKey()))) {
             osw.append(prop.getKey() + "=" + prop.getValue() + "\n");
@@ -274,16 +274,16 @@ class WriteExportFiles extends MasterRepo {
         }
       }
     }
-    
+
     osw.flush();
   }
 }
 
 public class ExportTable extends MasterRepo {
   private static final long serialVersionUID = 1L;
-  
+
   private final ExportInfo tableInfo;
-  
+
   public ExportTable(String tableName, String tableId, String exportDir) {
     tableInfo = new ExportInfo();
     tableInfo.tableName = tableName;
@@ -291,25 +291,25 @@ public class ExportTable extends MasterRepo {
     tableInfo.tableID = tableId;
     tableInfo.namespaceID = Tables.getNamespaceId(HdfsZooInstance.getInstance(), tableId);
   }
-  
+
   @Override
   public long isReady(long tid, Master environment) throws Exception {
     return Utils.reserveHdfsDirectory(new Path(tableInfo.exportDir).toString(), tid);
   }
-  
+
   @Override
   public Repo<Master> call(long tid, Master env) throws Exception {
     return new WriteExportFiles(tableInfo);
   }
-  
+
   @Override
   public void undo(long tid, Master env) throws Exception {
     Utils.unreserveHdfsDirectory(new Path(tableInfo.exportDir).toString(), tid);
   }
-  
+
   public static final int VERSION = 1;
-  
+
   public static final String DATA_VERSION_PROP = "srcDataVersion";
   public static final String EXPORT_VERSION_PROP = "exportVersion";
-  
+
 }

http://git-wip-us.apache.org/repos/asf/accumulo/blob/6bc67602/server/master/src/main/java/org/apache/accumulo/master/tableOps/MasterRepo.java
----------------------------------------------------------------------
diff --git a/server/master/src/main/java/org/apache/accumulo/master/tableOps/MasterRepo.java b/server/master/src/main/java/org/apache/accumulo/master/tableOps/MasterRepo.java
index dfd287c..8f65fac 100644
--- a/server/master/src/main/java/org/apache/accumulo/master/tableOps/MasterRepo.java
+++ b/server/master/src/main/java/org/apache/accumulo/master/tableOps/MasterRepo.java
@@ -21,29 +21,29 @@ import org.apache.accumulo.master.Master;
 import org.apache.log4j.Logger;
 
 public abstract class MasterRepo implements Repo<Master> {
-  
+
   private static final long serialVersionUID = 1L;
   protected static final Logger log = Logger.getLogger(MasterRepo.class);
-  
+
   @Override
   public long isReady(long tid, Master environment) throws Exception {
     return 0;
   }
-  
+
   @Override
   public void undo(long tid, Master environment) throws Exception {}
-  
+
   @Override
   public String getDescription() {
     return this.getClass().getSimpleName();
   }
-  
+
   @Override
   public String getReturn() {
     return null;
   }
-  
+
   @Override
   abstract public Repo<Master> call(long tid, Master environment) throws Exception;
-  
+
 }

http://git-wip-us.apache.org/repos/asf/accumulo/blob/6bc67602/server/master/src/main/java/org/apache/accumulo/master/tableOps/TableRangeOp.java
----------------------------------------------------------------------
diff --git a/server/master/src/main/java/org/apache/accumulo/master/tableOps/TableRangeOp.java b/server/master/src/main/java/org/apache/accumulo/master/tableOps/TableRangeOp.java
index ccb5d69..68c3e72 100644
--- a/server/master/src/main/java/org/apache/accumulo/master/tableOps/TableRangeOp.java
+++ b/server/master/src/main/java/org/apache/accumulo/master/tableOps/TableRangeOp.java
@@ -32,14 +32,14 @@ import org.apache.hadoop.io.Text;
 
 /**
  * Merge makes things hard.
- * 
+ *
  * Typically, a client will read the list of tablets, and begin an operation on that tablet at the location listed in the metadata table. When a tablet splits,
  * the information read from the metadata table doesn't match reality, so the operation fails, and must be retried. But the operation will take place either on
  * the parent, or at a later time on the children. It won't take place on just half of the tablet.
- * 
+ *
  * However, when a merge occurs, the operation may have succeeded on one section of the merged area, and not on the others, when the merge occurs. There is no
  * way to retry the request at a later time on an unmodified tablet.
- * 
+ *
  * The code below uses read-write lock to prevent some operations while a merge is taking place. Normal operations, like bulk imports, will grab the read lock
  * and prevent merges (writes) while they run. Merge operations will lock out some operations while they run.
  */
@@ -87,8 +87,7 @@ public class TableRangeOp extends MasterRepo {
   @Override
   public long isReady(long tid, Master environment) throws Exception {
     String namespaceId = Tables.getNamespaceId(environment.getInstance(), tableId);
-    return Utils.reserveNamespace(namespaceId, tid, false, true, TableOperation.MERGE)
-        + Utils.reserveTable(tableId, tid, true, true, TableOperation.MERGE);
+    return Utils.reserveNamespace(namespaceId, tid, false, true, TableOperation.MERGE) + Utils.reserveTable(tableId, tid, true, true, TableOperation.MERGE);
   }
 
   public TableRangeOp(MergeInfo.Operation op, String tableId, Text startRow, Text endRow) throws ThriftTableOperationException {

http://git-wip-us.apache.org/repos/asf/accumulo/blob/6bc67602/server/master/src/main/java/org/apache/accumulo/master/tableOps/TraceRepo.java
----------------------------------------------------------------------
diff --git a/server/master/src/main/java/org/apache/accumulo/master/tableOps/TraceRepo.java b/server/master/src/main/java/org/apache/accumulo/master/tableOps/TraceRepo.java
index 2571030..43f27bd 100644
--- a/server/master/src/main/java/org/apache/accumulo/master/tableOps/TraceRepo.java
+++ b/server/master/src/main/java/org/apache/accumulo/master/tableOps/TraceRepo.java
@@ -23,23 +23,23 @@ import org.apache.accumulo.core.trace.thrift.TInfo;
 import org.apache.accumulo.fate.Repo;
 
 /**
- * 
+ *
  */
 public class TraceRepo<T> implements Repo<T> {
-  
+
   private static final long serialVersionUID = 1L;
-  
+
   long traceId;
   long parentId;
   Repo<T> repo;
-  
+
   public TraceRepo(Repo<T> repo) {
     this.repo = repo;
     TInfo tinfo = Tracer.traceInfo();
     traceId = tinfo.traceId;
     parentId = tinfo.parentId;
   }
-  
+
   @Override
   public long isReady(long tid, T environment) throws Exception {
     Span span = Trace.trace(new TInfo(traceId, parentId), repo.getDescription());
@@ -49,7 +49,7 @@ public class TraceRepo<T> implements Repo<T> {
       span.stop();
     }
   }
-  
+
   @Override
   public Repo<T> call(long tid, T environment) throws Exception {
     Span span = Trace.trace(new TInfo(traceId, parentId), repo.getDescription());
@@ -62,7 +62,7 @@ public class TraceRepo<T> implements Repo<T> {
       span.stop();
     }
   }
-  
+
   @Override
   public void undo(long tid, T environment) throws Exception {
     Span span = Trace.trace(new TInfo(traceId, parentId), repo.getDescription());
@@ -72,15 +72,15 @@ public class TraceRepo<T> implements Repo<T> {
       span.stop();
     }
   }
-  
+
   @Override
   public String getDescription() {
     return repo.getDescription();
   }
-  
+
   @Override
   public String getReturn() {
     return repo.getReturn();
   }
-  
+
 }

http://git-wip-us.apache.org/repos/asf/accumulo/blob/6bc67602/server/master/src/main/java/org/apache/accumulo/master/tableOps/Utils.java
----------------------------------------------------------------------
diff --git a/server/master/src/main/java/org/apache/accumulo/master/tableOps/Utils.java b/server/master/src/main/java/org/apache/accumulo/master/tableOps/Utils.java
index 64947fb..0f6025a 100644
--- a/server/master/src/main/java/org/apache/accumulo/master/tableOps/Utils.java
+++ b/server/master/src/main/java/org/apache/accumulo/master/tableOps/Utils.java
@@ -118,8 +118,7 @@ public class Utils {
   public static long reserveHdfsDirectory(String directory, long tid) throws KeeperException, InterruptedException {
     Instance instance = HdfsZooInstance.getInstance();
 
-    String resvPath = ZooUtil.getRoot(instance) + Constants.ZHDFS_RESERVATIONS + "/"
-        + Base64.encodeBase64String(directory.getBytes(UTF_8));
+    String resvPath = ZooUtil.getRoot(instance) + Constants.ZHDFS_RESERVATIONS + "/" + Base64.encodeBase64String(directory.getBytes(UTF_8));
 
     IZooReaderWriter zk = ZooReaderWriter.getInstance();
 
@@ -131,8 +130,7 @@ public class Utils {
 
   public static void unreserveHdfsDirectory(String directory, long tid) throws KeeperException, InterruptedException {
     Instance instance = HdfsZooInstance.getInstance();
-    String resvPath = ZooUtil.getRoot(instance) + Constants.ZHDFS_RESERVATIONS + "/"
-        + Base64.encodeBase64String(directory.getBytes(UTF_8));
+    String resvPath = ZooUtil.getRoot(instance) + Constants.ZHDFS_RESERVATIONS + "/" + Base64.encodeBase64String(directory.getBytes(UTF_8));
     ZooReservation.release(ZooReaderWriter.getInstance(), resvPath, String.format("%016x", tid));
   }
 

http://git-wip-us.apache.org/repos/asf/accumulo/blob/6bc67602/server/master/src/main/java/org/apache/accumulo/master/tserverOps/ShutdownTServer.java
----------------------------------------------------------------------
diff --git a/server/master/src/main/java/org/apache/accumulo/master/tserverOps/ShutdownTServer.java b/server/master/src/main/java/org/apache/accumulo/master/tserverOps/ShutdownTServer.java
index 53c7c6f..6cce8ee 100644
--- a/server/master/src/main/java/org/apache/accumulo/master/tserverOps/ShutdownTServer.java
+++ b/server/master/src/main/java/org/apache/accumulo/master/tserverOps/ShutdownTServer.java
@@ -24,8 +24,8 @@ import org.apache.accumulo.core.zookeeper.ZooUtil;
 import org.apache.accumulo.fate.Repo;
 import org.apache.accumulo.fate.zookeeper.IZooReaderWriter;
 import org.apache.accumulo.fate.zookeeper.ZooUtil.NodeExistsPolicy;
-import org.apache.accumulo.master.Master;
 import org.apache.accumulo.master.EventCoordinator.Listener;
+import org.apache.accumulo.master.Master;
 import org.apache.accumulo.master.tableOps.MasterRepo;
 import org.apache.accumulo.server.master.LiveTServerSet.TServerConnection;
 import org.apache.accumulo.server.master.state.TServerInstance;
@@ -35,22 +35,22 @@ import org.apache.log4j.Logger;
 import org.apache.thrift.transport.TTransportException;
 
 public class ShutdownTServer extends MasterRepo {
-  
+
   private static final long serialVersionUID = 1L;
   private static final Logger log = Logger.getLogger(ShutdownTServer.class);
   private TServerInstance server;
   private boolean force;
-  
+
   public ShutdownTServer(TServerInstance server, boolean force) {
     this.server = server;
     this.force = force;
   }
-  
+
   @Override
   public long isReady(long tid, Master environment) throws Exception {
     return 0;
   }
-  
+
   @Override
   public Repo<Master> call(long tid, Master master) throws Exception {
     // suppress assignment of tablets to the server
@@ -62,7 +62,7 @@ public class ShutdownTServer extends MasterRepo {
       zoo.putPersistentData(path, "forced down".getBytes(UTF_8), NodeExistsPolicy.OVERWRITE);
       return null;
     }
-    
+
     // TODO move this to isReady() and drop while loop? - ACCUMULO-1259
     Listener listener = master.getEventCoordinator().getListener();
     master.shutdownTServer(server);
@@ -85,10 +85,10 @@ public class ShutdownTServer extends MasterRepo {
       }
       listener.waitForEvents(1000);
     }
-    
+
     return null;
   }
-  
+
   @Override
   public void undo(long tid, Master m) throws Exception {}
 }

http://git-wip-us.apache.org/repos/asf/accumulo/blob/6bc67602/server/master/src/test/java/org/apache/accumulo/master/DefaultMapTest.java
----------------------------------------------------------------------
diff --git a/server/master/src/test/java/org/apache/accumulo/master/DefaultMapTest.java b/server/master/src/test/java/org/apache/accumulo/master/DefaultMapTest.java
index 3389aa3..c0e9a4a 100644
--- a/server/master/src/test/java/org/apache/accumulo/master/DefaultMapTest.java
+++ b/server/master/src/test/java/org/apache/accumulo/master/DefaultMapTest.java
@@ -16,13 +16,14 @@
  */
 package org.apache.accumulo.master;
 
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertTrue;
+
 import org.apache.accumulo.server.util.DefaultMap;
 import org.junit.Test;
 
-import static org.junit.Assert.*;
-
 public class DefaultMapTest {
-  
+
   @Test
   public void testDefaultMap() {
     DefaultMap<String,String> map = new DefaultMap<String,String>("");
@@ -32,5 +33,5 @@ public class DefaultMapTest {
     assertEquals(empty, "");
     assertTrue(empty == map.get("otherKey"));
   }
-  
+
 }

http://git-wip-us.apache.org/repos/asf/accumulo/blob/6bc67602/server/master/src/test/java/org/apache/accumulo/master/TestMergeState.java
----------------------------------------------------------------------
diff --git a/server/master/src/test/java/org/apache/accumulo/master/TestMergeState.java b/server/master/src/test/java/org/apache/accumulo/master/TestMergeState.java
index 5c46ddc..d5951cc 100644
--- a/server/master/src/test/java/org/apache/accumulo/master/TestMergeState.java
+++ b/server/master/src/test/java/org/apache/accumulo/master/TestMergeState.java
@@ -54,7 +54,7 @@ import org.junit.Test;
 import com.google.common.net.HostAndPort;
 
 /**
- * 
+ *
  */
 public class TestMergeState {
 

http://git-wip-us.apache.org/repos/asf/accumulo/blob/6bc67602/server/master/src/test/java/org/apache/accumulo/master/replication/DistributedWorkQueueWorkAssignerHelperTest.java
----------------------------------------------------------------------
diff --git a/server/master/src/test/java/org/apache/accumulo/master/replication/DistributedWorkQueueWorkAssignerHelperTest.java b/server/master/src/test/java/org/apache/accumulo/master/replication/DistributedWorkQueueWorkAssignerHelperTest.java
index feee6d5..789a634 100644
--- a/server/master/src/test/java/org/apache/accumulo/master/replication/DistributedWorkQueueWorkAssignerHelperTest.java
+++ b/server/master/src/test/java/org/apache/accumulo/master/replication/DistributedWorkQueueWorkAssignerHelperTest.java
@@ -27,7 +27,7 @@ import org.junit.Assert;
 import org.junit.Test;
 
 /**
- * 
+ *
  */
 public class DistributedWorkQueueWorkAssignerHelperTest {
 

http://git-wip-us.apache.org/repos/asf/accumulo/blob/6bc67602/server/master/src/test/java/org/apache/accumulo/master/replication/MasterReplicationCoordinatorTest.java
----------------------------------------------------------------------
diff --git a/server/master/src/test/java/org/apache/accumulo/master/replication/MasterReplicationCoordinatorTest.java b/server/master/src/test/java/org/apache/accumulo/master/replication/MasterReplicationCoordinatorTest.java
index a2ea329..36e71f8 100644
--- a/server/master/src/test/java/org/apache/accumulo/master/replication/MasterReplicationCoordinatorTest.java
+++ b/server/master/src/test/java/org/apache/accumulo/master/replication/MasterReplicationCoordinatorTest.java
@@ -30,7 +30,7 @@ import org.junit.Test;
 import com.google.common.net.HostAndPort;
 
 /**
- * 
+ *
  */
 public class MasterReplicationCoordinatorTest {
 

http://git-wip-us.apache.org/repos/asf/accumulo/blob/6bc67602/server/master/src/test/java/org/apache/accumulo/master/replication/StatusMakerTest.java
----------------------------------------------------------------------
diff --git a/server/master/src/test/java/org/apache/accumulo/master/replication/StatusMakerTest.java b/server/master/src/test/java/org/apache/accumulo/master/replication/StatusMakerTest.java
index 6a8fa4d..7ee3a89 100644
--- a/server/master/src/test/java/org/apache/accumulo/master/replication/StatusMakerTest.java
+++ b/server/master/src/test/java/org/apache/accumulo/master/replication/StatusMakerTest.java
@@ -54,7 +54,7 @@ import com.google.common.collect.Iterables;
 import com.google.common.collect.Sets;
 
 /**
- * 
+ *
  */
 public class StatusMakerTest {
 

http://git-wip-us.apache.org/repos/asf/accumulo/blob/6bc67602/server/master/src/test/java/org/apache/accumulo/master/state/MergeInfoTest.java
----------------------------------------------------------------------
diff --git a/server/master/src/test/java/org/apache/accumulo/master/state/MergeInfoTest.java b/server/master/src/test/java/org/apache/accumulo/master/state/MergeInfoTest.java
index d7fc619..8ac3e42 100644
--- a/server/master/src/test/java/org/apache/accumulo/master/state/MergeInfoTest.java
+++ b/server/master/src/test/java/org/apache/accumulo/master/state/MergeInfoTest.java
@@ -26,7 +26,7 @@ import org.junit.Assert;
 import org.junit.Test;
 
 public class MergeInfoTest {
-  
+
   MergeInfo readWrite(MergeInfo info) throws Exception {
     DataOutputBuffer buffer = new DataOutputBuffer();
     info.write(buffer);
@@ -39,11 +39,11 @@ public class MergeInfoTest {
     Assert.assertEquals(info.getOperation(), info2.getOperation());
     return info2;
   }
-  
+
   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));
   }
-  
+
   @Test
   public void testWritable() throws Exception {
     MergeInfo info;
@@ -54,7 +54,7 @@ public class MergeInfoTest {
     Assert.assertTrue(info.isDelete());
     info.setState(MergeState.COMPLETE);
   }
-  
+
   @Test
   public void testNeedsToBeChopped() throws Exception {
     MergeInfo info = new MergeInfo(ke("x", "b", "a"), MergeInfo.Operation.DELETE);
@@ -72,5 +72,5 @@ public class MergeInfoTest {
     Assert.assertFalse(info.needsToBeChopped(ke("x", "c", "bb")));
     Assert.assertTrue(info.needsToBeChopped(ke("x", "b", "a")));
   }
-  
+
 }

http://git-wip-us.apache.org/repos/asf/accumulo/blob/6bc67602/server/master/src/test/java/org/apache/accumulo/master/state/RootTabletStateStoreTest.java
----------------------------------------------------------------------
diff --git a/server/master/src/test/java/org/apache/accumulo/master/state/RootTabletStateStoreTest.java b/server/master/src/test/java/org/apache/accumulo/master/state/RootTabletStateStoreTest.java
index 3479d35..abceae4 100644
--- a/server/master/src/test/java/org/apache/accumulo/master/state/RootTabletStateStoreTest.java
+++ b/server/master/src/test/java/org/apache/accumulo/master/state/RootTabletStateStoreTest.java
@@ -34,8 +34,8 @@ import org.apache.accumulo.server.master.state.DistributedStore;
 import org.apache.accumulo.server.master.state.DistributedStoreException;
 import org.apache.accumulo.server.master.state.TServerInstance;
 import org.apache.accumulo.server.master.state.TabletLocationState;
-import org.apache.accumulo.server.master.state.ZooTabletStateStore;
 import org.apache.accumulo.server.master.state.TabletLocationState.BadLocationStateException;
+import org.apache.accumulo.server.master.state.ZooTabletStateStore;
 import org.apache.hadoop.io.Text;
 import org.junit.Assert;
 import org.junit.Test;
@@ -43,16 +43,16 @@ import org.junit.Test;
 import com.google.common.net.HostAndPort;
 
 public class RootTabletStateStoreTest {
-  
+
   static class Node {
     Node(String name) {
       this.name = name;
     }
-    
+
     List<Node> children = new ArrayList<Node>();
     String name;
     byte[] value = new byte[] {};
-    
+
     Node find(String name) {
       for (Node node : children)
         if (node.name.equals(name))
@@ -60,11 +60,11 @@ public class RootTabletStateStoreTest {
       return null;
     }
   };
-  
+
   static class FakeZooStore implements DistributedStore {
-    
+
     Node root = new Node("/");
-    
+
     private Node recurse(Node root, String[] path, int depth) {
       if (depth == path.length)
         return root;
@@ -73,12 +73,12 @@ public class RootTabletStateStoreTest {
         return null;
       return recurse(child, path, depth + 1);
     }
-    
+
     private Node navigate(String path) {
       path = path.replaceAll("/$", "");
       return recurse(root, path.split("/"), 1);
     }
-    
+
     @Override
     public List<String> getChildren(String path) throws DistributedStoreException {
       Node node = navigate(path);
@@ -89,17 +89,17 @@ public class RootTabletStateStoreTest {
         children.add(child.name);
       return children;
     }
-    
+
     @Override
     public void put(String path, byte[] bs) throws DistributedStoreException {
       create(path).value = bs;
     }
-    
+
     private Node create(String path) {
       String[] parts = path.split("/");
       return recurseCreate(root, parts, 1);
     }
-    
+
     private Node recurseCreate(Node root, String[] path, int index) {
       if (path.length == index)
         return root;
@@ -110,7 +110,7 @@ public class RootTabletStateStoreTest {
       }
       return recurseCreate(node, path, index + 1);
     }
-    
+
     @Override
     public void remove(String path) throws DistributedStoreException {
       String[] parts = path.split("/");
@@ -122,7 +122,7 @@ public class RootTabletStateStoreTest {
       if (child != null)
         parent.children.remove(child);
     }
-    
+
     @Override
     public byte[] get(String path) throws DistributedStoreException {
       Node node = navigate(path);
@@ -131,7 +131,7 @@ public class RootTabletStateStoreTest {
       return null;
     }
   }
-  
+
   @Test
   public void testFakeZoo() throws DistributedStoreException {
     DistributedStore store = new FakeZooStore();
@@ -149,7 +149,7 @@ public class RootTabletStateStoreTest {
     children = store.getChildren("/a/b");
     assertEquals(new HashSet<String>(children), new HashSet<String>(Arrays.asList("b")));
   }
-  
+
   @Test
   public void testRootTabletStateStore() throws DistributedStoreException {
     ZooTabletStateStore tstore = new ZooTabletStateStore(new FakeZooStore());
@@ -190,18 +190,18 @@ public class RootTabletStateStoreTest {
       count++;
     }
     assertEquals(count, 1);
-    
+
     KeyExtent notRoot = new KeyExtent(new Text("0"), null, null);
     try {
       tstore.setLocations(Collections.singletonList(new Assignment(notRoot, server)));
       Assert.fail("should not get here");
     } catch (IllegalArgumentException ex) {}
-    
+
     try {
       tstore.setFutureLocations(Collections.singletonList(new Assignment(notRoot, server)));
       Assert.fail("should not get here");
     } catch (IllegalArgumentException ex) {}
-    
+
     TabletLocationState broken = null;
     try {
       broken = new TabletLocationState(notRoot, server, null, null, null, false);
@@ -213,7 +213,7 @@ public class RootTabletStateStoreTest {
       Assert.fail("should not get here");
     } catch (IllegalArgumentException ex) {}
   }
-  
+
   // @Test
   // public void testMetaDataStore() { } // see functional test
 }

http://git-wip-us.apache.org/repos/asf/accumulo/blob/6bc67602/server/monitor/src/main/java/org/apache/accumulo/monitor/Monitor.java
----------------------------------------------------------------------
diff --git a/server/monitor/src/main/java/org/apache/accumulo/monitor/Monitor.java b/server/monitor/src/main/java/org/apache/accumulo/monitor/Monitor.java
index 218bcaf..1a2904c 100644
--- a/server/monitor/src/main/java/org/apache/accumulo/monitor/Monitor.java
+++ b/server/monitor/src/main/java/org/apache/accumulo/monitor/Monitor.java
@@ -523,6 +523,7 @@ public class Monitor {
     public final long scanCount;
     public final Long oldestScan;
     public final long fetched;
+
     ScanStats(List<ActiveScan> active) {
       this.scanCount = active.size();
       long oldest = -1;
@@ -535,9 +536,10 @@ public class Monitor {
   }
 
   static final Map<HostAndPort,ScanStats> allScans = new HashMap<HostAndPort,ScanStats>();
-  public static Map<HostAndPort, ScanStats> getScans() {
+
+  public static Map<HostAndPort,ScanStats> getScans() {
     synchronized (allScans) {
-      return new TreeMap<HostAndPort, ScanStats>(allScans);
+      return new TreeMap<HostAndPort,ScanStats>(allScans);
     }
   }
 

http://git-wip-us.apache.org/repos/asf/accumulo/blob/6bc67602/server/monitor/src/main/java/org/apache/accumulo/monitor/ZooKeeperStatus.java
----------------------------------------------------------------------
diff --git a/server/monitor/src/main/java/org/apache/accumulo/monitor/ZooKeeperStatus.java b/server/monitor/src/main/java/org/apache/accumulo/monitor/ZooKeeperStatus.java
index 907d1f1..89e879e 100644
--- a/server/monitor/src/main/java/org/apache/accumulo/monitor/ZooKeeperStatus.java
+++ b/server/monitor/src/main/java/org/apache/accumulo/monitor/ZooKeeperStatus.java
@@ -33,22 +33,22 @@ import org.apache.thrift.transport.TTransportException;
 import com.google.common.net.HostAndPort;
 
 public class ZooKeeperStatus implements Runnable {
-  
+
   private static final Logger log = Logger.getLogger(ZooKeeperStatus.class);
-  
+
   private volatile boolean stop = false;
-  
+
   public static class ZooKeeperState implements Comparable<ZooKeeperState> {
     public final String keeper;
     public final String mode;
     public final int clients;
-    
+
     public ZooKeeperState(String keeper, String mode, int clients) {
       this.keeper = keeper;
       this.mode = mode;
       this.clients = clients;
     }
-    
+
     @Override
     public int compareTo(ZooKeeperState other) {
       if (this == other) {
@@ -68,29 +68,29 @@ public class ZooKeeperStatus implements Runnable {
       }
     }
   }
-  
+
   private static SortedSet<ZooKeeperState> status = new TreeSet<ZooKeeperState>();
-  
+
   public static Collection<ZooKeeperState> getZooKeeperStatus() {
     return status;
   }
-  
+
   public void stop() {
     this.stop = true;
   }
-  
+
   @Override
   public void run() {
-    
+
     while (!stop) {
-      
+
       TreeSet<ZooKeeperState> update = new TreeSet<ZooKeeperState>();
-      
+
       String zookeepers[] = SiteConfiguration.getInstance().get(Property.INSTANCE_ZK_HOST).split(",");
       for (String keeper : zookeepers) {
         int clients = 0;
         String mode = "unknown";
-        
+
         String[] parts = keeper.split(":");
         TTransport transport = null;
         try {
@@ -99,7 +99,7 @@ public class ZooKeeperStatus implements Runnable {
             addr = HostAndPort.fromParts(parts[0], Integer.parseInt(parts[1]));
           else
             addr = HostAndPort.fromParts(parts[0], 2181);
-          
+
           transport = TTimeoutTransport.create(addr, 10 * 1000l);
           transport.write("stat\n".getBytes(UTF_8), 0, 5);
           StringBuilder response = new StringBuilder();
@@ -137,5 +137,5 @@ public class ZooKeeperStatus implements Runnable {
       UtilWaitThread.sleep(5 * 1000);
     }
   }
-  
+
 }

http://git-wip-us.apache.org/repos/asf/accumulo/blob/6bc67602/server/monitor/src/main/java/org/apache/accumulo/monitor/servlets/GcStatusServlet.java
----------------------------------------------------------------------
diff --git a/server/monitor/src/main/java/org/apache/accumulo/monitor/servlets/GcStatusServlet.java b/server/monitor/src/main/java/org/apache/accumulo/monitor/servlets/GcStatusServlet.java
index 0f0db9e..926eedc 100644
--- a/server/monitor/src/main/java/org/apache/accumulo/monitor/servlets/GcStatusServlet.java
+++ b/server/monitor/src/main/java/org/apache/accumulo/monitor/servlets/GcStatusServlet.java
@@ -29,18 +29,18 @@ import org.apache.accumulo.monitor.util.celltypes.DurationType;
 import org.apache.accumulo.monitor.util.celltypes.NumberType;
 
 public class GcStatusServlet extends BasicServlet {
-  
+
   private static final long serialVersionUID = 1L;
-  
+
   @Override
   protected String getTitle(HttpServletRequest req) {
     return "Garbage Collector Status";
   }
-  
+
   @Override
   protected void pageBody(HttpServletRequest req, HttpServletResponse resp, StringBuilder sb) {
     GCStatus status = Monitor.getGcStatus();
-    
+
     if (status != null) {
       Table gcActivity = new Table("gcActivity", "Collection&nbsp;Activity");
       gcActivity.addSortableColumn("Activity");
@@ -50,7 +50,7 @@ public class GcStatusServlet extends BasicServlet {
       gcActivity.addSortableColumn("In&nbsp;Use", new NumberType<Long>(), null);
       gcActivity.addSortableColumn("Errors", new NumberType<Long>(0l, 1l), null);
       gcActivity.addSortableColumn("Duration", new DurationType(), null);
-      
+
       if (status.last.finished > 0)
         gcActivity.addRow("File&nbsp;Collection,&nbsp;Last&nbsp;Cycle", status.last.finished, status.last.candidates, status.last.deleted, status.last.inUse,
             status.last.errors, status.last.finished - status.last.started);
@@ -68,5 +68,5 @@ public class GcStatusServlet extends BasicServlet {
       banner(sb, "error", "Collector is Unavailable");
     }
   }
-  
+
 }

http://git-wip-us.apache.org/repos/asf/accumulo/blob/6bc67602/server/monitor/src/main/java/org/apache/accumulo/monitor/servlets/JSONServlet.java
----------------------------------------------------------------------
diff --git a/server/monitor/src/main/java/org/apache/accumulo/monitor/servlets/JSONServlet.java b/server/monitor/src/main/java/org/apache/accumulo/monitor/servlets/JSONServlet.java
index 09dbb6e..224e1a1 100644
--- a/server/monitor/src/main/java/org/apache/accumulo/monitor/servlets/JSONServlet.java
+++ b/server/monitor/src/main/java/org/apache/accumulo/monitor/servlets/JSONServlet.java
@@ -36,19 +36,19 @@ import com.google.gson.Gson;
 
 public class JSONServlet extends BasicServlet {
   private static final long serialVersionUID = 1L;
-  
+
   private Gson gson = new Gson();
-  
+
   @Override
   protected String getTitle(HttpServletRequest req) {
     return "JSON Report";
   }
-  
+
   @Override
   protected void pageStart(HttpServletRequest req, HttpServletResponse resp, StringBuilder sb) {
     resp.setContentType("application/json");
   }
-  
+
   private static Map<String,Object> addServer(String ip, String hostname, double osload, double ingest, double query, double ingestMB, double queryMB,
       int scans, double scansessions, long holdtime) {
     Map<String,Object> map = new HashMap<String,Object>();
@@ -64,41 +64,41 @@ public class JSONServlet extends BasicServlet {
     map.put("holdtime", holdtime);
     return map;
   }
-  
+
   @Override
   protected void pageBody(HttpServletRequest req, HttpServletResponse resp, StringBuilder sb) {
     if (Monitor.getMmi() == null || Monitor.getMmi().tableMap == null) {
       return;
     }
-    
+
     Map<String,Object> results = new HashMap<String,Object>();
     List<Map<String,Object>> servers = new ArrayList<Map<String,Object>>();
-    
+
     for (TabletServerStatus status : Monitor.getMmi().tServerInfo) {
       TableInfo summary = TableInfoUtil.summarizeTableStats(status);
       servers.add(addServer(status.name, TServerLinkType.displayName(status.name), status.osLoad, summary.ingestRate, summary.queryRate,
           summary.ingestByteRate / 1000000.0, summary.queryByteRate / 1000000.0, summary.scans.running + summary.scans.queued, Monitor.getLookupRate(),
           status.holdTime));
     }
-    
+
     for (Entry<String,Byte> entry : Monitor.getMmi().badTServers.entrySet()) {
       Map<String,Object> badServer = new HashMap<String,Object>();
       badServer.put("ip", entry.getKey());
       badServer.put("bad", true);
       servers.add(badServer);
     }
-    
+
     for (DeadServer dead : Monitor.getMmi().deadTabletServers) {
       Map<String,Object> deadServer = new HashMap<String,Object>();
       deadServer.put("ip", dead.server);
       deadServer.put("dead", true);
       servers.add(deadServer);
     }
-    
+
     results.put("servers", servers);
     sb.append(gson.toJson(results));
   }
-  
+
   @Override
   protected void pageEnd(HttpServletRequest req, HttpServletResponse resp, StringBuilder sb) {}
 }

http://git-wip-us.apache.org/repos/asf/accumulo/blob/6bc67602/server/monitor/src/main/java/org/apache/accumulo/monitor/servlets/LogServlet.java
----------------------------------------------------------------------
diff --git a/server/monitor/src/main/java/org/apache/accumulo/monitor/servlets/LogServlet.java b/server/monitor/src/main/java/org/apache/accumulo/monitor/servlets/LogServlet.java
index 7c2172a..77f14de 100644
--- a/server/monitor/src/main/java/org/apache/accumulo/monitor/servlets/LogServlet.java
+++ b/server/monitor/src/main/java/org/apache/accumulo/monitor/servlets/LogServlet.java
@@ -33,14 +33,14 @@ import org.apache.log4j.Level;
 import org.apache.log4j.spi.LoggingEvent;
 
 public class LogServlet extends BasicServlet {
-  
+
   private static final long serialVersionUID = 1L;
-  
+
   @Override
   protected String getTitle(HttpServletRequest req) {
     return "Recent Logs";
   }
-  
+
   @Override
   protected void pageBody(HttpServletRequest req, HttpServletResponse resp, StringBuilder sb) {
     AccumuloConfiguration conf = Monitor.getContext().getConfiguration();
@@ -79,7 +79,7 @@ public class LogServlet extends BasicServlet {
           default:
             text.append(c);
         }
-        
+
       }
       StringBuilder builder = new StringBuilder(text.toString());
       if (ev.getThrowableStrRep() != null)
@@ -95,13 +95,13 @@ public class LogServlet extends BasicServlet {
     if (!clear)
       sb.append("<div class='center'><a href='/op?action=clearLog&redir=").append(currentPage(req)).append("'>Clear&nbsp;All&nbsp;Events</a></div>\n");
   }
-  
+
   private static class LogLevelType extends StringType<Level> {
     @Override
     public String alignment() {
       return "center";
     }
-    
+
     @Override
     public String format(Object obj) {
       if (obj == null)

http://git-wip-us.apache.org/repos/asf/accumulo/blob/6bc67602/server/monitor/src/main/java/org/apache/accumulo/monitor/servlets/MasterServlet.java
----------------------------------------------------------------------
diff --git a/server/monitor/src/main/java/org/apache/accumulo/monitor/servlets/MasterServlet.java b/server/monitor/src/main/java/org/apache/accumulo/monitor/servlets/MasterServlet.java
index 2f7086f..64b8648 100644
--- a/server/monitor/src/main/java/org/apache/accumulo/monitor/servlets/MasterServlet.java
+++ b/server/monitor/src/main/java/org/apache/accumulo/monitor/servlets/MasterServlet.java
@@ -27,8 +27,6 @@ import java.util.Map;
 import javax.servlet.http.HttpServletRequest;
 import javax.servlet.http.HttpServletResponse;
 
-import org.apache.accumulo.monitor.util.celltypes.PreciseNumberType;
-
 import org.apache.accumulo.core.client.impl.Tables;
 import org.apache.accumulo.core.conf.Property;
 import org.apache.accumulo.core.master.thrift.DeadServer;
@@ -42,6 +40,7 @@ import org.apache.accumulo.monitor.util.Table;
 import org.apache.accumulo.monitor.util.TableRow;
 import org.apache.accumulo.monitor.util.celltypes.DurationType;
 import org.apache.accumulo.monitor.util.celltypes.NumberType;
+import org.apache.accumulo.monitor.util.celltypes.PreciseNumberType;
 import org.apache.accumulo.monitor.util.celltypes.ProgressChartType;
 import org.apache.accumulo.monitor.util.celltypes.StringType;
 import org.apache.accumulo.server.monitor.DedupedLogEvent;
@@ -51,26 +50,26 @@ import org.apache.log4j.Level;
 import com.google.common.base.Joiner;
 
 public class MasterServlet extends BasicServlet {
-  
+
   private static final long serialVersionUID = 1L;
-  
+
   @Override
   protected String getTitle(HttpServletRequest req) {
     List<String> masters = Monitor.getContext().getInstance().getMasterLocations();
     return "Master Server" + (masters.size() == 0 ? "" : ":" + AddressUtil.parseAddress(masters.get(0), false).getHostText());
   }
-  
+
   @Override
   protected void pageBody(HttpServletRequest req, HttpServletResponse response, StringBuilder sb) throws IOException {
     Map<String,String> tidToNameMap = Tables.getIdToNameMap(Monitor.getContext().getInstance());
-    
+
     doLogEventBanner(sb);
     TablesServlet.doProblemsBanner(sb);
     doMasterStatus(req, sb);
     doRecoveryList(req, sb);
     TablesServlet.doTableList(req, sb, tidToNameMap);
   }
-  
+
   private void doLogEventBanner(StringBuilder sb) {
     if (LogService.getInstance().getEvents().size() > 0) {
       int error = 0, warning = 0, total = 0;
@@ -90,9 +89,9 @@ public class MasterServlet extends BasicServlet {
           : "s", warning, warning == 1 ? "" : "s", total));
     }
   }
-  
+
   private void doMasterStatus(HttpServletRequest req, StringBuilder sb) throws IOException {
-    
+
     if (Monitor.getMmi() != null) {
       String gcStatus = "Waiting";
       if (Monitor.getGcStatus() != null) {
@@ -121,7 +120,7 @@ public class MasterServlet extends BasicServlet {
       if (Monitor.getMmi().serversShuttingDown != null && Monitor.getMmi().serversShuttingDown.size() > 0 && Monitor.getMmi().state == MasterState.NORMAL) {
         sb.append("<span class='warning'>Servers being stopped: " + Joiner.on(", ").join(Monitor.getMmi().serversShuttingDown) + "</span>\n");
       }
-      
+
       int guessHighLoad = ManagementFactory.getOperatingSystemMXBean().getAvailableProcessors();
       List<String> slaves = new ArrayList<String>();
       for (TabletServerStatus up : Monitor.getMmi().tServerInfo) {
@@ -131,7 +130,7 @@ public class MasterServlet extends BasicServlet {
         slaves.add(down.server);
       }
       List<String> masters = Monitor.getContext().getInstance().getMasterLocations();
-      
+
       Table masterStatus = new Table("masterStatus", "Master&nbsp;Status");
       masterStatus.addSortableColumn("Master", new StringType<String>(), "The hostname of the master server");
       masterStatus.addSortableColumn("#&nbsp;Online<br />Tablet&nbsp;Servers", new PreciseNumberType((int) (slaves.size() * 0.8 + 1.0), slaves.size(),
@@ -165,11 +164,11 @@ public class MasterServlet extends BasicServlet {
       row.add(ManagementFactory.getOperatingSystemMXBean().getSystemLoadAverage());
       masterStatus.addRow(row);
       masterStatus.generate(req, sb);
-      
+
     } else
       banner(sb, "error", "Master Server Not Running");
   }
-  
+
   private void doRecoveryList(HttpServletRequest req, StringBuilder sb) {
     MasterMonitorInfo mmi = Monitor.getMmi();
     if (mmi != null) {
@@ -197,5 +196,5 @@ public class MasterServlet extends BasicServlet {
         recoveryTable.generate(req, sb);
     }
   }
-  
+
 }

http://git-wip-us.apache.org/repos/asf/accumulo/blob/6bc67602/server/monitor/src/main/java/org/apache/accumulo/monitor/servlets/ProblemServlet.java
----------------------------------------------------------------------
diff --git a/server/monitor/src/main/java/org/apache/accumulo/monitor/servlets/ProblemServlet.java b/server/monitor/src/main/java/org/apache/accumulo/monitor/servlets/ProblemServlet.java
index 4f7da48..1b3e944 100644
--- a/server/monitor/src/main/java/org/apache/accumulo/monitor/servlets/ProblemServlet.java
+++ b/server/monitor/src/main/java/org/apache/accumulo/monitor/servlets/ProblemServlet.java
@@ -38,31 +38,31 @@ import org.apache.accumulo.server.problems.ProblemReports;
 import org.apache.accumulo.server.problems.ProblemType;
 
 public class ProblemServlet extends BasicServlet {
-  
+
   private static final long serialVersionUID = 1L;
-  
+
   @Override
   protected String getTitle(HttpServletRequest req) {
     return "Per-Table Problem Report";
   }
-  
+
   @Override
   protected void pageBody(final HttpServletRequest req, HttpServletResponse resp, StringBuilder sb) {
     Map<String,String> tidToNameMap = Tables.getIdToNameMap(Monitor.getContext().getInstance());
     doProblemSummary(req, sb, tidToNameMap);
     doProblemDetails(req, sb, req.getParameter("table"), tidToNameMap);
   }
-  
+
   private static void doProblemSummary(final HttpServletRequest req, StringBuilder sb, final Map<String,String> tidToNameMap) {
     if (Monitor.getProblemSummary().isEmpty() && Monitor.getProblemException() == null)
       return;
-    
+
     Table problemSummary = new Table("problemSummary", "Problem&nbsp;Summary", "error");
     problemSummary.addSortableColumn("Table", new TableProblemLinkType(tidToNameMap), null);
     for (ProblemType type : ProblemType.values())
       problemSummary.addSortableColumn(type.name(), new NumberType<Integer>(), null);
     problemSummary.addUnsortableColumn("Operations", new ClearTableProblemsLinkType(req, tidToNameMap), null);
-    
+
     if (Monitor.getProblemException() != null) {
       StringBuilder cell = new StringBuilder();
       cell.append("<b>Failed to obtain problem reports</b> : " + Monitor.getProblemException().getMessage());
@@ -87,12 +87,12 @@ public class ProblemServlet extends BasicServlet {
     }
     problemSummary.generate(req, sb);
   }
-  
+
   private static void doProblemDetails(final HttpServletRequest req, StringBuilder sb, String tableId, Map<String,String> tidToNameMap) {
-    
+
     if (Monitor.getProblemException() != null)
       return;
-    
+
     ArrayList<ProblemReport> problemReports = new ArrayList<ProblemReport>();
     Iterator<ProblemReport> iter = tableId == null ? ProblemReports.getInstance(Monitor.getContext()).iterator() : ProblemReports.getInstance(
         Monitor.getContext()).iterator(tableId);
@@ -109,7 +109,7 @@ public class ProblemServlet extends BasicServlet {
     problemTable.addSortableColumn("Exception");
     problemTable.addUnsortableColumn("Operations", new ClearProblemLinkType(req), null);
     for (ProblemReport pr : problemReports) {
-      
+
       TableRow row = problemTable.prepareRow();
       row.add(pr.getTableName());
       row.add(pr.getProblemType().name());
@@ -122,14 +122,14 @@ public class ProblemServlet extends BasicServlet {
     }
     problemTable.generate(req, sb);
   }
-  
+
   private static class TableProblemLinkType extends StringType<String> {
     private Map<String,String> tidToNameMap;
-    
+
     public TableProblemLinkType(Map<String,String> tidToNameMap) {
       this.tidToNameMap = tidToNameMap;
     }
-    
+
     @Override
     public String format(Object obj) {
       if (obj == null)
@@ -138,21 +138,21 @@ public class ProblemServlet extends BasicServlet {
       return String.format("<a href='/problems?table=%s'>%s</a>", encode(table), encode((Tables.getPrintableTableNameFromId(tidToNameMap, table))));
     }
   }
-  
+
   private static class ClearTableProblemsLinkType extends StringType<String> {
     private HttpServletRequest req;
     private Map<String,String> tidToNameMap;
-    
+
     public ClearTableProblemsLinkType(HttpServletRequest req, Map<String,String> tidToNameMap) {
       this.req = req;
       this.tidToNameMap = tidToNameMap;
     }
-    
+
     @Override
     public String alignment() {
       return "right";
     }
-    
+
     @Override
     public String format(Object obj) {
       if (obj == null)
@@ -162,19 +162,19 @@ public class ProblemServlet extends BasicServlet {
           Tables.getPrintableTableNameFromId(tidToNameMap, table));
     }
   }
-  
+
   private static class ClearProblemLinkType extends CellType<ProblemReport> {
     private HttpServletRequest req;
-    
+
     public ClearProblemLinkType(HttpServletRequest req) {
       this.req = req;
     }
-    
+
     @Override
     public String alignment() {
       return "right";
     }
-    
+
     @Override
     public String format(Object obj) {
       if (obj == null)
@@ -183,11 +183,11 @@ public class ProblemServlet extends BasicServlet {
       return String.format("<a href='/op?table=%s&action=clearProblem&redir=%s&resource=%s&ptype=%s'>clear this problem</a>", encode(p.getTableName()),
           currentPage(req), encode(p.getResource()), encode(p.getProblemType().name()));
     }
-    
+
     @Override
     public int compare(ProblemReport o1, ProblemReport o2) {
       return 0;
     }
   }
-  
+
 }

http://git-wip-us.apache.org/repos/asf/accumulo/blob/6bc67602/server/monitor/src/main/java/org/apache/accumulo/monitor/servlets/ShellServlet.java
----------------------------------------------------------------------
diff --git a/server/monitor/src/main/java/org/apache/accumulo/monitor/servlets/ShellServlet.java b/server/monitor/src/main/java/org/apache/accumulo/monitor/servlets/ShellServlet.java
index 6b2b31f..55145f9 100644
--- a/server/monitor/src/main/java/org/apache/accumulo/monitor/servlets/ShellServlet.java
+++ b/server/monitor/src/main/java/org/apache/accumulo/monitor/servlets/ShellServlet.java
@@ -49,7 +49,7 @@ public class ShellServlet extends BasicServlet {
   protected String getTitle(HttpServletRequest req) {
     return "Shell";
   }
-  
+
   @Override
   protected void pageBody(HttpServletRequest req, HttpServletResponse response, StringBuilder sb) throws IOException {
     HttpSession session = req.getSession(true);
@@ -216,27 +216,27 @@ public class ShellServlet extends BasicServlet {
     return "<div id='login'><form method=POST action='" + requestURI + "'>"
         + "<table><tr><td>Mock:&nbsp</td><td><input type='checkbox' name='mock' value='mock'></td></tr>"
         + "<tr><td>Username:&nbsp;</td><td><input type='text' name='user'></td></tr>"
-        + "<tr><td>Password:&nbsp;</td><td><input type='password' name='pass'></td><td>"
-        + "<input type='hidden' name='" + CSRF_KEY + "' value='" + csrfToken + "'/><input type='submit' value='Enter'></td></tr></table></form></div>";
+        + "<tr><td>Password:&nbsp;</td><td><input type='password' name='pass'></td><td>" + "<input type='hidden' name='" + CSRF_KEY + "' value='" + csrfToken
+        + "'/><input type='submit' value='Enter'></td></tr></table></form></div>";
   }
-  
+
   private static class StringBuilderOutputStream extends OutputStream {
     StringBuilder sb = new StringBuilder();
-    
+
     @Override
     public void write(int b) throws IOException {
       sb.append((char) (0xff & b));
     }
-    
+
     public String get() {
       return sb.toString();
     }
-    
+
     public void clear() {
       sb.setLength(0);
     }
   }
-  
+
   private static class ShellExecutionThread extends InputStream implements Runnable {
     private Shell shell;
     StringBuilderOutputStream output;
@@ -244,7 +244,7 @@ public class ShellServlet extends BasicServlet {
     private int cmdIndex;
     private boolean done;
     private boolean readWait;
-    
+
     private ShellExecutionThread(String username, String password, String mock) throws IOException {
       this.done = false;
       this.cmd = null;
@@ -261,7 +261,7 @@ public class ShellServlet extends BasicServlet {
         throw new IOException("shell config error");
       }
     }
-    
+
     @Override
     public synchronized int read() throws IOException {
       if (cmd == null) {
@@ -287,7 +287,7 @@ public class ShellServlet extends BasicServlet {
       }
       return c;
     }
-    
+
     @Override
     public synchronized void run() {
       Thread.currentThread().setName("shell thread");
@@ -308,7 +308,7 @@ public class ShellServlet extends BasicServlet {
       done = true;
       this.notifyAll();
     }
-    
+
     public synchronized void addInputString(String s) {
       if (done)
         throw new IllegalStateException("adding string to exited shell");
@@ -319,7 +319,7 @@ public class ShellServlet extends BasicServlet {
       }
       this.notifyAll();
     }
-    
+
     public synchronized void waitUntilReady() {
       while (cmd != null) {
         try {
@@ -327,29 +327,29 @@ public class ShellServlet extends BasicServlet {
         } catch (InterruptedException e) {}
       }
     }
-    
+
     public synchronized String getOutput() {
       String s = output.get();
       output.clear();
       return s;
     }
-    
+
     public String getPrompt() {
       return shell.getDefaultPrompt();
     }
-    
+
     public void printInfo() throws IOException {
       shell.printInfo();
     }
-    
+
     public boolean isMasking() {
       return shell.isMasking();
     }
-    
+
     public synchronized boolean isWaitingForInput() {
       return readWait;
     }
-    
+
     public boolean isDone() {
       return done;
     }

http://git-wip-us.apache.org/repos/asf/accumulo/blob/6bc67602/server/monitor/src/main/java/org/apache/accumulo/monitor/servlets/TServersServlet.java
----------------------------------------------------------------------
diff --git a/server/monitor/src/main/java/org/apache/accumulo/monitor/servlets/TServersServlet.java b/server/monitor/src/main/java/org/apache/accumulo/monitor/servlets/TServersServlet.java
index e7ab43d..47a2ca0 100644
--- a/server/monitor/src/main/java/org/apache/accumulo/monitor/servlets/TServersServlet.java
+++ b/server/monitor/src/main/java/org/apache/accumulo/monitor/servlets/TServersServlet.java
@@ -57,30 +57,30 @@ import org.apache.accumulo.server.util.TableInfoUtil;
 import com.google.common.net.HostAndPort;
 
 public class TServersServlet extends BasicServlet {
-  
+
   private static final long serialVersionUID = 1L;
   private static final TabletServerStatus NO_STATUS = new TabletServerStatus();
-  
+
   static class SecondType extends NumberType<Double> {
-    
+
     @Override
     public String format(Object obj) {
       if (obj == null)
         return "&mdash;";
       return Duration.format((long) (1000.0 * (Double) obj));
     }
-    
+
   }
-  
+
   @Override
   protected String getTitle(HttpServletRequest req) {
     return "Tablet Server Status";
   }
-  
+
   @Override
   protected void pageBody(HttpServletRequest req, HttpServletResponse response, StringBuilder sb) throws Exception {
     String tserverAddress = req.getParameter("s");
-    
+
     // Check to make sure tserver is a known address
     boolean tserverExists = false;
     if (tserverAddress != null && tserverAddress.isEmpty() == false) {
@@ -91,23 +91,23 @@ public class TServersServlet extends BasicServlet {
         }
       }
     }
-    
+
     if (tserverAddress == null || tserverAddress.isEmpty() || tserverExists == false) {
       doBadTserverList(req, sb);
-      
+
       doDeadTserverList(req, sb);
-      
+
       ArrayList<TabletServerStatus> tservers = new ArrayList<TabletServerStatus>();
       if (Monitor.getMmi() != null)
         tservers.addAll(Monitor.getMmi().tServerInfo);
-      
+
       Table tServerList = new Table("tservers", "Tablet&nbsp;Servers");
       tServerList.setSubCaption("Click on the <span style='color: #0000ff;'>server address</span> to view detailed performance statistics for that server.");
-      
+
       doTserverList(req, sb, tservers, null, tServerList);
       return;
     }
-    
+
     double totalElapsedForAll = 0;
     double splitStdDev = 0;
     double minorStdDev = 0;
@@ -119,7 +119,7 @@ public class TServersServlet extends BasicServlet {
     double currentMinorStdDev = 0;
     double currentMajorStdDev = 0;
     TabletStats total = new TabletStats(null, new ActionStats(), new ActionStats(), new ActionStats(), 0, 0, 0, 0);
-    
+
     HostAndPort address = HostAndPort.fromString(tserverAddress);
     TabletStats historical = new TabletStats(null, new ActionStats(), new ActionStats(), new ActionStats(), 0, 0, 0, 0);
     List<TabletStats> tsStats = new ArrayList<TabletStats>();
@@ -139,7 +139,7 @@ public class TServersServlet extends BasicServlet {
       log.error(e, e);
       return;
     }
-    
+
     Table perTabletResults = new Table("perTabletResults", "Detailed&nbsp;Current&nbsp;Operations");
     perTabletResults.setSubCaption("Per-tablet&nbsp;Details");
     perTabletResults.addSortableColumn("Table", new TableLinkType(), null);
@@ -153,7 +153,7 @@ public class TServersServlet extends BasicServlet {
     perTabletResults.addSortableColumn("Major&nbsp;Avg", new SecondType(), null);
     perTabletResults.addSortableColumn("Major&nbsp;Std&nbsp;Dev", new SecondType(), null);
     perTabletResults.addSortableColumn("Major&nbsp;Avg&nbsp;e/s", new NumberType<Double>(), null);
-    
+
     for (TabletStats info : tsStats) {
       if (info.extent == null) {
         historical = info;
@@ -162,7 +162,7 @@ public class TServersServlet extends BasicServlet {
       total.numEntries += info.numEntries;
       ActionStatsUpdator.update(total.minors, info.minors);
       ActionStatsUpdator.update(total.majors, info.majors);
-      
+
       KeyExtent extent = new KeyExtent(info.extent);
       String tableId = extent.getTableId().toString();
       MessageDigest digester = MessageDigest.getInstance("MD5");
@@ -171,7 +171,7 @@ public class TServersServlet extends BasicServlet {
       }
       String obscuredExtent = Base64.encodeBase64String(digester.digest());
       String displayExtent = String.format("<code>[%s]</code>", obscuredExtent);
-      
+
       TableRow row = perTabletResults.prepareRow();
       row.add(tableId);
       row.add(displayExtent);
@@ -186,7 +186,7 @@ public class TServersServlet extends BasicServlet {
       row.add(info.majors.elapsed != 0 ? info.majors.count / info.majors.elapsed : null);
       perTabletResults.addRow(row);
     }
-    
+
     // Calculate current averages oldServer adding in historical data
     if (total.minors.num != 0)
       currentMinorAvg = (long) (total.minors.elapsed / total.minors.num);
@@ -196,25 +196,25 @@ public class TServersServlet extends BasicServlet {
       currentMajorAvg = total.majors.elapsed / total.majors.num;
     if (total.majors.elapsed != 0 && total.majors.num != 0 && total.majors.elapsed > total.majors.num)
       currentMajorStdDev = stddev(total.majors.elapsed, total.majors.num, total.majors.sumDev);
-    
+
     // After these += operations, these variables are now total for current
     // tablets and historical tablets
     ActionStatsUpdator.update(total.minors, historical.minors);
     ActionStatsUpdator.update(total.majors, historical.majors);
     totalElapsedForAll += total.majors.elapsed + historical.splits.elapsed + total.minors.elapsed;
-    
+
     minorStdDev = stddev(total.minors.elapsed, total.minors.num, total.minors.sumDev);
     minorQueueStdDev = stddev(total.minors.queueTime, total.minors.num, total.minors.queueSumDev);
     majorStdDev = stddev(total.majors.elapsed, total.majors.num, total.majors.sumDev);
     majorQueueStdDev = stddev(total.majors.queueTime, total.majors.num, total.majors.queueSumDev);
     splitStdDev = stddev(historical.splits.num, historical.splits.elapsed, historical.splits.sumDev);
-    
+
     doDetailTable(req, sb, address, tsStats.size(), total, historical);
     doAllTimeTable(req, sb, total, historical, majorQueueStdDev, minorQueueStdDev, totalElapsedForAll, splitStdDev, majorStdDev, minorStdDev);
     doCurrentTabletOps(req, sb, currentMinorAvg, currentMinorStdDev, currentMajorAvg, currentMajorStdDev);
     perTabletResults.generate(req, sb);
   }
-  
+
   private void doCurrentTabletOps(HttpServletRequest req, StringBuilder sb, double currentMinorAvg, double currentMinorStdDev, double currentMajorAvg,
       double currentMajorStdDev) {
     Table currentTabletOps = new Table("currentTabletOps", "Current&nbsp;Tablet&nbsp;Operation&nbsp;Results");
@@ -225,10 +225,10 @@ public class TServersServlet extends BasicServlet {
     currentTabletOps.addRow(currentMinorAvg, currentMinorStdDev, currentMajorAvg, currentMajorStdDev);
     currentTabletOps.generate(req, sb);
   }
-  
+
   private void doAllTimeTable(HttpServletRequest req, StringBuilder sb, TabletStats total, TabletStats historical, double majorQueueStdDev,
       double minorQueueStdDev, double totalElapsedForAll, double splitStdDev, double majorStdDev, double minorStdDev) {
-    
+
     Table opHistoryDetails = new Table("opHistoryDetails", "All-Time&nbsp;Tablet&nbsp;Operation&nbsp;Results");
     opHistoryDetails.addSortableColumn("Operation");
     opHistoryDetails.addSortableColumn("Success", new NumberType<Integer>(), null);
@@ -238,7 +238,7 @@ public class TServersServlet extends BasicServlet {
     opHistoryDetails.addSortableColumn("Average<br />Time", new SecondType(), null);
     opHistoryDetails.addSortableColumn("Std.&nbsp;Dev.<br />Time", new SecondType(), null);
     opHistoryDetails.addSortableColumn("Percentage&nbsp;Time&nbsp;Spent", new ProgressChartType(totalElapsedForAll), null);
-    
+
     opHistoryDetails.addRow("Split", historical.splits.num, historical.splits.fail, null, null,
         historical.splits.num != 0 ? (historical.splits.elapsed / historical.splits.num) : null, splitStdDev, historical.splits.elapsed);
     opHistoryDetails.addRow("Major&nbsp;Compaction", total.majors.num, total.majors.fail, total.majors.num != 0 ? (total.majors.queueTime / total.majors.num)
@@ -247,7 +247,7 @@ public class TServersServlet extends BasicServlet {
         : null, minorQueueStdDev, total.minors.num != 0 ? (total.minors.elapsed / total.minors.num) : null, minorStdDev, total.minors.elapsed);
     opHistoryDetails.generate(req, sb);
   }
-  
+
   private void doDetailTable(HttpServletRequest req, StringBuilder sb, HostAndPort address, int numTablets, TabletStats total, TabletStats historical) {
     Table detailTable = new Table("tServerDetail", "Details");
     detailTable.setSubCaption(address.getHostText() + ":" + address.getPort());
@@ -259,7 +259,7 @@ public class TServersServlet extends BasicServlet {
     detailTable.addRow(numTablets, total.numEntries, total.minors.status, total.majors.status, historical.splits.status);
     detailTable.generate(req, sb);
   }
-  
+
   /*
    * omg there's so much undocumented stuff going on here. First, sumDev is a partial standard deviation computation. It is the (clue 1) sum of the squares of
    * (clue 2) seconds of elapsed time.
@@ -271,7 +271,7 @@ public class TServersServlet extends BasicServlet {
     }
     return 0;
   }
-  
+
   private void doBadTserverList(HttpServletRequest req, StringBuilder sb) {
     if (Monitor.getMmi() != null && !Monitor.getMmi().badTServers.isEmpty()) {
       Table badTServerList = new Table("badtservers", "Non-Functioning&nbsp;Tablet&nbsp;Servers", "error");
@@ -283,7 +283,7 @@ public class TServersServlet extends BasicServlet {
       badTServerList.generate(req, sb);
     }
   }
-  
+
   private void doDeadTserverList(HttpServletRequest req, StringBuilder sb) {
     MasterMonitorInfo mmi = Monitor.getMmi();
     if (mmi != null) {
@@ -293,7 +293,7 @@ public class TServersServlet extends BasicServlet {
       doDeadServerTable(req, sb, deadTServerList, obit);
     }
   }
-  
+
   public static void doDeadServerTable(HttpServletRequest req, StringBuilder sb, Table deadTServerList, List<DeadServer> obit) {
     if (obit != null && !obit.isEmpty()) {
       deadTServerList.addSortableColumn("Server");
@@ -306,11 +306,11 @@ public class TServersServlet extends BasicServlet {
       deadTServerList.generate(req, sb);
     }
   }
-  
+
   static void doTserverList(HttpServletRequest req, StringBuilder sb, List<TabletServerStatus> tservers, String tableId, Table tServerList) {
     int guessHighLoad = ManagementFactory.getOperatingSystemMXBean().getAvailableProcessors();
     long now = System.currentTimeMillis();
-    
+
     double avgLastContact = 0.;
     for (TabletServerStatus status : tservers) {
       avgLastContact += (now - status.lastContact);
@@ -336,7 +336,7 @@ public class TServersServlet extends BasicServlet {
     tServerList.addSortableColumn("Data Cache<br />Hit Rate", new PercentageType(), "The recent data cache hit rate.");
     tServerList.addSortableColumn("OS&nbsp;Load", new NumberType<Double>(0., guessHighLoad * 1., 0., guessHighLoad * 3.),
         "The Unix one minute load average. The average number of processes in the run queue over a one minute interval.");
-    
+
     log.debug("tableId: " + tableId);
     for (TabletServerStatus status : tservers) {
       if (status == null)
@@ -366,5 +366,5 @@ public class TServersServlet extends BasicServlet {
     }
     tServerList.generate(req, sb);
   }
-  
+
 }

http://git-wip-us.apache.org/repos/asf/accumulo/blob/6bc67602/server/monitor/src/main/java/org/apache/accumulo/monitor/servlets/TablesServlet.java
----------------------------------------------------------------------
diff --git a/server/monitor/src/main/java/org/apache/accumulo/monitor/servlets/TablesServlet.java b/server/monitor/src/main/java/org/apache/accumulo/monitor/servlets/TablesServlet.java
index e5914f9..3700874 100644
--- a/server/monitor/src/main/java/org/apache/accumulo/monitor/servlets/TablesServlet.java
+++ b/server/monitor/src/main/java/org/apache/accumulo/monitor/servlets/TablesServlet.java
@@ -50,35 +50,35 @@ import org.apache.accumulo.server.util.TableInfoUtil;
 import org.apache.hadoop.io.Text;
 
 public class TablesServlet extends BasicServlet {
-  
+
   private static final long serialVersionUID = 1L;
-  
+
   @Override
   protected String getTitle(HttpServletRequest req) {
     return "Table Status";
   }
-  
+
   @Override
   protected void pageBody(HttpServletRequest req, HttpServletResponse response, StringBuilder sb) throws Exception {
     Map<String,String> tidToNameMap = Tables.getIdToNameMap(Monitor.getContext().getInstance());
     String tableId = req.getParameter("t");
-    
+
     doProblemsBanner(sb);
-    
+
     if (tableId == null || tableId.isEmpty() || tidToNameMap.containsKey(tableId) == false) {
       doTableList(req, sb, tidToNameMap);
       return;
     }
-    
+
     doTableDetails(req, sb, tidToNameMap, tableId);
   }
-  
+
   static void doProblemsBanner(StringBuilder sb) {
     int numProblems = Monitor.getProblemSummary().entrySet().size();
     if (numProblems > 0)
       banner(sb, "error", String.format("<a href='/problems'>Table Problems: %d Total</a>", numProblems));
   }
-  
+
   static void doTableList(HttpServletRequest req, StringBuilder sb, Map<String,String> tidToNameMap) {
     Table tableList = new Table("tableList", "Table&nbsp;List");
     tableList.addSortableColumn("Table&nbsp;Name", new TableLinkType(), null);
@@ -107,14 +107,14 @@ public class TablesServlet extends BasicServlet {
             + "Major Compactions are performed as a consequence of new files created from Minor Compactions and Bulk Load operations.  "
             + "They reduce the number of files used during queries.");
     SortedMap<String,TableInfo> tableStats = new TreeMap<String,TableInfo>();
-    
+
     if (Monitor.getMmi() != null && Monitor.getMmi().tableMap != null)
       for (Entry<String,TableInfo> te : Monitor.getMmi().tableMap.entrySet())
         tableStats.put(Tables.getPrintableTableNameFromId(tidToNameMap, te.getKey()), te.getValue());
-    
+
     Map<String,Double> compactingByTable = TableInfoUtil.summarizeTableStats(Monitor.getMmi());
     TableManager tableManager = TableManager.getInstance();
-    
+
     for (Entry<String,String> tableName_tableId : Tables.getNameToIdMap(Monitor.getContext().getInstance()).entrySet()) {
       String tableName = tableName_tableId.getKey();
       String tableId = tableName_tableId.getValue();
@@ -138,10 +138,10 @@ public class TablesServlet extends BasicServlet {
       row.add(tableInfo);
       tableList.addRow(row);
     }
-    
+
     tableList.generate(req, sb);
   }
-  
+
   private void doTableDetails(HttpServletRequest req, StringBuilder sb, Map<String,String> tidToNameMap, String tableId) {
     String displayName = Tables.getPrintableTableNameFromId(tidToNameMap, tableId);
     Instance instance = Monitor.getContext().getInstance();
@@ -152,7 +152,7 @@ public class TablesServlet extends BasicServlet {
       String systemTableName = MetadataTable.ID.equals(tableId) ? RootTable.NAME : MetadataTable.NAME;
       MetaDataTableScanner scanner = new MetaDataTableScanner(Monitor.getContext(), new Range(KeyExtent.getMetadataEntry(new Text(tableId), new Text()),
           KeyExtent.getMetadataEntry(new Text(tableId), null)), systemTableName);
-      
+
       while (scanner.hasNext()) {
         TabletLocationState state = scanner.next();
         if (state.current != null) {
@@ -165,9 +165,9 @@ public class TablesServlet extends BasicServlet {
       }
       scanner.close();
     }
-    
+
     log.debug("Locs: " + locs);
-    
+
     List<TabletServerStatus> tservers = new ArrayList<TabletServerStatus>();
     if (Monitor.getMmi() != null) {
       for (TabletServerStatus tss : Monitor.getMmi().tServerInfo) {
@@ -180,7 +180,7 @@ public class TablesServlet extends BasicServlet {
         }
       }
     }
-    
+
     Table tableDetails = new Table("participatingTServers", "Participating&nbsp;Tablet&nbsp;Servers");
     tableDetails.setSubCaption(displayName);
     TServersServlet.doTserverList(req, sb, tservers, tableId, tableDetails);

http://git-wip-us.apache.org/repos/asf/accumulo/blob/6bc67602/server/monitor/src/main/java/org/apache/accumulo/monitor/servlets/VisServlet.java
----------------------------------------------------------------------
diff --git a/server/monitor/src/main/java/org/apache/accumulo/monitor/servlets/VisServlet.java b/server/monitor/src/main/java/org/apache/accumulo/monitor/servlets/VisServlet.java
index af1688e..eedf598 100644
--- a/server/monitor/src/main/java/org/apache/accumulo/monitor/servlets/VisServlet.java
+++ b/server/monitor/src/main/java/org/apache/accumulo/monitor/servlets/VisServlet.java
@@ -29,9 +29,9 @@ import org.apache.accumulo.monitor.Monitor;
 
 public class VisServlet extends BasicServlet {
   private static final int concurrentScans = Monitor.getContext().getConfiguration().getCount(Property.TSERV_READ_AHEAD_MAXCONCURRENT);
-  
+
   private static final long serialVersionUID = 1L;
-  
+
   public enum StatType {
     osload(ManagementFactory.getOperatingSystemMXBean().getAvailableProcessors(), true, 100, "OS Load"),
     ingest(1000, true, 1, "Ingest Entries"),
@@ -43,13 +43,13 @@ public class VisServlet extends BasicServlet {
     holdtime(60000, false, 1, "Hold Time"),
     allavg(1, false, 100, "Overall Avg", true),
     allmax(1, false, 100, "Overall Max", true);
-    
+
     private int max;
     private boolean adjustMax;
     private float significance;
     private String description;
     private boolean derived;
-    
+
     /**
      * @param max
      *          initial estimate of largest possible value for this stat
@@ -63,7 +63,7 @@ public class VisServlet extends BasicServlet {
     private StatType(int max, boolean adjustMax, float significance, String description) {
       this(max, adjustMax, significance, description, false);
     }
-    
+
     private StatType(int max, boolean adjustMax, float significance, String description, boolean derived) {
       this.max = max;
       this.adjustMax = adjustMax;
@@ -71,27 +71,27 @@ public class VisServlet extends BasicServlet {
       this.description = description;
       this.derived = derived;
     }
-    
+
     public int getMax() {
       return max;
     }
-    
+
     public boolean getAdjustMax() {
       return adjustMax;
     }
-    
+
     public float getSignificance() {
       return significance;
     }
-    
+
     public String getDescription() {
       return description;
     }
-    
+
     public boolean isDerived() {
       return derived;
     }
-    
+
     public static int numDerived() {
       int count = 0;
       for (StatType st : StatType.values())
@@ -100,7 +100,7 @@ public class VisServlet extends BasicServlet {
       return count;
     }
   }
-  
+
   public static class VisualizationConfig {
     boolean useCircles = true;
     StatType motion = StatType.allmax;
@@ -108,38 +108,38 @@ public class VisServlet extends BasicServlet {
     int spacing = 40;
     String url;
   }
-  
+
   @Override
   protected String getTitle(HttpServletRequest req) {
     return "Server Activity";
   }
-  
+
   @Override
   protected void pageBody(HttpServletRequest req, HttpServletResponse response, StringBuilder sb) throws IOException {
     StringBuffer urlsb = req.getRequestURL();
     urlsb.setLength(urlsb.lastIndexOf("/") + 1);
     VisualizationConfig cfg = new VisualizationConfig();
     cfg.url = urlsb.toString();
-    
+
     String s = req.getParameter("shape");
     if (s != null && (s.equals("square") || s.equals("squares"))) {
       cfg.useCircles = false;
     }
-    
+
     s = req.getParameter("motion");
     if (s != null) {
       try {
         cfg.motion = StatType.valueOf(s);
       } catch (Exception e) {}
     }
-    
+
     s = req.getParameter("color");
     if (s != null) {
       try {
         cfg.color = StatType.valueOf(s);
       } catch (Exception e) {}
     }
-    
+
     String size = req.getParameter("size");
     if (size != null) {
       if (size.equals("10"))
@@ -149,20 +149,20 @@ public class VisServlet extends BasicServlet {
       else if (size.equals("80"))
         cfg.spacing = 80;
     }
-    
+
     ArrayList<TabletServerStatus> tservers = new ArrayList<TabletServerStatus>();
     if (Monitor.getMmi() != null)
       tservers.addAll(Monitor.getMmi().tServerInfo);
-    
+
     if (tservers.size() == 0)
       return;
-    
+
     int width = (int) Math.ceil(Math.sqrt(tservers.size())) * cfg.spacing;
-    int height = (int) Math.ceil(tservers.size() / (double)width) * cfg.spacing;
+    int height = (int) Math.ceil(tservers.size() / (double) width) * cfg.spacing;
     doSettings(sb, cfg, width < 640 ? 640 : width, height < 640 ? 640 : height);
     doScript(sb, cfg, tservers);
   }
-  
+
   private void doSettings(StringBuilder sb, VisualizationConfig cfg, int width, int height) {
     sb.append("<div class='left'>\n");
     sb.append("<div id='parameters' class='nowrap'>\n");
@@ -193,13 +193,13 @@ public class VisServlet extends BasicServlet {
     sb.append("</div>\n");
     sb.append("</div>\n\n");
   }
-  
+
   private void addOptions(StringBuilder sb, StatType selectedStatType) {
     for (StatType st : StatType.values()) {
       sb.append("<option").append(st.equals(selectedStatType) ? " selected='true'>" : ">").append(st.getDescription()).append("</option>");
     }
   }
-  
+
   private void doScript(StringBuilder sb, VisualizationConfig cfg, ArrayList<TabletServerStatus> tservers) {
     // initialization of some javascript variables
     sb.append("<script type='text/javascript'>\n");
@@ -230,7 +230,7 @@ public class VisServlet extends BasicServlet {
     sb.append("}; // values will be converted by floor(this*value)/this\n");
     sb.append("var numNormalStats = ").append(StatType.values().length - StatType.numDerived()).append(";\n");
     sb.append("</script>\n");
-    
+
     sb.append("<script src='web/vis.js' type='text/javascript'></script>");
   }
 }

http://git-wip-us.apache.org/repos/asf/accumulo/blob/6bc67602/server/monitor/src/main/java/org/apache/accumulo/monitor/servlets/XMLServlet.java
----------------------------------------------------------------------
diff --git a/server/monitor/src/main/java/org/apache/accumulo/monitor/servlets/XMLServlet.java b/server/monitor/src/main/java/org/apache/accumulo/monitor/servlets/XMLServlet.java
index 3b115f9..1662069 100644
--- a/server/monitor/src/main/java/org/apache/accumulo/monitor/servlets/XMLServlet.java
+++ b/server/monitor/src/main/java/org/apache/accumulo/monitor/servlets/XMLServlet.java
@@ -38,40 +38,40 @@ import org.apache.accumulo.server.util.TableInfoUtil;
 
 public class XMLServlet extends BasicServlet {
   private static final long serialVersionUID = 1L;
-  
+
   @Override
   protected String getTitle(HttpServletRequest req) {
     return "XML Report";
   }
-  
+
   @Override
   protected void pageStart(HttpServletRequest req, HttpServletResponse resp, StringBuilder sb) {
     resp.setContentType("text/xml;charset=" + UTF_8.name());
     sb.append("<?xml version=\"1.0\" encoding=\"" + UTF_8.name() + "\"?>\n");
     sb.append("<stats>\n");
   }
-  
+
   @Override
   protected void pageBody(HttpServletRequest req, HttpServletResponse resp, StringBuilder sb) {
     double totalIngest = 0.;
     double totalQuery = 0.;
     double disk = 0.0;
     long totalEntries = 0L;
-    
+
     sb.append("\n<servers>\n");
     if (Monitor.getMmi() == null || Monitor.getMmi().tableMap == null) {
       sb.append("</servers>\n");
       return;
     }
     SortedMap<String,TableInfo> tableStats = new TreeMap<String,TableInfo>(Monitor.getMmi().tableMap);
-    
+
     for (TabletServerStatus status : Monitor.getMmi().tServerInfo) {
-      
+
       sb.append("\n<server id='").append(status.name).append("'>\n");
       sb.append("<hostname>").append(TServerLinkType.displayName(status.name)).append("</hostname>");
       sb.append("<lastContact>").append(System.currentTimeMillis() - status.lastContact).append("</lastContact>\n");
       sb.append("<osload>").append(status.osLoad).append("</osload>\n");
-      
+
       TableInfo summary = TableInfoUtil.summarizeTableStats(status);
       sb.append("<compactions>\n");
       sb.append("<major>").append("<running>").append(summary.majors.running).append("</running>").append("<queued>").append(summary.majors.queued)
@@ -79,9 +79,9 @@ public class XMLServlet extends BasicServlet {
       sb.append("<minor>").append("<running>").append(summary.minors.running).append("</running>").append("<queued>").append(summary.minors.queued)
           .append("</queued>").append("</minor>\n");
       sb.append("</compactions>\n");
-      
+
       sb.append("<tablets>").append(summary.tablets).append("</tablets>\n");
-      
+
       sb.append("<ingest>").append(summary.ingestRate).append("</ingest>\n");
       sb.append("<query>").append(summary.queryRate).append("</query>\n");
       sb.append("<ingestMB>").append(summary.ingestByteRate / 1000000.0).append("</ingestMB>\n");
@@ -95,41 +95,41 @@ public class XMLServlet extends BasicServlet {
       sb.append("</server>\n");
     }
     sb.append("\n</servers>\n");
-    
+
     sb.append("\n<masterGoalState>" + Monitor.getMmi().goalState + "</masterGoalState>\n");
     sb.append("\n<masterState>" + Monitor.getMmi().state + "</masterState>\n");
-    
+
     sb.append("\n<badTabletServers>\n");
     for (Entry<String,Byte> entry : Monitor.getMmi().badTServers.entrySet()) {
       sb.append(String.format("<badTabletServer id='%s' status='%s'/>\n", entry.getKey(), TabletServerState.getStateById(entry.getValue())));
     }
     sb.append("\n</badTabletServers>\n");
-    
+
     sb.append("\n<tabletServersShuttingDown>\n");
     for (String server : Monitor.getMmi().serversShuttingDown) {
       sb.append(String.format("<server id='%s'/>\n", server));
     }
     sb.append("\n</tabletServersShuttingDown>\n");
-    
+
     sb.append(String.format("\n<unassignedTablets>%d</unassignedTablets>\n", Monitor.getMmi().unassignedTablets));
-    
+
     sb.append("\n<deadTabletServers>\n");
     for (DeadServer dead : Monitor.getMmi().deadTabletServers) {
       sb.append(String.format("<deadTabletServer id='%s' lastChange='%d' status='%s'/>\n", dead.server, dead.lastStatus, dead.status));
     }
     sb.append("\n</deadTabletServers>\n");
-    
+
     sb.append("\n<deadLoggers>\n");
     for (DeadServer dead : Monitor.getMmi().deadTabletServers) {
       sb.append(String.format("<deadLogger id='%s' lastChange='%d' status='%s'/>\n", dead.server, dead.lastStatus, dead.status));
     }
     sb.append("\n</deadLoggers>\n");
-    
+
     sb.append("\n<tables>\n");
     Instance instance = Monitor.getContext().getInstance();
     for (Entry<String,TableInfo> entry : tableStats.entrySet()) {
       TableInfo tableInfo = entry.getValue();
-      
+
       sb.append("\n<table>\n");
       String tableId = entry.getKey();
       String tableName = "unknown";
@@ -163,7 +163,7 @@ public class XMLServlet extends BasicServlet {
       sb.append("</table>\n");
     }
     sb.append("\n</tables>\n");
-    
+
     sb.append("\n<totals>\n");
     sb.append("<ingestrate>").append(totalIngest).append("</ingestrate>\n");
     sb.append("<queryrate>").append(totalQuery).append("</queryrate>\n");
@@ -171,7 +171,7 @@ public class XMLServlet extends BasicServlet {
     sb.append("<numentries>").append(totalEntries).append("</numentries>\n");
     sb.append("</totals>\n");
   }
-  
+
   @Override
   protected void pageEnd(HttpServletRequest req, HttpServletResponse resp, StringBuilder sb) {
     sb.append("\n</stats>\n");

http://git-wip-us.apache.org/repos/asf/accumulo/blob/6bc67602/server/monitor/src/main/java/org/apache/accumulo/monitor/servlets/trace/ListType.java
----------------------------------------------------------------------
diff --git a/server/monitor/src/main/java/org/apache/accumulo/monitor/servlets/trace/ListType.java b/server/monitor/src/main/java/org/apache/accumulo/monitor/servlets/trace/ListType.java
index 5ab3b2a..84322b5 100644
--- a/server/monitor/src/main/java/org/apache/accumulo/monitor/servlets/trace/ListType.java
+++ b/server/monitor/src/main/java/org/apache/accumulo/monitor/servlets/trace/ListType.java
@@ -33,17 +33,17 @@ import org.apache.accumulo.tracer.thrift.RemoteSpan;
 import org.apache.hadoop.io.Text;
 
 public class ListType extends Basic {
-  
+
   private static final long serialVersionUID = 1L;
-  
+
   String getType(HttpServletRequest req) {
     return getStringParameter(req, "type", "<Unknown>");
   }
-  
+
   int getMinutes(HttpServletRequest req) {
     return getIntParameter(req, "minutes", Summary.DEFAULT_MINUTES);
   }
-  
+
   @Override
   public void pageBody(HttpServletRequest req, HttpServletResponse resp, StringBuilder sb) throws Exception {
     String type = getType(req);
@@ -68,7 +68,7 @@ public class ListType extends Basic {
     }
     trace.generate(req, sb);
   }
-  
+
   @Override
   public String getTitle(HttpServletRequest req) {
     return "Traces for " + getType(req) + " for the last " + getMinutes(req) + " minutes";

http://git-wip-us.apache.org/repos/asf/accumulo/blob/6bc67602/server/monitor/src/main/java/org/apache/accumulo/monitor/servlets/trace/NullKeyValueIterator.java
----------------------------------------------------------------------
diff --git a/server/monitor/src/main/java/org/apache/accumulo/monitor/servlets/trace/NullKeyValueIterator.java b/server/monitor/src/main/java/org/apache/accumulo/monitor/servlets/trace/NullKeyValueIterator.java
index 26cfb07..1ec7bfc 100644
--- a/server/monitor/src/main/java/org/apache/accumulo/monitor/servlets/trace/NullKeyValueIterator.java
+++ b/server/monitor/src/main/java/org/apache/accumulo/monitor/servlets/trace/NullKeyValueIterator.java
@@ -23,17 +23,17 @@ import org.apache.accumulo.core.data.Key;
 import org.apache.accumulo.core.data.Value;
 
 public class NullKeyValueIterator implements Iterator<Entry<Key,Value>> {
-  
+
   @Override
   public boolean hasNext() {
     return false;
   }
-  
+
   @Override
   public Entry<Key,Value> next() {
     return null;
   }
-  
+
   @Override
   public void remove() {}
 }


Mime
View raw message