accumulo-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From e..@apache.org
Subject [3/6] ACCUMULO-2160 fixed up a lot of findbugs/pmd complaints
Date Wed, 08 Jan 2014 23:33:18 GMT
http://git-wip-us.apache.org/repos/asf/accumulo/blob/5bd4e27c/fate/src/main/java/org/apache/accumulo/fate/zookeeper/IZooReader.java
----------------------------------------------------------------------
diff --git a/fate/src/main/java/org/apache/accumulo/fate/zookeeper/IZooReader.java b/fate/src/main/java/org/apache/accumulo/fate/zookeeper/IZooReader.java
index 3902a5c..0610e79 100644
--- a/fate/src/main/java/org/apache/accumulo/fate/zookeeper/IZooReader.java
+++ b/fate/src/main/java/org/apache/accumulo/fate/zookeeper/IZooReader.java
@@ -24,20 +24,20 @@ import org.apache.zookeeper.data.Stat;
 
 public interface IZooReader {
   
-  public abstract byte[] getData(String zPath, Stat stat) throws KeeperException, InterruptedException;
+  byte[] getData(String zPath, Stat stat) throws KeeperException, InterruptedException;
   
-  public abstract Stat getStatus(String zPath) throws KeeperException, InterruptedException;
+  Stat getStatus(String zPath) throws KeeperException, InterruptedException;
   
-  public abstract Stat getStatus(String zPath, Watcher watcher) throws KeeperException, InterruptedException;
+  Stat getStatus(String zPath, Watcher watcher) throws KeeperException, InterruptedException;
   
-  public abstract List<String> getChildren(String zPath) throws KeeperException, InterruptedException;
+  List<String> getChildren(String zPath) throws KeeperException, InterruptedException;
   
-  public abstract List<String> getChildren(String zPath, Watcher watcher) throws KeeperException, InterruptedException;
+  List<String> getChildren(String zPath, Watcher watcher) throws KeeperException, InterruptedException;
   
-  public abstract boolean exists(String zPath) throws KeeperException, InterruptedException;
+  boolean exists(String zPath) throws KeeperException, InterruptedException;
   
-  public abstract boolean exists(String zPath, Watcher watcher) throws KeeperException, InterruptedException;
+  boolean exists(String zPath, Watcher watcher) throws KeeperException, InterruptedException;
   
-  public abstract void sync(final String path) throws KeeperException, InterruptedException;
+  void sync(final String path) throws KeeperException, InterruptedException;
   
 }

http://git-wip-us.apache.org/repos/asf/accumulo/blob/5bd4e27c/fate/src/main/java/org/apache/accumulo/fate/zookeeper/IZooReaderWriter.java
----------------------------------------------------------------------
diff --git a/fate/src/main/java/org/apache/accumulo/fate/zookeeper/IZooReaderWriter.java b/fate/src/main/java/org/apache/accumulo/fate/zookeeper/IZooReaderWriter.java
index a43ae7c..afc2250 100644
--- a/fate/src/main/java/org/apache/accumulo/fate/zookeeper/IZooReaderWriter.java
+++ b/fate/src/main/java/org/apache/accumulo/fate/zookeeper/IZooReaderWriter.java
@@ -26,43 +26,43 @@ import org.apache.zookeeper.data.ACL;
 
 public interface IZooReaderWriter extends IZooReader {
   
-  public abstract ZooKeeper getZooKeeper();
+  ZooKeeper getZooKeeper();
   
-  public abstract void recursiveDelete(String zPath, NodeMissingPolicy policy) throws KeeperException, InterruptedException;
+  void recursiveDelete(String zPath, NodeMissingPolicy policy) throws KeeperException, InterruptedException;
   
-  public abstract void recursiveDelete(String zPath, int version, NodeMissingPolicy policy) throws KeeperException, InterruptedException;
+  void recursiveDelete(String zPath, int version, NodeMissingPolicy policy) throws KeeperException, InterruptedException;
   
   /**
    * Create a persistent node with the default ACL
    * 
    * @return true if the node was created or altered; false if it was skipped
    */
-  public abstract boolean putPersistentData(String zPath, byte[] data, NodeExistsPolicy policy) throws KeeperException, InterruptedException;
+  boolean putPersistentData(String zPath, byte[] data, NodeExistsPolicy policy) throws KeeperException, InterruptedException;
   
-  public abstract boolean putPrivatePersistentData(String zPath, byte[] data, NodeExistsPolicy policy) throws KeeperException, InterruptedException;
+  boolean putPrivatePersistentData(String zPath, byte[] data, NodeExistsPolicy policy) throws KeeperException, InterruptedException;
   
-  public abstract void putPersistentData(String zPath, byte[] data, int version, NodeExistsPolicy policy) throws KeeperException, InterruptedException;
+  void putPersistentData(String zPath, byte[] data, int version, NodeExistsPolicy policy) throws KeeperException, InterruptedException;
   
-  public abstract String putPersistentSequential(String zPath, byte[] data) throws KeeperException, InterruptedException;
+  String putPersistentSequential(String zPath, byte[] data) throws KeeperException, InterruptedException;
   
-  public abstract String putEphemeralSequential(String zPath, byte[] data) throws KeeperException, InterruptedException;
+  String putEphemeralSequential(String zPath, byte[] data) throws KeeperException, InterruptedException;
   
-  public String putEphemeralData(String zPath, byte[] data) throws KeeperException, InterruptedException;
+  String putEphemeralData(String zPath, byte[] data) throws KeeperException, InterruptedException;
 
-  public abstract void recursiveCopyPersistent(String source, String destination, NodeExistsPolicy policy) throws KeeperException, InterruptedException;
+  void recursiveCopyPersistent(String source, String destination, NodeExistsPolicy policy) throws KeeperException, InterruptedException;
   
-  public abstract void delete(String path, int version) throws InterruptedException, KeeperException;
+  void delete(String path, int version) throws InterruptedException, KeeperException;
   
-  public interface Mutator {
+  interface Mutator {
     byte[] mutate(byte[] currentValue) throws Exception;
   }
   
-  public abstract byte[] mutate(String zPath, byte[] createValue, List<ACL> acl, Mutator mutator) throws Exception;
+  byte[] mutate(String zPath, byte[] createValue, List<ACL> acl, Mutator mutator) throws Exception;
   
-  public abstract boolean isLockHeld(ZooUtil.LockID lockID) throws KeeperException, InterruptedException;
+  boolean isLockHeld(ZooUtil.LockID lockID) throws KeeperException, InterruptedException;
   
-  public abstract void mkdirs(String path) throws KeeperException, InterruptedException;
+  void mkdirs(String path) throws KeeperException, InterruptedException;
   
-  public abstract void sync(String path) throws KeeperException, InterruptedException;
+  void sync(String path) throws KeeperException, InterruptedException;
   
 }

http://git-wip-us.apache.org/repos/asf/accumulo/blob/5bd4e27c/fate/src/main/java/org/apache/accumulo/fate/zookeeper/TransactionWatcher.java
----------------------------------------------------------------------
diff --git a/fate/src/main/java/org/apache/accumulo/fate/zookeeper/TransactionWatcher.java b/fate/src/main/java/org/apache/accumulo/fate/zookeeper/TransactionWatcher.java
index 856d43b..cc4bebf 100644
--- a/fate/src/main/java/org/apache/accumulo/fate/zookeeper/TransactionWatcher.java
+++ b/fate/src/main/java/org/apache/accumulo/fate/zookeeper/TransactionWatcher.java
@@ -25,15 +25,15 @@ import org.apache.log4j.Logger;
 
 public class TransactionWatcher {
   
-  private static final Logger log = Logger.getLogger(TransactionWatcher.class);
-  final private Map<Long,AtomicInteger> counts = new HashMap<Long,AtomicInteger>();
-  final private Arbitrator arbitrator;
-  
   public interface Arbitrator {
     boolean transactionAlive(String type, long tid) throws Exception;
     boolean transactionComplete(String type, long tid) throws Exception;
   }
   
+  private static final Logger log = Logger.getLogger(TransactionWatcher.class);
+  final private Map<Long,AtomicInteger> counts = new HashMap<Long,AtomicInteger>();
+  final private Arbitrator arbitrator;
+  
   public TransactionWatcher(Arbitrator arbitrator) {
     this.arbitrator = arbitrator;
   }

http://git-wip-us.apache.org/repos/asf/accumulo/blob/5bd4e27c/fate/src/main/java/org/apache/accumulo/fate/zookeeper/ZooCache.java
----------------------------------------------------------------------
diff --git a/fate/src/main/java/org/apache/accumulo/fate/zookeeper/ZooCache.java b/fate/src/main/java/org/apache/accumulo/fate/zookeeper/ZooCache.java
index e57b0b6..489dc98 100644
--- a/fate/src/main/java/org/apache/accumulo/fate/zookeeper/ZooCache.java
+++ b/fate/src/main/java/org/apache/accumulo/fate/zookeeper/ZooCache.java
@@ -114,7 +114,7 @@ public class ZooCache {
     this.externalWatcher = watcher;
   }
 
-  private static interface ZooRunnable {
+  private interface ZooRunnable {
     void run(ZooKeeper zooKeeper) throws KeeperException, InterruptedException;
   }
 

http://git-wip-us.apache.org/repos/asf/accumulo/blob/5bd4e27c/fate/src/main/java/org/apache/accumulo/fate/zookeeper/ZooLock.java
----------------------------------------------------------------------
diff --git a/fate/src/main/java/org/apache/accumulo/fate/zookeeper/ZooLock.java b/fate/src/main/java/org/apache/accumulo/fate/zookeeper/ZooLock.java
index 8772a83..3240862 100644
--- a/fate/src/main/java/org/apache/accumulo/fate/zookeeper/ZooLock.java
+++ b/fate/src/main/java/org/apache/accumulo/fate/zookeeper/ZooLock.java
@@ -346,9 +346,7 @@ public class ZooLock implements Watcher {
     watchingParent = false;
 
     if (event.getState() == KeeperState.Expired && lock != null) {
-      if (lock != null) {
         lostLock(LockLossReason.SESSION_EXPIRED);
-      }
     } else {
       
       try { // set the watch on the parent node again

http://git-wip-us.apache.org/repos/asf/accumulo/blob/5bd4e27c/fate/src/main/java/org/apache/accumulo/fate/zookeeper/ZooReaderWriter.java
----------------------------------------------------------------------
diff --git a/fate/src/main/java/org/apache/accumulo/fate/zookeeper/ZooReaderWriter.java b/fate/src/main/java/org/apache/accumulo/fate/zookeeper/ZooReaderWriter.java
index 13c3c1a..2a327b0 100644
--- a/fate/src/main/java/org/apache/accumulo/fate/zookeeper/ZooReaderWriter.java
+++ b/fate/src/main/java/org/apache/accumulo/fate/zookeeper/ZooReaderWriter.java
@@ -21,6 +21,7 @@ import java.lang.reflect.InvocationTargetException;
 import java.lang.reflect.Method;
 import java.lang.reflect.Proxy;
 import java.security.SecurityPermission;
+import java.util.Arrays;
 import java.util.List;
 
 import org.apache.accumulo.fate.util.UtilWaitThread;
@@ -56,7 +57,7 @@ public class ZooReaderWriter extends ZooReader implements IZooReaderWriter {
   public ZooReaderWriter(String string, int timeInMillis, String scheme, byte[] auth) {
     super(string, timeInMillis);
     this.scheme = scheme;
-    this.auth = auth;
+    this.auth = Arrays.copyOf(auth, auth.length);
   }
   
   @Override

http://git-wip-us.apache.org/repos/asf/accumulo/blob/5bd4e27c/fate/src/main/java/org/apache/accumulo/fate/zookeeper/ZooReservation.java
----------------------------------------------------------------------
diff --git a/fate/src/main/java/org/apache/accumulo/fate/zookeeper/ZooReservation.java b/fate/src/main/java/org/apache/accumulo/fate/zookeeper/ZooReservation.java
index e938e88..655f382 100644
--- a/fate/src/main/java/org/apache/accumulo/fate/zookeeper/ZooReservation.java
+++ b/fate/src/main/java/org/apache/accumulo/fate/zookeeper/ZooReservation.java
@@ -45,7 +45,7 @@ public class ZooReservation {
         
         String idInZoo = new String(zooData).split(":")[0];
         
-        return idInZoo.equals(new String(reservationID));
+        return idInZoo.equals(reservationID);
       }
     }
     
@@ -65,8 +65,8 @@ public class ZooReservation {
     
     String idInZoo = new String(zooData).split(":")[0];
     
-    if (!idInZoo.equals(new String(reservationID))) {
-      throw new IllegalStateException("Tried to release reservation " + path + " with data mismatch " + new String(reservationID) + " " + new String(zooData));
+    if (!idInZoo.equals(reservationID)) {
+      throw new IllegalStateException("Tried to release reservation " + path + " with data mismatch " + reservationID + " " + new String(zooData));
     }
     
     zk.recursiveDelete(path, stat.getVersion(), NodeMissingPolicy.SKIP);

http://git-wip-us.apache.org/repos/asf/accumulo/blob/5bd4e27c/fate/src/main/java/org/apache/accumulo/fate/zookeeper/ZooSession.java
----------------------------------------------------------------------
diff --git a/fate/src/main/java/org/apache/accumulo/fate/zookeeper/ZooSession.java b/fate/src/main/java/org/apache/accumulo/fate/zookeeper/ZooSession.java
index 7fdd0a1..2a751cf 100644
--- a/fate/src/main/java/org/apache/accumulo/fate/zookeeper/ZooSession.java
+++ b/fate/src/main/java/org/apache/accumulo/fate/zookeeper/ZooSession.java
@@ -67,7 +67,7 @@ public class ZooSession {
     final int TIME_BETWEEN_CONNECT_CHECKS_MS = 100;
     int connectTimeWait = Math.min(10 * 1000, timeout);
     boolean tryAgain = true;
-    int sleepTime = 100;
+    long sleepTime = 100;
     ZooKeeper zooKeeper = null;
     
     long startTime = System.currentTimeMillis();
@@ -106,7 +106,7 @@ public class ZooSession {
       
       if (tryAgain) {
         if (startTime + 2 * timeout < System.currentTimeMillis() + sleepTime + connectTimeWait)
-          sleepTime = (int) (startTime + 2 * timeout - System.currentTimeMillis() - connectTimeWait);
+          sleepTime = startTime + 2 * timeout - System.currentTimeMillis() - connectTimeWait;
         if (sleepTime < 0)
         {
           connectTimeWait -= sleepTime; 
@@ -114,7 +114,7 @@ public class ZooSession {
         }
         UtilWaitThread.sleep(sleepTime);
         if (sleepTime < 10000)
-          sleepTime = (int) (sleepTime + sleepTime * Math.random());
+          sleepTime = sleepTime + (long)(sleepTime * Math.random());
       }
     }
     

http://git-wip-us.apache.org/repos/asf/accumulo/blob/5bd4e27c/minicluster/src/main/java/org/apache/accumulo/minicluster/MiniAccumuloCluster.java
----------------------------------------------------------------------
diff --git a/minicluster/src/main/java/org/apache/accumulo/minicluster/MiniAccumuloCluster.java b/minicluster/src/main/java/org/apache/accumulo/minicluster/MiniAccumuloCluster.java
index 6a8d24e..2ed2434 100644
--- a/minicluster/src/main/java/org/apache/accumulo/minicluster/MiniAccumuloCluster.java
+++ b/minicluster/src/main/java/org/apache/accumulo/minicluster/MiniAccumuloCluster.java
@@ -586,8 +586,8 @@ public class MiniAccumuloCluster {
     if (masterProcess != null) {
       masterProcess.destroy();
     }
-    synchronized (tabletServerProcesses) {
-      if (tabletServerProcesses != null) {
+    if (tabletServerProcesses != null) {
+      synchronized (tabletServerProcesses) {
         for (Process tserver : tabletServerProcesses) {
           tserver.destroy();
         }

http://git-wip-us.apache.org/repos/asf/accumulo/blob/5bd4e27c/minicluster/src/main/java/org/apache/accumulo/minicluster/ProcessReference.java
----------------------------------------------------------------------
diff --git a/minicluster/src/main/java/org/apache/accumulo/minicluster/ProcessReference.java b/minicluster/src/main/java/org/apache/accumulo/minicluster/ProcessReference.java
index 5c801e4..b033c0d 100644
--- a/minicluster/src/main/java/org/apache/accumulo/minicluster/ProcessReference.java
+++ b/minicluster/src/main/java/org/apache/accumulo/minicluster/ProcessReference.java
@@ -39,6 +39,9 @@ public class ProcessReference {
 
   @Override
   public boolean equals(Object obj) {
-    return process.equals(obj);
+    if (obj instanceof Process) {
+      return process == obj;
+    }
+    return this == obj;
   }
 }

http://git-wip-us.apache.org/repos/asf/accumulo/blob/5bd4e27c/minicluster/src/test/java/org/apache/accumulo/minicluster/MiniAccumuloClusterGCTest.java
----------------------------------------------------------------------
diff --git a/minicluster/src/test/java/org/apache/accumulo/minicluster/MiniAccumuloClusterGCTest.java b/minicluster/src/test/java/org/apache/accumulo/minicluster/MiniAccumuloClusterGCTest.java
index a29bbc0..86a8950 100644
--- a/minicluster/src/test/java/org/apache/accumulo/minicluster/MiniAccumuloClusterGCTest.java
+++ b/minicluster/src/test/java/org/apache/accumulo/minicluster/MiniAccumuloClusterGCTest.java
@@ -63,7 +63,7 @@ public class MiniAccumuloClusterGCTest {
   
       Assert.assertEquals(true, macConfig.shouldRunGC());
     } finally {
-      if (null != f && f.exists()) {
+      if (f.exists()) {
         f.delete();
       }
     }

http://git-wip-us.apache.org/repos/asf/accumulo/blob/5bd4e27c/pom.xml
----------------------------------------------------------------------
diff --git a/pom.xml b/pom.xml
index e41b75c..f620e8e 100644
--- a/pom.xml
+++ b/pom.xml
@@ -1073,6 +1073,7 @@
           <xmlOutput>true</xmlOutput>
           <effort>Max</effort>
           <threshold>Medium</threshold>
+          <failOnError>false</failOnError>
         </configuration>
       </plugin>
     </plugins>

http://git-wip-us.apache.org/repos/asf/accumulo/blob/5bd4e27c/proxy/src/main/java/org/apache/accumulo/proxy/Proxy.java
----------------------------------------------------------------------
diff --git a/proxy/src/main/java/org/apache/accumulo/proxy/Proxy.java b/proxy/src/main/java/org/apache/accumulo/proxy/Proxy.java
index 72231f0..7597fc7 100644
--- a/proxy/src/main/java/org/apache/accumulo/proxy/Proxy.java
+++ b/proxy/src/main/java/org/apache/accumulo/proxy/Proxy.java
@@ -106,7 +106,8 @@ public class Proxy {
           } catch (Exception e) {
             throw new RuntimeException();
           } finally {
-            folder.delete();
+            if (!folder.delete())
+              log.warn("Unexpected error removing " + folder);
           }
         }
       });

http://git-wip-us.apache.org/repos/asf/accumulo/blob/5bd4e27c/proxy/src/main/java/org/apache/accumulo/proxy/ProxyServer.java
----------------------------------------------------------------------
diff --git a/proxy/src/main/java/org/apache/accumulo/proxy/ProxyServer.java b/proxy/src/main/java/org/apache/accumulo/proxy/ProxyServer.java
index 89a79b7..3413c94 100644
--- a/proxy/src/main/java/org/apache/accumulo/proxy/ProxyServer.java
+++ b/proxy/src/main/java/org/apache/accumulo/proxy/ProxyServer.java
@@ -419,10 +419,11 @@ public class ProxyServer implements AccumuloProxy.Iface {
     try {
       Map<String,Set<Text>> groups = getConnector(login).tableOperations().getLocalityGroups(tableName);
       Map<String,Set<String>> ret = new HashMap<String,Set<String>>();
-      for (String key : groups.keySet()) {
-        ret.put(key, new HashSet<String>());
-        for (Text val : groups.get(key)) {
-          ret.get(key).add(val.toString());
+      for (Entry<String,Set<Text>> entry : groups.entrySet()) {
+        Set<String> value = new HashSet<String>();
+        ret.put(entry.getKey(), value);
+        for (Text val : entry.getValue()) {
+          value.add(val.toString());
         }
       }
       return ret;

http://git-wip-us.apache.org/repos/asf/accumulo/blob/5bd4e27c/server/base/src/main/java/org/apache/accumulo/server/Accumulo.java
----------------------------------------------------------------------
diff --git a/server/base/src/main/java/org/apache/accumulo/server/Accumulo.java b/server/base/src/main/java/org/apache/accumulo/server/Accumulo.java
index bcde150..83f54b0 100644
--- a/server/base/src/main/java/org/apache/accumulo/server/Accumulo.java
+++ b/server/base/src/main/java/org/apache/accumulo/server/Accumulo.java
@@ -172,7 +172,7 @@ public class Accumulo {
       DOMConfigurator.configureAndWatch(logConfig, 5000);
     
     // Read the auditing config
-    String auditConfig = String.format("%s/auditLog.xml", System.getenv("ACCUMULO_CONF_DIR"), application);
+    String auditConfig = String.format("%s/auditLog.xml", System.getenv("ACCUMULO_CONF_DIR"));
     
     DOMConfigurator.configureAndWatch(auditConfig, 5000);
     

http://git-wip-us.apache.org/repos/asf/accumulo/blob/5bd4e27c/server/base/src/main/java/org/apache/accumulo/server/conf/NamespaceConfiguration.java
----------------------------------------------------------------------
diff --git a/server/base/src/main/java/org/apache/accumulo/server/conf/NamespaceConfiguration.java b/server/base/src/main/java/org/apache/accumulo/server/conf/NamespaceConfiguration.java
index 2a1f9a1..c0ac0b8 100644
--- a/server/base/src/main/java/org/apache/accumulo/server/conf/NamespaceConfiguration.java
+++ b/server/base/src/main/java/org/apache/accumulo/server/conf/NamespaceConfiguration.java
@@ -75,13 +75,10 @@ public class NamespaceConfiguration extends AccumuloConfiguration {
     return value;
   }
 
-  private static ZooCache getPropCache() {
+  private synchronized static ZooCache getPropCache() {
     Instance inst = HdfsZooInstance.getInstance();
     if (propCache == null)
-      synchronized (NamespaceConfiguration.class) {
-        if (propCache == null)
-          propCache = new ZooCache(inst.getZooKeepers(), inst.getZooKeepersSessionTimeOut(), new NamespaceConfWatcher(inst));
-      }
+	propCache = new ZooCache(inst.getZooKeepers(), inst.getZooKeepersSessionTimeOut(), new NamespaceConfWatcher(inst));
     return propCache;
   }
 

http://git-wip-us.apache.org/repos/asf/accumulo/blob/5bd4e27c/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 ce7a882..3c348f4 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
@@ -51,13 +51,10 @@ public class TableConfiguration extends AccumuloConfiguration {
     this.observers = Collections.synchronizedSet(new HashSet<ConfigurationObserver>());
   }
 
-  private static ZooCache getTablePropCache() {
+  private synchronized static ZooCache getTablePropCache() {
     Instance inst = HdfsZooInstance.getInstance();
     if (tablePropCache == null)
-      synchronized (TableConfiguration.class) {
-        if (tablePropCache == null)
-          tablePropCache = new ZooCache(inst.getZooKeepers(), inst.getZooKeepersSessionTimeOut(), new TableConfWatcher(inst));
-      }
+	tablePropCache = new ZooCache(inst.getZooKeepers(), inst.getZooKeepersSessionTimeOut(), new TableConfWatcher(inst));
     return tablePropCache;
   }
 

http://git-wip-us.apache.org/repos/asf/accumulo/blob/5bd4e27c/server/base/src/main/java/org/apache/accumulo/server/fs/VolumeManagerImpl.java
----------------------------------------------------------------------
diff --git a/server/base/src/main/java/org/apache/accumulo/server/fs/VolumeManagerImpl.java b/server/base/src/main/java/org/apache/accumulo/server/fs/VolumeManagerImpl.java
index a89572d..3e9cc26 100644
--- a/server/base/src/main/java/org/apache/accumulo/server/fs/VolumeManagerImpl.java
+++ b/server/base/src/main/java/org/apache/accumulo/server/fs/VolumeManagerImpl.java
@@ -445,7 +445,7 @@ public class VolumeManagerImpl implements VolumeManager {
       if (uri1.getScheme().equals(uri3.getScheme())) {
         String a1 = uri1.getAuthority();
         String a2 = uri3.getAuthority();
-        if (a1 == a2 || (a1 != null && a1.equals(a2)))
+        if ((a1 == null && a2 == null) || (a1 != null && a1.equals(a2)))
           return new Path(option);
       }
     }

http://git-wip-us.apache.org/repos/asf/accumulo/blob/5bd4e27c/server/base/src/main/java/org/apache/accumulo/server/master/recovery/LogCloser.java
----------------------------------------------------------------------
diff --git a/server/base/src/main/java/org/apache/accumulo/server/master/recovery/LogCloser.java b/server/base/src/main/java/org/apache/accumulo/server/master/recovery/LogCloser.java
index deeea61..1365742 100644
--- a/server/base/src/main/java/org/apache/accumulo/server/master/recovery/LogCloser.java
+++ b/server/base/src/main/java/org/apache/accumulo/server/master/recovery/LogCloser.java
@@ -23,5 +23,5 @@ import org.apache.accumulo.server.fs.VolumeManager;
 import org.apache.hadoop.fs.Path;
 
 public interface LogCloser {
-  public long close(AccumuloConfiguration conf, VolumeManager fs, Path path) throws IOException;
+  long close(AccumuloConfiguration conf, VolumeManager fs, Path path) throws IOException;
 }

http://git-wip-us.apache.org/repos/asf/accumulo/blob/5bd4e27c/server/base/src/main/java/org/apache/accumulo/server/master/state/Assignment.java
----------------------------------------------------------------------
diff --git a/server/base/src/main/java/org/apache/accumulo/server/master/state/Assignment.java b/server/base/src/main/java/org/apache/accumulo/server/master/state/Assignment.java
index b2510fc..40b7a93 100644
--- a/server/base/src/main/java/org/apache/accumulo/server/master/state/Assignment.java
+++ b/server/base/src/main/java/org/apache/accumulo/server/master/state/Assignment.java
@@ -17,7 +17,6 @@
 package org.apache.accumulo.server.master.state;
 
 import org.apache.accumulo.core.data.KeyExtent;
-import org.apache.accumulo.server.master.state.TServerInstance;
 
 public class Assignment {
   public KeyExtent tablet;

http://git-wip-us.apache.org/repos/asf/accumulo/blob/5bd4e27c/server/base/src/main/java/org/apache/accumulo/server/master/state/DistributedStore.java
----------------------------------------------------------------------
diff --git a/server/base/src/main/java/org/apache/accumulo/server/master/state/DistributedStore.java b/server/base/src/main/java/org/apache/accumulo/server/master/state/DistributedStore.java
index ad658df..10a1311 100644
--- a/server/base/src/main/java/org/apache/accumulo/server/master/state/DistributedStore.java
+++ b/server/base/src/main/java/org/apache/accumulo/server/master/state/DistributedStore.java
@@ -23,12 +23,12 @@ import java.util.List;
  */
 public interface DistributedStore {
   
-  public List<String> getChildren(String path) throws DistributedStoreException;
+  List<String> getChildren(String path) throws DistributedStoreException;
   
-  public byte[] get(String path) throws DistributedStoreException;
+  byte[] get(String path) throws DistributedStoreException;
   
-  public void put(String path, byte[] bs) throws DistributedStoreException;
+  void put(String path, byte[] bs) throws DistributedStoreException;
   
-  public void remove(String path) throws DistributedStoreException;
+  void remove(String path) throws DistributedStoreException;
   
 }

http://git-wip-us.apache.org/repos/asf/accumulo/blob/5bd4e27c/server/base/src/main/java/org/apache/accumulo/server/master/state/MetaDataStateStore.java
----------------------------------------------------------------------
diff --git a/server/base/src/main/java/org/apache/accumulo/server/master/state/MetaDataStateStore.java b/server/base/src/main/java/org/apache/accumulo/server/master/state/MetaDataStateStore.java
index 082f2ca..57d38eb 100644
--- a/server/base/src/main/java/org/apache/accumulo/server/master/state/MetaDataStateStore.java
+++ b/server/base/src/main/java/org/apache/accumulo/server/master/state/MetaDataStateStore.java
@@ -31,9 +31,6 @@ import org.apache.accumulo.core.metadata.schema.MetadataSchema;
 import org.apache.accumulo.core.metadata.schema.MetadataSchema.TabletsSection;
 import org.apache.accumulo.core.security.Credentials;
 import org.apache.accumulo.server.client.HdfsZooInstance;
-import org.apache.accumulo.server.master.state.CurrentState;
-import org.apache.accumulo.server.master.state.MetaDataTableScanner;
-import org.apache.accumulo.server.master.state.TabletLocationState;
 import org.apache.accumulo.server.security.SystemCredentials;
 import org.apache.hadoop.io.Text;
 

http://git-wip-us.apache.org/repos/asf/accumulo/blob/5bd4e27c/server/base/src/main/java/org/apache/accumulo/server/master/state/RootTabletStateStore.java
----------------------------------------------------------------------
diff --git a/server/base/src/main/java/org/apache/accumulo/server/master/state/RootTabletStateStore.java b/server/base/src/main/java/org/apache/accumulo/server/master/state/RootTabletStateStore.java
index d8220fe..bdf5478 100644
--- a/server/base/src/main/java/org/apache/accumulo/server/master/state/RootTabletStateStore.java
+++ b/server/base/src/main/java/org/apache/accumulo/server/master/state/RootTabletStateStore.java
@@ -22,9 +22,6 @@ import org.apache.accumulo.core.client.Instance;
 import org.apache.accumulo.core.metadata.RootTable;
 import org.apache.accumulo.core.metadata.schema.MetadataSchema;
 import org.apache.accumulo.core.security.Credentials;
-import org.apache.accumulo.server.master.state.CurrentState;
-import org.apache.accumulo.server.master.state.MetaDataTableScanner;
-import org.apache.accumulo.server.master.state.TabletLocationState;
 
 public class RootTabletStateStore extends MetaDataStateStore {
   

http://git-wip-us.apache.org/repos/asf/accumulo/blob/5bd4e27c/server/base/src/main/java/org/apache/accumulo/server/master/state/TabletStateStore.java
----------------------------------------------------------------------
diff --git a/server/base/src/main/java/org/apache/accumulo/server/master/state/TabletStateStore.java b/server/base/src/main/java/org/apache/accumulo/server/master/state/TabletStateStore.java
index 5e19976..ed68b4e 100644
--- a/server/base/src/main/java/org/apache/accumulo/server/master/state/TabletStateStore.java
+++ b/server/base/src/main/java/org/apache/accumulo/server/master/state/TabletStateStore.java
@@ -20,8 +20,6 @@ import java.util.Collection;
 import java.util.Collections;
 import java.util.Iterator;
 
-import org.apache.accumulo.server.master.state.TabletLocationState;
-
 /**
  * Interface for storing information about tablet assignments. There are three implementations:
  * 

http://git-wip-us.apache.org/repos/asf/accumulo/blob/5bd4e27c/server/base/src/main/java/org/apache/accumulo/server/metrics/MetricsConfiguration.java
----------------------------------------------------------------------
diff --git a/server/base/src/main/java/org/apache/accumulo/server/metrics/MetricsConfiguration.java b/server/base/src/main/java/org/apache/accumulo/server/metrics/MetricsConfiguration.java
index 446a548..087ca12 100644
--- a/server/base/src/main/java/org/apache/accumulo/server/metrics/MetricsConfiguration.java
+++ b/server/base/src/main/java/org/apache/accumulo/server/metrics/MetricsConfiguration.java
@@ -107,15 +107,19 @@ public class MetricsConfiguration {
   }
   
   public Configuration getEnvironmentConfiguration() {
-    if (null == envConfig)
-      envConfig = new EnvironmentConfiguration();
-    return envConfig;
+    synchronized (MetricsConfiguration.class) {
+      if (null == envConfig)
+        envConfig = new EnvironmentConfiguration();
+      return envConfig;
+    }
   }
   
   public Configuration getSystemConfiguration() {
-    if (null == sysConfig)
-      sysConfig = new SystemConfiguration();
-    return sysConfig;
+    synchronized (MetricsConfiguration.class) {
+      if (null == sysConfig)
+        sysConfig = new SystemConfiguration();
+      return sysConfig;
+    }
   }
   
   public Configuration getMetricsConfiguration() {

http://git-wip-us.apache.org/repos/asf/accumulo/blob/5bd4e27c/server/base/src/main/java/org/apache/accumulo/server/metrics/ThriftMetricsMBean.java
----------------------------------------------------------------------
diff --git a/server/base/src/main/java/org/apache/accumulo/server/metrics/ThriftMetricsMBean.java b/server/base/src/main/java/org/apache/accumulo/server/metrics/ThriftMetricsMBean.java
index 11f94c2..403cffe 100644
--- a/server/base/src/main/java/org/apache/accumulo/server/metrics/ThriftMetricsMBean.java
+++ b/server/base/src/main/java/org/apache/accumulo/server/metrics/ThriftMetricsMBean.java
@@ -18,25 +18,25 @@ package org.apache.accumulo.server.metrics;
 
 public interface ThriftMetricsMBean {
   
-  public static final String idle = "idle";
-  public static final String execute = "execute";
+  static final String idle = "idle";
+  static final String execute = "execute";
   
-  public long getIdleCount();
+  long getIdleCount();
   
-  public long getIdleMinTime();
+  long getIdleMinTime();
   
-  public long getIdleMaxTime();
+  long getIdleMaxTime();
   
-  public long getIdleAvgTime();
+  long getIdleAvgTime();
   
-  public long getExecutionCount();
+  long getExecutionCount();
   
-  public long getExecutionMinTime();
+  long getExecutionMinTime();
   
-  public long getExecutionMaxTime();
+  long getExecutionMaxTime();
   
-  public long getExecutionAvgTime();
+  long getExecutionAvgTime();
   
-  public void reset();
+  void reset();
   
 }

http://git-wip-us.apache.org/repos/asf/accumulo/blob/5bd4e27c/server/base/src/main/java/org/apache/accumulo/server/problems/ProblemReports.java
----------------------------------------------------------------------
diff --git a/server/base/src/main/java/org/apache/accumulo/server/problems/ProblemReports.java b/server/base/src/main/java/org/apache/accumulo/server/problems/ProblemReports.java
index 53a1fe7..23d4de5 100644
--- a/server/base/src/main/java/org/apache/accumulo/server/problems/ProblemReports.java
+++ b/server/base/src/main/java/org/apache/accumulo/server/problems/ProblemReports.java
@@ -159,11 +159,7 @@ public class ProblemReports implements Iterable<ProblemReport> {
     Scanner scanner = connector.createScanner(MetadataTable.NAME, Authorizations.EMPTY);
     scanner.addScanIterator(new IteratorSetting(1, "keys-only", SortedKeyIterator.class));
     
-    if (table == null) {
-      scanner.setRange(new Range(new Text("~err_"), false, new Text("~err`"), false));
-    } else {
-      scanner.setRange(new Range(new Text("~err_" + table)));
-    }
+    scanner.setRange(new Range(new Text("~err_" + table)));
     
     Mutation delMut = new Mutation(new Text("~err_" + table));
     

http://git-wip-us.apache.org/repos/asf/accumulo/blob/5bd4e27c/server/base/src/main/java/org/apache/accumulo/server/security/handler/Authenticator.java
----------------------------------------------------------------------
diff --git a/server/base/src/main/java/org/apache/accumulo/server/security/handler/Authenticator.java b/server/base/src/main/java/org/apache/accumulo/server/security/handler/Authenticator.java
index 7012065..5f0da82 100644
--- a/server/base/src/main/java/org/apache/accumulo/server/security/handler/Authenticator.java
+++ b/server/base/src/main/java/org/apache/accumulo/server/security/handler/Authenticator.java
@@ -30,28 +30,28 @@ import org.apache.accumulo.core.security.thrift.TCredentials;
 
 public interface Authenticator {
   
-  public void initialize(String instanceId, boolean initialize);
+  void initialize(String instanceId, boolean initialize);
   
-  public boolean validSecurityHandlers(Authorizor auth, PermissionHandler pm);
+  boolean validSecurityHandlers(Authorizor auth, PermissionHandler pm);
   
-  public void initializeSecurity(TCredentials credentials, String principal, byte[] token) throws AccumuloSecurityException, ThriftSecurityException;
+  void initializeSecurity(TCredentials credentials, String principal, byte[] token) throws AccumuloSecurityException, ThriftSecurityException;
   
-  public boolean authenticateUser(String principal, AuthenticationToken token) throws AccumuloSecurityException;
+  boolean authenticateUser(String principal, AuthenticationToken token) throws AccumuloSecurityException;
   
-  public Set<String> listUsers() throws AccumuloSecurityException;
+  Set<String> listUsers() throws AccumuloSecurityException;
   
-  public void createUser(String principal, AuthenticationToken token) throws AccumuloSecurityException;
+  void createUser(String principal, AuthenticationToken token) throws AccumuloSecurityException;
   
-  public void dropUser(String user) throws AccumuloSecurityException;
+  void dropUser(String user) throws AccumuloSecurityException;
   
-  public void changePassword(String principal, AuthenticationToken token) throws AccumuloSecurityException;
+  void changePassword(String principal, AuthenticationToken token) throws AccumuloSecurityException;
   
-  public boolean userExists(String user) throws AccumuloSecurityException;
+  boolean userExists(String user) throws AccumuloSecurityException;
   
-  public Set<Class<? extends AuthenticationToken>> getSupportedTokenTypes();
+  Set<Class<? extends AuthenticationToken>> getSupportedTokenTypes();
   
   /**
    * Returns true if the given token is appropriate for this Authenticator
    */
-  public boolean validTokenClass(String tokenClass);
+  boolean validTokenClass(String tokenClass);
 }

http://git-wip-us.apache.org/repos/asf/accumulo/blob/5bd4e27c/server/base/src/main/java/org/apache/accumulo/server/security/handler/Authorizor.java
----------------------------------------------------------------------
diff --git a/server/base/src/main/java/org/apache/accumulo/server/security/handler/Authorizor.java b/server/base/src/main/java/org/apache/accumulo/server/security/handler/Authorizor.java
index 569d893..5131bd3 100644
--- a/server/base/src/main/java/org/apache/accumulo/server/security/handler/Authorizor.java
+++ b/server/base/src/main/java/org/apache/accumulo/server/security/handler/Authorizor.java
@@ -33,40 +33,40 @@ public interface Authorizor {
   /**
    * Sets up the authorizor for a new instance of Accumulo
    */
-  public void initialize(String instanceId, boolean initialize);
+  void initialize(String instanceId, boolean initialize);
   
   /**
    * Used to validate that the Authorizor, Authenticator, and permission handler can coexist
    */
-  public boolean validSecurityHandlers(Authenticator auth, PermissionHandler pm);
+  boolean validSecurityHandlers(Authenticator auth, PermissionHandler pm);
   
   /**
    * Used to initialize security for the root user
    */
-  public void initializeSecurity(TCredentials credentials, String rootuser) throws AccumuloSecurityException, ThriftSecurityException;
+  void initializeSecurity(TCredentials credentials, String rootuser) throws AccumuloSecurityException, ThriftSecurityException;
   
   /**
    * Used to change the authorizations for the user
    */
-  public void changeAuthorizations(String user, Authorizations authorizations) throws AccumuloSecurityException;
+  void changeAuthorizations(String user, Authorizations authorizations) throws AccumuloSecurityException;
   
   /**
    * Used to get the authorizations for the user
    */
-  public Authorizations getCachedUserAuthorizations(String user) throws AccumuloSecurityException;
+  Authorizations getCachedUserAuthorizations(String user) throws AccumuloSecurityException;
 
   /**
    * Used to check if a user has valid auths.
    */
-  public boolean isValidAuthorizations(String user, List<ByteBuffer> list) throws AccumuloSecurityException;
+  boolean isValidAuthorizations(String user, List<ByteBuffer> list) throws AccumuloSecurityException;
   
   /**
    * Initializes a new user
    */
-  public void initUser(String user) throws AccumuloSecurityException;
+  void initUser(String user) throws AccumuloSecurityException;
   
   /**
    * Deletes a user
    */
-  public void dropUser(String user) throws AccumuloSecurityException;
+  void dropUser(String user) throws AccumuloSecurityException;
 }

http://git-wip-us.apache.org/repos/asf/accumulo/blob/5bd4e27c/server/base/src/main/java/org/apache/accumulo/server/security/handler/InsecureAuthenticator.java
----------------------------------------------------------------------
diff --git a/server/base/src/main/java/org/apache/accumulo/server/security/handler/InsecureAuthenticator.java b/server/base/src/main/java/org/apache/accumulo/server/security/handler/InsecureAuthenticator.java
index 38574fa..5b374d9 100644
--- a/server/base/src/main/java/org/apache/accumulo/server/security/handler/InsecureAuthenticator.java
+++ b/server/base/src/main/java/org/apache/accumulo/server/security/handler/InsecureAuthenticator.java
@@ -33,7 +33,6 @@ public class InsecureAuthenticator implements Authenticator {
   
   @Override
   public void initialize(String instanceId, boolean initialize) {
-    return;
   }
   
   @Override
@@ -43,7 +42,6 @@ public class InsecureAuthenticator implements Authenticator {
   
   @Override
   public void initializeSecurity(TCredentials credentials, String principal, byte[] token) throws AccumuloSecurityException {
-    return;
   }
   
   @Override
@@ -58,17 +56,14 @@ public class InsecureAuthenticator implements Authenticator {
   
   @Override
   public void createUser(String principal, AuthenticationToken token) throws AccumuloSecurityException {
-    return;
   }
   
   @Override
   public void dropUser(String user) throws AccumuloSecurityException {
-    return;
   }
   
   @Override
   public void changePassword(String user, AuthenticationToken token) throws AccumuloSecurityException {
-    return;
   }
   
   @Override

http://git-wip-us.apache.org/repos/asf/accumulo/blob/5bd4e27c/server/base/src/main/java/org/apache/accumulo/server/security/handler/InsecurePermHandler.java
----------------------------------------------------------------------
diff --git a/server/base/src/main/java/org/apache/accumulo/server/security/handler/InsecurePermHandler.java b/server/base/src/main/java/org/apache/accumulo/server/security/handler/InsecurePermHandler.java
index 99c3bbe..dfe3c88 100644
--- a/server/base/src/main/java/org/apache/accumulo/server/security/handler/InsecurePermHandler.java
+++ b/server/base/src/main/java/org/apache/accumulo/server/security/handler/InsecurePermHandler.java
@@ -31,7 +31,6 @@ public class InsecurePermHandler implements PermissionHandler {
   
   @Override
   public void initialize(String instanceId, boolean initialize) {
-    return;
   }
   
   @Override
@@ -41,7 +40,6 @@ public class InsecurePermHandler implements PermissionHandler {
   
   @Override
   public void initializeSecurity(TCredentials token, String rootuser) throws AccumuloSecurityException {
-    return;
   }
   
   @Override
@@ -66,37 +64,30 @@ public class InsecurePermHandler implements PermissionHandler {
   
   @Override
   public void grantSystemPermission(String user, SystemPermission permission) throws AccumuloSecurityException {
-    return;
   }
   
   @Override
   public void revokeSystemPermission(String user, SystemPermission permission) throws AccumuloSecurityException {
-    return;
   }
   
   @Override
   public void grantTablePermission(String user, String table, TablePermission permission) throws AccumuloSecurityException, TableNotFoundException {
-    return;
   }
   
   @Override
   public void revokeTablePermission(String user, String table, TablePermission permission) throws AccumuloSecurityException, TableNotFoundException {
-    return;
   }
   
   @Override
   public void cleanTablePermissions(String table) throws AccumuloSecurityException, TableNotFoundException {
-    return;
   }
   
   @Override
   public void initUser(String user) throws AccumuloSecurityException {
-    return;
   }
   
   @Override
   public void cleanUser(String user) throws AccumuloSecurityException {
-    return;
   }
   
   @Override
@@ -117,18 +108,15 @@ public class InsecurePermHandler implements PermissionHandler {
   @Override
   public void grantNamespacePermission(String user, String namespace, NamespacePermission permission) throws AccumuloSecurityException,
       NamespaceNotFoundException {
-    return;
   }
 
   @Override
   public void revokeNamespacePermission(String user, String namespace, NamespacePermission permission) throws AccumuloSecurityException,
       NamespaceNotFoundException {
-    return;
   }
 
   @Override
   public void cleanNamespacePermissions(String namespace) throws AccumuloSecurityException, NamespaceNotFoundException {
-    return;
   }
   
 }

http://git-wip-us.apache.org/repos/asf/accumulo/blob/5bd4e27c/server/base/src/main/java/org/apache/accumulo/server/security/handler/PermissionHandler.java
----------------------------------------------------------------------
diff --git a/server/base/src/main/java/org/apache/accumulo/server/security/handler/PermissionHandler.java b/server/base/src/main/java/org/apache/accumulo/server/security/handler/PermissionHandler.java
index b93ff1e..914bab3 100644
--- a/server/base/src/main/java/org/apache/accumulo/server/security/handler/PermissionHandler.java
+++ b/server/base/src/main/java/org/apache/accumulo/server/security/handler/PermissionHandler.java
@@ -34,105 +34,105 @@ public interface PermissionHandler {
   /**
    * Sets up the permission handler for a new instance of Accumulo
    */
-  public void initialize(String instanceId, boolean initialize);
+  void initialize(String instanceId, boolean initialize);
 
   /**
    * Used to validate that the Authorizor, Authenticator, and permission handler can coexist
    */
-  public boolean validSecurityHandlers(Authenticator authent, Authorizor author);
+  boolean validSecurityHandlers(Authenticator authent, Authorizor author);
 
   /**
    * Used to initialize security for the root user
    */
-  public void initializeSecurity(TCredentials credentials, String rootuser) throws AccumuloSecurityException, ThriftSecurityException;
+  void initializeSecurity(TCredentials credentials, String rootuser) throws AccumuloSecurityException, ThriftSecurityException;
 
   /**
    * Used to get the system permission for the user
    */
-  public boolean hasSystemPermission(String user, SystemPermission permission) throws AccumuloSecurityException;
+  boolean hasSystemPermission(String user, SystemPermission permission) throws AccumuloSecurityException;
 
   /**
    * Used to get the system permission for the user, with caching due to high frequency operation. NOTE: At this time, this method is unused but is included
    * just in case we need it in the future.
    */
-  public boolean hasCachedSystemPermission(String user, SystemPermission permission) throws AccumuloSecurityException;
+  boolean hasCachedSystemPermission(String user, SystemPermission permission) throws AccumuloSecurityException;
 
   /**
    * Used to get the table permission of a user for a table
    */
-  public boolean hasTablePermission(String user, String table, TablePermission permission) throws AccumuloSecurityException, TableNotFoundException;
+  boolean hasTablePermission(String user, String table, TablePermission permission) throws AccumuloSecurityException, TableNotFoundException;
 
   /**
    * Used to get the table permission of a user for a table, with caching. This method is for high frequency operations
    */
-  public boolean hasCachedTablePermission(String user, String table, TablePermission permission) throws AccumuloSecurityException, TableNotFoundException;
+  boolean hasCachedTablePermission(String user, String table, TablePermission permission) throws AccumuloSecurityException, TableNotFoundException;
 
   /**
    * Used to get the namespace permission of a user for a namespace
    */
-  public boolean hasNamespacePermission(String user, String namespace, NamespacePermission permission) throws AccumuloSecurityException,
+  boolean hasNamespacePermission(String user, String namespace, NamespacePermission permission) throws AccumuloSecurityException,
       NamespaceNotFoundException;
 
   /**
    * Used to get the namespace permission of a user for a namespace, with caching. This method is for high frequency operations
    */
-  public boolean hasCachedNamespacePermission(String user, String namespace, NamespacePermission permission) throws AccumuloSecurityException,
+  boolean hasCachedNamespacePermission(String user, String namespace, NamespacePermission permission) throws AccumuloSecurityException,
       NamespaceNotFoundException;
 
   /**
    * Gives the user the given system permission
    */
-  public void grantSystemPermission(String user, SystemPermission permission) throws AccumuloSecurityException;
+  void grantSystemPermission(String user, SystemPermission permission) throws AccumuloSecurityException;
 
   /**
    * Denies the user the given system permission
    */
-  public void revokeSystemPermission(String user, SystemPermission permission) throws AccumuloSecurityException;
+  void revokeSystemPermission(String user, SystemPermission permission) throws AccumuloSecurityException;
 
   /**
    * Gives the user the given table permission
    */
-  public void grantTablePermission(String user, String table, TablePermission permission) throws AccumuloSecurityException, TableNotFoundException;
+  void grantTablePermission(String user, String table, TablePermission permission) throws AccumuloSecurityException, TableNotFoundException;
 
   /**
    * Denies the user the given table permission.
    */
-  public void revokeTablePermission(String user, String table, TablePermission permission) throws AccumuloSecurityException, TableNotFoundException;
+  void revokeTablePermission(String user, String table, TablePermission permission) throws AccumuloSecurityException, TableNotFoundException;
 
   /**
    * Gives the user the given namespace permission
    */
-  public void grantNamespacePermission(String user, String namespace, NamespacePermission permission) throws AccumuloSecurityException,
+  void grantNamespacePermission(String user, String namespace, NamespacePermission permission) throws AccumuloSecurityException,
       NamespaceNotFoundException;
 
   /**
    * Denies the user the given namespace permission.
    */
-  public void revokeNamespacePermission(String user, String namespace, NamespacePermission permission) throws AccumuloSecurityException,
+  void revokeNamespacePermission(String user, String namespace, NamespacePermission permission) throws AccumuloSecurityException,
       NamespaceNotFoundException;
 
   /**
    * Cleans up the permissions for a table. Used when a table gets deleted.
    */
-  public void cleanTablePermissions(String table) throws AccumuloSecurityException, TableNotFoundException;
+  void cleanTablePermissions(String table) throws AccumuloSecurityException, TableNotFoundException;
 
   /**
    * Cleans up the permissions for a namespace. Used when a namespace gets deleted.
    */
-  public void cleanNamespacePermissions(String namespace) throws AccumuloSecurityException, NamespaceNotFoundException;
+  void cleanNamespacePermissions(String namespace) throws AccumuloSecurityException, NamespaceNotFoundException;
 
   /**
    * Initializes a new user
    */
-  public void initUser(String user) throws AccumuloSecurityException;
+  void initUser(String user) throws AccumuloSecurityException;
 
   /**
    * Initializes a new user
    */
-  public void initTable(String table) throws AccumuloSecurityException;
+  void initTable(String table) throws AccumuloSecurityException;
 
   /**
    * Deletes a user
    */
-  public void cleanUser(String user) throws AccumuloSecurityException;
+  void cleanUser(String user) throws AccumuloSecurityException;
 }

http://git-wip-us.apache.org/repos/asf/accumulo/blob/5bd4e27c/server/base/src/main/java/org/apache/accumulo/server/util/DumpZookeeper.java
----------------------------------------------------------------------
diff --git a/server/base/src/main/java/org/apache/accumulo/server/util/DumpZookeeper.java b/server/base/src/main/java/org/apache/accumulo/server/util/DumpZookeeper.java
index c688869..30aa2eb 100644
--- a/server/base/src/main/java/org/apache/accumulo/server/util/DumpZookeeper.java
+++ b/server/base/src/main/java/org/apache/accumulo/server/util/DumpZookeeper.java
@@ -58,8 +58,6 @@ public class DumpZookeeper {
     
     Logger.getRootLogger().setLevel(Level.WARN);
     PrintStream out = System.out;
-    if (args.length > 0)
-      opts.root = opts.root;
     try {
       zk = ZooReaderWriter.getInstance();
       

http://git-wip-us.apache.org/repos/asf/accumulo/blob/5bd4e27c/server/base/src/main/java/org/apache/accumulo/server/util/FileUtil.java
----------------------------------------------------------------------
diff --git a/server/base/src/main/java/org/apache/accumulo/server/util/FileUtil.java b/server/base/src/main/java/org/apache/accumulo/server/util/FileUtil.java
index 7e20853..b410dc1 100644
--- a/server/base/src/main/java/org/apache/accumulo/server/util/FileUtil.java
+++ b/server/base/src/main/java/org/apache/accumulo/server/util/FileUtil.java
@@ -171,7 +171,6 @@ public class FileUtil {
           }
         
         try {
-          if (writer != null)
             writer.close();
         } catch (IOException e) {
           log.error(e, e);

http://git-wip-us.apache.org/repos/asf/accumulo/blob/5bd4e27c/server/base/src/main/java/org/apache/accumulo/server/util/time/ProvidesTime.java
----------------------------------------------------------------------
diff --git a/server/base/src/main/java/org/apache/accumulo/server/util/time/ProvidesTime.java b/server/base/src/main/java/org/apache/accumulo/server/util/time/ProvidesTime.java
index 92f0d2c..117fa5f 100644
--- a/server/base/src/main/java/org/apache/accumulo/server/util/time/ProvidesTime.java
+++ b/server/base/src/main/java/org/apache/accumulo/server/util/time/ProvidesTime.java
@@ -21,5 +21,5 @@ package org.apache.accumulo.server.util.time;
  * 
  */
 public interface ProvidesTime {
-  public long currentTime();
+  long currentTime();
 }

http://git-wip-us.apache.org/repos/asf/accumulo/blob/5bd4e27c/server/gc/src/main/java/org/apache/accumulo/gc/GarbageCollectWriteAheadLogs.java
----------------------------------------------------------------------
diff --git a/server/gc/src/main/java/org/apache/accumulo/gc/GarbageCollectWriteAheadLogs.java b/server/gc/src/main/java/org/apache/accumulo/gc/GarbageCollectWriteAheadLogs.java
index 111d1e7..ab2ab42 100644
--- a/server/gc/src/main/java/org/apache/accumulo/gc/GarbageCollectWriteAheadLogs.java
+++ b/server/gc/src/main/java/org/apache/accumulo/gc/GarbageCollectWriteAheadLogs.java
@@ -67,6 +67,7 @@ public class GarbageCollectWriteAheadLogs {
   GarbageCollectWriteAheadLogs(Instance instance, VolumeManager fs, boolean useTrash) throws IOException {
     this.instance = instance;
     this.fs = fs;
+    this.useTrash = useTrash;
   }
   
   public void collect(GCStatus status) {

http://git-wip-us.apache.org/repos/asf/accumulo/blob/5bd4e27c/server/master/src/main/java/org/apache/accumulo/master/recovery/RecoveryManager.java
----------------------------------------------------------------------
diff --git a/server/master/src/main/java/org/apache/accumulo/master/recovery/RecoveryManager.java b/server/master/src/main/java/org/apache/accumulo/master/recovery/RecoveryManager.java
index 789d482..390b33f 100644
--- a/server/master/src/main/java/org/apache/accumulo/master/recovery/RecoveryManager.java
+++ b/server/master/src/main/java/org/apache/accumulo/master/recovery/RecoveryManager.java
@@ -123,7 +123,7 @@ public class RecoveryManager {
 
   public boolean recoverLogs(KeyExtent extent, Collection<Collection<String>> walogs) throws IOException {
     boolean recoveryNeeded = false;
-    ;
+
     for (Collection<String> logs : walogs) {
       for (String walog : logs) {
 

http://git-wip-us.apache.org/repos/asf/accumulo/blob/5bd4e27c/server/master/src/main/java/org/apache/accumulo/master/tableOps/BulkImport.java
----------------------------------------------------------------------
diff --git a/server/master/src/main/java/org/apache/accumulo/master/tableOps/BulkImport.java b/server/master/src/main/java/org/apache/accumulo/master/tableOps/BulkImport.java
index 2426898..5b85a14 100644
--- a/server/master/src/main/java/org/apache/accumulo/master/tableOps/BulkImport.java
+++ b/server/master/src/main/java/org/apache/accumulo/master/tableOps/BulkImport.java
@@ -462,9 +462,6 @@ class LoadFiles extends MasterRepo {
   private static final long serialVersionUID = 1L;
   
   private static ExecutorService threadPool = null;
-  static {
-    
-  }
   private static final Logger log = Logger.getLogger(BulkImport.class);
   
   private String tableId;

http://git-wip-us.apache.org/repos/asf/accumulo/blob/5bd4e27c/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 a0f0af4..a972d46 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
@@ -108,7 +108,7 @@ public class TableRangeOp extends MasterRepo {
   @Override
   public Repo<Master> call(long tid, Master env) throws Exception {
 
-    if (RootTable.ID.equals(tableId) && TableOperation.MERGE.equals(op)) {
+    if (RootTable.ID.equals(tableId) && Operation.MERGE.equals(op)) {
       log.warn("Attempt to merge tablets for " + RootTable.NAME + " does nothing. It is not splittable.");
     }
 

http://git-wip-us.apache.org/repos/asf/accumulo/blob/5bd4e27c/server/monitor/src/main/java/org/apache/accumulo/monitor/EmbeddedWebServer.java
----------------------------------------------------------------------
diff --git a/server/monitor/src/main/java/org/apache/accumulo/monitor/EmbeddedWebServer.java b/server/monitor/src/main/java/org/apache/accumulo/monitor/EmbeddedWebServer.java
index e16b598..5439b8a 100644
--- a/server/monitor/src/main/java/org/apache/accumulo/monitor/EmbeddedWebServer.java
+++ b/server/monitor/src/main/java/org/apache/accumulo/monitor/EmbeddedWebServer.java
@@ -43,10 +43,10 @@ public class EmbeddedWebServer {
     handler = new ContextHandlerCollection();
     root = new Context(handler, "/", new SessionHandler(), null, null, null);
     
-    if (Monitor.getSystemConfiguration().get(Property.MONITOR_SSL_KEYSTORE) == ""
-        || Monitor.getSystemConfiguration().get(Property.MONITOR_SSL_KEYSTOREPASS) == ""
-        || Monitor.getSystemConfiguration().get(Property.MONITOR_SSL_TRUSTSTORE) == ""
-        || Monitor.getSystemConfiguration().get(Property.MONITOR_SSL_TRUSTSTOREPASS) == "") {
+    if (Monitor.getSystemConfiguration().get(Property.MONITOR_SSL_KEYSTORE).equals("")
+        || Monitor.getSystemConfiguration().get(Property.MONITOR_SSL_KEYSTOREPASS).equals("")
+        || Monitor.getSystemConfiguration().get(Property.MONITOR_SSL_TRUSTSTORE).equals("")
+        || Monitor.getSystemConfiguration().get(Property.MONITOR_SSL_TRUSTSTOREPASS).equals("")) {
       sock = new SocketConnector();
       usingSsl = false;
     } else {

http://git-wip-us.apache.org/repos/asf/accumulo/blob/5bd4e27c/server/monitor/src/main/java/org/apache/accumulo/monitor/servlets/OperationServlet.java
----------------------------------------------------------------------
diff --git a/server/monitor/src/main/java/org/apache/accumulo/monitor/servlets/OperationServlet.java b/server/monitor/src/main/java/org/apache/accumulo/monitor/servlets/OperationServlet.java
index 961edc3..e403687 100644
--- a/server/monitor/src/main/java/org/apache/accumulo/monitor/servlets/OperationServlet.java
+++ b/server/monitor/src/main/java/org/apache/accumulo/monitor/servlets/OperationServlet.java
@@ -80,8 +80,8 @@ public class OperationServlet extends BasicServlet {
     }
   }
   
-  private static interface WebOperation {
-    public void execute(HttpServletRequest req, HttpServletResponse resp, Logger log) throws Exception;
+  private interface WebOperation {
+    void execute(HttpServletRequest req, HttpServletResponse resp, Logger log) throws Exception;
   }
   
   public static class RefreshOperation implements WebOperation {

http://git-wip-us.apache.org/repos/asf/accumulo/blob/5bd4e27c/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 5d2d2db..fb56573 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
@@ -158,7 +158,7 @@ public class VisServlet extends BasicServlet {
       return;
     
     int width = (int) Math.ceil(Math.sqrt(tservers.size())) * cfg.spacing;
-    int height = (int) Math.ceil(tservers.size() / 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);
   }

http://git-wip-us.apache.org/repos/asf/accumulo/blob/5bd4e27c/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 e29c5d7..1ba0590 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
@@ -63,7 +63,7 @@ public class ListType extends Basic {
     for (Entry<Key,Value> entry : scanner) {
       RemoteSpan span = TraceFormatter.getRemoteSpan(entry);
       if (span.description.equals(type)) {
-        trace.addRow(span, new Long(span.stop - span.start), span.svc + ":" + span.sender);
+        trace.addRow(span, Long.valueOf(span.stop - span.start), span.svc + ":" + span.sender);
       }
     }
     trace.generate(req, sb);

http://git-wip-us.apache.org/repos/asf/accumulo/blob/5bd4e27c/server/tserver/src/main/java/org/apache/accumulo/tserver/Compactor.java
----------------------------------------------------------------------
diff --git a/server/tserver/src/main/java/org/apache/accumulo/tserver/Compactor.java b/server/tserver/src/main/java/org/apache/accumulo/tserver/Compactor.java
index fdd8a29..0843c13 100644
--- a/server/tserver/src/main/java/org/apache/accumulo/tserver/Compactor.java
+++ b/server/tserver/src/main/java/org/apache/accumulo/tserver/Compactor.java
@@ -128,7 +128,7 @@ public class Compactor implements Callable<CompactionStats> {
     private static final long serialVersionUID = 1L;
   }
 
-  static interface CompactionEnv {
+  interface CompactionEnv {
     boolean isCompactionEnabled();
 
     IteratorScope getIteratorScope();

http://git-wip-us.apache.org/repos/asf/accumulo/blob/5bd4e27c/server/tserver/src/main/java/org/apache/accumulo/tserver/ConditionalMutationSet.java
----------------------------------------------------------------------
diff --git a/server/tserver/src/main/java/org/apache/accumulo/tserver/ConditionalMutationSet.java b/server/tserver/src/main/java/org/apache/accumulo/tserver/ConditionalMutationSet.java
index 0cdb14c..32eaacf 100644
--- a/server/tserver/src/main/java/org/apache/accumulo/tserver/ConditionalMutationSet.java
+++ b/server/tserver/src/main/java/org/apache/accumulo/tserver/ConditionalMutationSet.java
@@ -33,7 +33,7 @@ import org.apache.hadoop.io.WritableComparator;
  */
 public class ConditionalMutationSet {
 
-  static interface DeferFilter {
+  interface DeferFilter {
     void defer(List<ServerConditionalMutation> scml, List<ServerConditionalMutation> okMutations, List<ServerConditionalMutation> deferred);
   }
   

http://git-wip-us.apache.org/repos/asf/accumulo/blob/5bd4e27c/server/tserver/src/main/java/org/apache/accumulo/tserver/InMemoryMap.java
----------------------------------------------------------------------
diff --git a/server/tserver/src/main/java/org/apache/accumulo/tserver/InMemoryMap.java b/server/tserver/src/main/java/org/apache/accumulo/tserver/InMemoryMap.java
index 9678638..5ee62c6 100644
--- a/server/tserver/src/main/java/org/apache/accumulo/tserver/InMemoryMap.java
+++ b/server/tserver/src/main/java/org/apache/accumulo/tserver/InMemoryMap.java
@@ -232,19 +232,19 @@ public class InMemoryMap {
   }
   
   private interface SimpleMap {
-    public Value get(Key key);
+    Value get(Key key);
     
-    public Iterator<Entry<Key,Value>> iterator(Key startKey);
+    Iterator<Entry<Key,Value>> iterator(Key startKey);
     
-    public int size();
+    int size();
     
-    public InterruptibleIterator skvIterator();
+    InterruptibleIterator skvIterator();
     
-    public void delete();
+    void delete();
     
-    public long getMemoryUsed();
+    long getMemoryUsed();
     
-    public void mutate(List<Mutation> mutations, int kvCount);
+    void mutate(List<Mutation> mutations, int kvCount);
   }
   
   private static class LocalityGroupMap implements SimpleMap {

http://git-wip-us.apache.org/repos/asf/accumulo/blob/5bd4e27c/server/tserver/src/main/java/org/apache/accumulo/tserver/TabletServer.java
----------------------------------------------------------------------
diff --git a/server/tserver/src/main/java/org/apache/accumulo/tserver/TabletServer.java b/server/tserver/src/main/java/org/apache/accumulo/tserver/TabletServer.java
index d2b01ac..5c1f6ce 100644
--- a/server/tserver/src/main/java/org/apache/accumulo/tserver/TabletServer.java
+++ b/server/tserver/src/main/java/org/apache/accumulo/tserver/TabletServer.java
@@ -2915,7 +2915,7 @@ public class TabletServer extends AbstractMetricsImpl implements org.apache.accu
             openingTablets.remove(extent);
             onlineTablets.put(extent, tablet);
             openingTablets.notifyAll();
-            recentlyUnloadedCache.remove(tablet);
+            recentlyUnloadedCache.remove(tablet.getExtent());
           }
         }
         tablet = null; // release this reference

http://git-wip-us.apache.org/repos/asf/accumulo/blob/5bd4e27c/server/tserver/src/main/java/org/apache/accumulo/tserver/metrics/TabletServerMBean.java
----------------------------------------------------------------------
diff --git a/server/tserver/src/main/java/org/apache/accumulo/tserver/metrics/TabletServerMBean.java b/server/tserver/src/main/java/org/apache/accumulo/tserver/metrics/TabletServerMBean.java
index 228e743..3b7a637 100644
--- a/server/tserver/src/main/java/org/apache/accumulo/tserver/metrics/TabletServerMBean.java
+++ b/server/tserver/src/main/java/org/apache/accumulo/tserver/metrics/TabletServerMBean.java
@@ -18,33 +18,33 @@ package org.apache.accumulo.tserver.metrics;
 
 public interface TabletServerMBean {
   
-  public int getOnlineCount();
+  int getOnlineCount();
   
-  public int getOpeningCount();
+  int getOpeningCount();
   
-  public int getUnopenedCount();
+  int getUnopenedCount();
   
-  public int getMajorCompactions();
+  int getMajorCompactions();
   
-  public int getMajorCompactionsQueued();
+  int getMajorCompactionsQueued();
   
-  public int getMinorCompactions();
+  int getMinorCompactions();
   
-  public int getMinorCompactionsQueued();
+  int getMinorCompactionsQueued();
   
-  public long getEntries();
+  long getEntries();
   
-  public long getEntriesInMemory();
+  long getEntriesInMemory();
   
-  public long getQueries();
+  long getQueries();
   
-  public long getIngest();
+  long getIngest();
   
-  public long getTotalMinorCompactions();
+  long getTotalMinorCompactions();
   
-  public double getHoldTime();
+  double getHoldTime();
   
-  public String getName();
+  String getName();
   
-  public double getAverageFilesPerTablet();
+  double getAverageFilesPerTablet();
 }

http://git-wip-us.apache.org/repos/asf/accumulo/blob/5bd4e27c/server/tserver/src/main/java/org/apache/accumulo/tserver/metrics/TabletServerMinCMetricsMBean.java
----------------------------------------------------------------------
diff --git a/server/tserver/src/main/java/org/apache/accumulo/tserver/metrics/TabletServerMinCMetricsMBean.java b/server/tserver/src/main/java/org/apache/accumulo/tserver/metrics/TabletServerMinCMetricsMBean.java
index 4541701..0dc6cf3 100644
--- a/server/tserver/src/main/java/org/apache/accumulo/tserver/metrics/TabletServerMinCMetricsMBean.java
+++ b/server/tserver/src/main/java/org/apache/accumulo/tserver/metrics/TabletServerMinCMetricsMBean.java
@@ -18,25 +18,25 @@ package org.apache.accumulo.tserver.metrics;
 
 public interface TabletServerMinCMetricsMBean {
   
-  public static final String minc = "minc";
-  public static final String queue = "queue";
+  static final String minc = "minc";
+  static final String queue = "queue";
   
-  public long getMinorCompactionCount();
+  long getMinorCompactionCount();
   
-  public long getMinorCompactionAvgTime();
+  long getMinorCompactionAvgTime();
   
-  public long getMinorCompactionMinTime();
+  long getMinorCompactionMinTime();
   
-  public long getMinorCompactionMaxTime();
+  long getMinorCompactionMaxTime();
   
-  public long getMinorCompactionQueueCount();
+  long getMinorCompactionQueueCount();
   
-  public long getMinorCompactionQueueAvgTime();
+  long getMinorCompactionQueueAvgTime();
   
-  public long getMinorCompactionQueueMinTime();
+  long getMinorCompactionQueueMinTime();
   
-  public long getMinorCompactionQueueMaxTime();
+  long getMinorCompactionQueueMaxTime();
   
-  public void reset();
+  void reset();
   
 }

http://git-wip-us.apache.org/repos/asf/accumulo/blob/5bd4e27c/server/tserver/src/main/java/org/apache/accumulo/tserver/metrics/TabletServerScanMetricsMBean.java
----------------------------------------------------------------------
diff --git a/server/tserver/src/main/java/org/apache/accumulo/tserver/metrics/TabletServerScanMetricsMBean.java b/server/tserver/src/main/java/org/apache/accumulo/tserver/metrics/TabletServerScanMetricsMBean.java
index 4bcf188..b532cfa 100644
--- a/server/tserver/src/main/java/org/apache/accumulo/tserver/metrics/TabletServerScanMetricsMBean.java
+++ b/server/tserver/src/main/java/org/apache/accumulo/tserver/metrics/TabletServerScanMetricsMBean.java
@@ -18,25 +18,25 @@ package org.apache.accumulo.tserver.metrics;
 
 public interface TabletServerScanMetricsMBean {
   
-  public static final String scan = "scan";
-  public static final String resultSize = "result";
+  static final String scan = "scan";
+  static final String resultSize = "result";
   
-  public long getScanCount();
+  long getScanCount();
   
-  public long getScanAvgTime();
+  long getScanAvgTime();
   
-  public long getScanMinTime();
+  long getScanMinTime();
   
-  public long getScanMaxTime();
+  long getScanMaxTime();
   
-  public long getResultCount();
+  long getResultCount();
   
-  public long getResultAvgSize();
+  long getResultAvgSize();
   
-  public long getResultMinSize();
+  long getResultMinSize();
   
-  public long getResultMaxSize();
+  long getResultMaxSize();
   
-  public void reset();
+  void reset();
   
 }

http://git-wip-us.apache.org/repos/asf/accumulo/blob/5bd4e27c/server/tserver/src/main/java/org/apache/accumulo/tserver/metrics/TabletServerUpdateMetricsMBean.java
----------------------------------------------------------------------
diff --git a/server/tserver/src/main/java/org/apache/accumulo/tserver/metrics/TabletServerUpdateMetricsMBean.java b/server/tserver/src/main/java/org/apache/accumulo/tserver/metrics/TabletServerUpdateMetricsMBean.java
index 7e3b506..0292947 100644
--- a/server/tserver/src/main/java/org/apache/accumulo/tserver/metrics/TabletServerUpdateMetricsMBean.java
+++ b/server/tserver/src/main/java/org/apache/accumulo/tserver/metrics/TabletServerUpdateMetricsMBean.java
@@ -18,49 +18,49 @@ package org.apache.accumulo.tserver.metrics;
 
 public interface TabletServerUpdateMetricsMBean {
   
-  public final static String permissionErrors = "permissionErrors";
-  public final static String unknownTabletErrors = "unknownTabletErrors";
-  public final static String mutationArraySize = "mutationArraysSize";
-  public final static String commitPrep = "commitPrep";
-  public final static String constraintViolations = "constraintViolations";
-  public final static String waLogWriteTime = "waLogWriteTime";
-  public final static String commitTime = "commitTime";
+  final static String permissionErrors = "permissionErrors";
+  final static String unknownTabletErrors = "unknownTabletErrors";
+  final static String mutationArraySize = "mutationArraysSize";
+  final static String commitPrep = "commitPrep";
+  final static String constraintViolations = "constraintViolations";
+  final static String waLogWriteTime = "waLogWriteTime";
+  final static String commitTime = "commitTime";
   
-  public long getPermissionErrorCount();
+  long getPermissionErrorCount();
   
-  public long getUnknownTabletErrorCount();
+  long getUnknownTabletErrorCount();
   
-  public long getMutationArrayAvgSize();
+  long getMutationArrayAvgSize();
   
-  public long getMutationArrayMinSize();
+  long getMutationArrayMinSize();
   
-  public long getMutationArrayMaxSize();
+  long getMutationArrayMaxSize();
   
-  public long getCommitPrepCount();
+  long getCommitPrepCount();
   
-  public long getCommitPrepMinTime();
+  long getCommitPrepMinTime();
   
-  public long getCommitPrepMaxTime();
+  long getCommitPrepMaxTime();
   
-  public long getCommitPrepAvgTime();
+  long getCommitPrepAvgTime();
   
-  public long getConstraintViolationCount();
+  long getConstraintViolationCount();
   
-  public long getWALogWriteCount();
+  long getWALogWriteCount();
   
-  public long getWALogWriteMinTime();
+  long getWALogWriteMinTime();
   
-  public long getWALogWriteMaxTime();
+  long getWALogWriteMaxTime();
   
-  public long getWALogWriteAvgTime();
+  long getWALogWriteAvgTime();
   
-  public long getCommitCount();
+  long getCommitCount();
   
-  public long getCommitMinTime();
+  long getCommitMinTime();
   
-  public long getCommitMaxTime();
+  long getCommitMaxTime();
   
-  public long getCommitAvgTime();
+  long getCommitAvgTime();
   
-  public void reset();
+  void reset();
 }

http://git-wip-us.apache.org/repos/asf/accumulo/blob/5bd4e27c/start/src/main/java/org/apache/accumulo/start/classloader/vfs/AccumuloReloadingVFSClassLoader.java
----------------------------------------------------------------------
diff --git a/start/src/main/java/org/apache/accumulo/start/classloader/vfs/AccumuloReloadingVFSClassLoader.java b/start/src/main/java/org/apache/accumulo/start/classloader/vfs/AccumuloReloadingVFSClassLoader.java
index 2a70c9c..c485fe4 100644
--- a/start/src/main/java/org/apache/accumulo/start/classloader/vfs/AccumuloReloadingVFSClassLoader.java
+++ b/start/src/main/java/org/apache/accumulo/start/classloader/vfs/AccumuloReloadingVFSClassLoader.java
@@ -17,6 +17,7 @@
 package org.apache.accumulo.start.classloader.vfs;
 
 import java.util.ArrayList;
+import java.util.Arrays;
 
 import org.apache.commons.vfs2.FileChangeEvent;
 import org.apache.commons.vfs2.FileListener;
@@ -118,8 +119,8 @@ public class AccumuloReloadingVFSClassLoader implements FileListener, ReloadingC
     this(uris, vfs, parent, DEFAULT_TIMEOUT, preDelegate);
   }
 
-  public FileObject[] getFiles() {
-    return this.files;
+  synchronized public FileObject[] getFiles() {
+    return Arrays.copyOf(this.files, this.files.length);
   }
   
   /**

http://git-wip-us.apache.org/repos/asf/accumulo/blob/5bd4e27c/start/src/main/java/org/apache/accumulo/start/classloader/vfs/FinalCloseDefaultFileSystemManager.java
----------------------------------------------------------------------
diff --git a/start/src/main/java/org/apache/accumulo/start/classloader/vfs/FinalCloseDefaultFileSystemManager.java b/start/src/main/java/org/apache/accumulo/start/classloader/vfs/FinalCloseDefaultFileSystemManager.java
index e4737ec..a6cc19a 100644
--- a/start/src/main/java/org/apache/accumulo/start/classloader/vfs/FinalCloseDefaultFileSystemManager.java
+++ b/start/src/main/java/org/apache/accumulo/start/classloader/vfs/FinalCloseDefaultFileSystemManager.java
@@ -19,7 +19,7 @@ package org.apache.accumulo.start.classloader.vfs;
 import org.apache.commons.vfs2.impl.DefaultFileSystemManager;
 
 public class FinalCloseDefaultFileSystemManager extends DefaultFileSystemManager {
-  public void finalize() {
+  protected void finalize() {
     close();
   }
 }

http://git-wip-us.apache.org/repos/asf/accumulo/blob/5bd4e27c/start/src/main/java/org/apache/accumulo/start/classloader/vfs/MiniDFSUtil.java
----------------------------------------------------------------------
diff --git a/start/src/main/java/org/apache/accumulo/start/classloader/vfs/MiniDFSUtil.java b/start/src/main/java/org/apache/accumulo/start/classloader/vfs/MiniDFSUtil.java
index 6227549..c822f64 100644
--- a/start/src/main/java/org/apache/accumulo/start/classloader/vfs/MiniDFSUtil.java
+++ b/start/src/main/java/org/apache/accumulo/start/classloader/vfs/MiniDFSUtil.java
@@ -29,15 +29,19 @@ public class MiniDFSUtil {
     try {
       Process p = Runtime.getRuntime().exec("/bin/sh -c umask");
       BufferedReader bri = new BufferedReader(new InputStreamReader(p.getInputStream()));
-      String line = bri.readLine();
-      p.waitFor();
-      
-      Short umask = Short.parseShort(line.trim(), 8);
-      // Need to set permission to 777 xor umask
-      // leading zero makes java interpret as base 8
-      int newPermission = 0777 ^ umask;
-      
-      return String.format("%03o", newPermission);
+      try {
+        String line = bri.readLine();
+        p.waitFor();
+        
+        Short umask = Short.parseShort(line.trim(), 8);
+        // Need to set permission to 777 xor umask
+        // leading zero makes java interpret as base 8
+        int newPermission = 0777 ^ umask;
+        
+        return String.format("%03o", newPermission);
+      } finally {
+        bri.close();
+      }
     } catch (Exception e) {
       throw new RuntimeException("Error getting umask from O/S", e);
     }

http://git-wip-us.apache.org/repos/asf/accumulo/blob/5bd4e27c/start/src/main/java/org/apache/accumulo/start/classloader/vfs/PostDelegatingVFSClassLoader.java
----------------------------------------------------------------------
diff --git a/start/src/main/java/org/apache/accumulo/start/classloader/vfs/PostDelegatingVFSClassLoader.java b/start/src/main/java/org/apache/accumulo/start/classloader/vfs/PostDelegatingVFSClassLoader.java
index 723484c..b7d5fa9 100644
--- a/start/src/main/java/org/apache/accumulo/start/classloader/vfs/PostDelegatingVFSClassLoader.java
+++ b/start/src/main/java/org/apache/accumulo/start/classloader/vfs/PostDelegatingVFSClassLoader.java
@@ -38,13 +38,13 @@ public class PostDelegatingVFSClassLoader extends VFSClassLoader {
   
   protected synchronized Class<?> loadClass(String name, boolean resolve) throws ClassNotFoundException {
     Class<?> c = findLoadedClass(name);
-    if (c == null) {
-      try {
-        // try finding this class here instead of parent
-        c = findClass(name);
-      } catch (ClassNotFoundException e) {
-
-      }
+    if (c != null)
+      return c;
+    try {
+      // try finding this class here instead of parent
+      return findClass(name);
+    } catch (ClassNotFoundException e) {
+      
     }
     return super.loadClass(name, resolve);
   }

http://git-wip-us.apache.org/repos/asf/accumulo/blob/5bd4e27c/start/src/main/java/org/apache/accumulo/start/classloader/vfs/UniqueFileReplicator.java
----------------------------------------------------------------------
diff --git a/start/src/main/java/org/apache/accumulo/start/classloader/vfs/UniqueFileReplicator.java b/start/src/main/java/org/apache/accumulo/start/classloader/vfs/UniqueFileReplicator.java
index cc19b6e..328bb54 100644
--- a/start/src/main/java/org/apache/accumulo/start/classloader/vfs/UniqueFileReplicator.java
+++ b/start/src/main/java/org/apache/accumulo/start/classloader/vfs/UniqueFileReplicator.java
@@ -30,6 +30,7 @@ import org.apache.commons.vfs2.provider.FileReplicator;
 import org.apache.commons.vfs2.provider.UriParser;
 import org.apache.commons.vfs2.provider.VfsComponent;
 import org.apache.commons.vfs2.provider.VfsComponentContext;
+import org.apache.log4j.Logger;
 
 /**
  * 
@@ -37,6 +38,8 @@ import org.apache.commons.vfs2.provider.VfsComponentContext;
 public class UniqueFileReplicator implements VfsComponent, FileReplicator {
   
   private static final char[] TMP_RESERVED_CHARS = new char[] {'?', '/', '\\', ' ', '&', '"', '\'', '*', '#', ';', ':', '<', '>', '|'};
+
+  private static final Logger log = Logger.getLogger(UniqueFileReplicator.class);
   
   private File tempDir;
   private VfsComponentContext context;
@@ -51,7 +54,8 @@ public class UniqueFileReplicator implements VfsComponent, FileReplicator {
     String baseName = srcFile.getName().getBaseName();
     
     try {
-      tempDir.mkdirs();
+      if (!tempDir.mkdirs())
+        log.warn("Unexpected error creating directory " + tempDir);
       String safeBasename = UriParser.encode(baseName, TMP_RESERVED_CHARS).replace('%', '_');
       File file = File.createTempFile("vfsr_", "_" + safeBasename, tempDir);
       file.deleteOnExit();
@@ -85,10 +89,11 @@ public class UniqueFileReplicator implements VfsComponent, FileReplicator {
   public void close() {
     synchronized (tmpFiles) {
       for (File tmpFile : tmpFiles) {
-        tmpFile.delete();
+        if (!tmpFile.delete())
+          log.warn("File does not exist: " + tmpFile);
       }
     }
-    
-    tempDir.delete();
+    if (!tempDir.delete())
+      log.warn("Directory does not exists: " + tempDir);
   }
 }

http://git-wip-us.apache.org/repos/asf/accumulo/blob/5bd4e27c/start/src/main/java/org/apache/accumulo/start/classloader/vfs/providers/HdfsFileSystem.java
----------------------------------------------------------------------
diff --git a/start/src/main/java/org/apache/accumulo/start/classloader/vfs/providers/HdfsFileSystem.java b/start/src/main/java/org/apache/accumulo/start/classloader/vfs/providers/HdfsFileSystem.java
index 92b2720..c9fd2f5 100644
--- a/start/src/main/java/org/apache/accumulo/start/classloader/vfs/providers/HdfsFileSystem.java
+++ b/start/src/main/java/org/apache/accumulo/start/classloader/vfs/providers/HdfsFileSystem.java
@@ -42,112 +42,112 @@ import org.apache.hadoop.fs.Path;
  */
 public class HdfsFileSystem extends AbstractFileSystem
 {
-    private static final Log log = LogFactory.getLog(HdfsFileSystem.class);
-
-    private FileSystem fs;
-
-    /**
-     * 
-     * @param rootName
-     * @param fileSystemOptions
-     */
-    protected HdfsFileSystem(final FileName rootName, final FileSystemOptions fileSystemOptions)
+  private static final Log log = LogFactory.getLog(HdfsFileSystem.class);
+  
+  private FileSystem fs;
+  
+  /**
+   * 
+   * @param rootName
+   * @param fileSystemOptions
+   */
+  protected HdfsFileSystem(final FileName rootName, final FileSystemOptions fileSystemOptions)
+  {
+    super(rootName, null, fileSystemOptions);
+  }
+  
+  /**
+   * @see org.apache.commons.vfs2.provider.AbstractFileSystem#addCapabilities(java.util.Collection)
+   */
+  @Override
+  protected void addCapabilities(final Collection<Capability> capabilities)
+  {
+    capabilities.addAll(HdfsFileProvider.CAPABILITIES);
+  }
+  
+  /**
+   * @see org.apache.commons.vfs2.provider.AbstractFileSystem#close()
+   */
+  @Override
+  synchronized public void close()
+  {
+    try
     {
-        super(rootName, null, fileSystemOptions);
+      if (null != fs)
+      {
+        fs.close();
+      }
     }
-
-    /**
-     * @see org.apache.commons.vfs2.provider.AbstractFileSystem#addCapabilities(java.util.Collection)
-     */
-    @Override
-    protected void addCapabilities(final Collection<Capability> capabilities)
+    catch (final IOException e)
     {
-        capabilities.addAll(HdfsFileProvider.CAPABILITIES);
+      throw new RuntimeException("Error closing HDFS client", e);
     }
-
-    /**
-     * @see org.apache.commons.vfs2.provider.AbstractFileSystem#close()
-     */
-    @Override
-    public void close()
+    super.close();
+  }
+  
+  /**
+   * @see org.apache.commons.vfs2.provider.AbstractFileSystem#createFile(org.apache.commons.vfs2.provider.AbstractFileName)
+   */
+  @Override
+  protected FileObject createFile(final AbstractFileName name) throws Exception
+  {
+    throw new FileSystemException("Operation not supported");
+  }
+  
+  /**
+   * @see org.apache.commons.vfs2.provider.AbstractFileSystem#resolveFile(org.apache.commons.vfs2.FileName)
+   */
+  @Override
+  public FileObject resolveFile(final FileName name) throws FileSystemException
+  {
+    
+    synchronized (this)
     {
+      if (null == this.fs)
+      {
+        final String hdfsUri = name.getRootURI();
+        final Configuration conf = new Configuration(true);
+        conf.set(org.apache.hadoop.fs.FileSystem.FS_DEFAULT_NAME_KEY, hdfsUri);
+        this.fs = null;
         try
         {
-            if (null != fs)
-            {
-                fs.close();
-            }
+          fs = org.apache.hadoop.fs.FileSystem.get(conf);
         }
         catch (final IOException e)
         {
-            throw new RuntimeException("Error closing HDFS client", e);
+          log.error("Error connecting to filesystem " + hdfsUri, e);
+          throw new FileSystemException("Error connecting to filesystem " + hdfsUri, e);
         }
-        super.close();
+      }
     }
-
-    /**
-     * @see org.apache.commons.vfs2.provider.AbstractFileSystem#createFile(org.apache.commons.vfs2.provider.AbstractFileName)
-     */
-    @Override
-    protected FileObject createFile(final AbstractFileName name) throws Exception
+    
+    boolean useCache = (null != getContext().getFileSystemManager().getFilesCache());
+    FileObject file;
+    if (useCache)
     {
-        throw new FileSystemException("Operation not supported");
+      file = this.getFileFromCache(name);
     }
-
-    /**
-     * @see org.apache.commons.vfs2.provider.AbstractFileSystem#resolveFile(org.apache.commons.vfs2.FileName)
-     */
-    @Override
-    public FileObject resolveFile(final FileName name) throws FileSystemException
+    else
     {
-
-        synchronized (this)
-        {
-            if (null == this.fs)
-            {
-                final String hdfsUri = name.getRootURI();
-                final Configuration conf = new Configuration(true);
-                conf.set(org.apache.hadoop.fs.FileSystem.FS_DEFAULT_NAME_KEY, hdfsUri);
-                this.fs = null;
-                try
-                {
-                    fs = org.apache.hadoop.fs.FileSystem.get(conf);
-                }
-                catch (final IOException e)
-                {
-                    log.error("Error connecting to filesystem " + hdfsUri, e);
-                    throw new FileSystemException("Error connecting to filesystem " + hdfsUri, e);
-                }
-            }
-        }
-
-        boolean useCache = (null != getContext().getFileSystemManager().getFilesCache());
-        FileObject file;
-        if (useCache)
-        {
-            file = this.getFileFromCache(name);
-        }
-        else
-        {
-            file = null;
-        }
-        if (null == file)
-        {
-            String path = null;
-            try
-            {
-                path = URLDecoder.decode(name.getPath(), "UTF-8");
-            }
-            catch (final UnsupportedEncodingException e)
-            {
-                path = name.getPath();
-            }
-            final Path filePath = new Path(path);
-            file = new HdfsFileObject((AbstractFileName) name, this, fs, filePath);
-            if (useCache)
-            {
+      file = null;
+    }
+    if (null == file)
+    {
+      String path = null;
+      try
+      {
+        path = URLDecoder.decode(name.getPath(), "UTF-8");
+      }
+      catch (final UnsupportedEncodingException e)
+      {
+        path = name.getPath();
+      }
+      final Path filePath = new Path(path);
+      file = new HdfsFileObject((AbstractFileName) name, this, fs, filePath);
+      if (useCache)
+      {
         this.putFileToCache(file);
-            }
+      }
       
     }
     
@@ -160,5 +160,5 @@ public class HdfsFileSystem extends AbstractFileSystem
     
     return file;
   }
-
+  
 }

http://git-wip-us.apache.org/repos/asf/accumulo/blob/5bd4e27c/test/src/main/java/org/apache/accumulo/test/IMMLGBenchmark.java
----------------------------------------------------------------------
diff --git a/test/src/main/java/org/apache/accumulo/test/IMMLGBenchmark.java b/test/src/main/java/org/apache/accumulo/test/IMMLGBenchmark.java
index 8fdba5a..8aa899b 100644
--- a/test/src/main/java/org/apache/accumulo/test/IMMLGBenchmark.java
+++ b/test/src/main/java/org/apache/accumulo/test/IMMLGBenchmark.java
@@ -135,6 +135,12 @@ public class IMMLGBenchmark {
     return t2 - t1;
     
   }
+  
+  static long abs(long l) {
+    if (l < 0)
+      return -l;
+    return l;
+  }
 
   private static long write(Connector conn, ArrayList<byte[]> cfset, String table) throws TableNotFoundException, MutationsRejectedException {
     Random rand = new Random();
@@ -146,7 +152,7 @@ public class IMMLGBenchmark {
     long t1 = System.currentTimeMillis();
 
     for (int i = 0; i < 1 << 15; i++) {
-      byte[] row = FastFormat.toZeroPaddedString(Math.abs(rand.nextLong()), 16, 16, new byte[0]);
+      byte[] row = FastFormat.toZeroPaddedString(abs(rand.nextLong()), 16, 16, new byte[0]);
       
       Mutation m = new Mutation(row);
       for (byte[] cf : cfset) {


Mime
View raw message