diff --git a/hbase-client/src/main/java/org/apache/hadoop/hbase/client/BufferedMutatorImpl.java b/hbase-client/src/main/java/org/apache/hadoop/hbase/client/BufferedMutatorImpl.java index c772b782db7..b91038d0073 100644 --- a/hbase-client/src/main/java/org/apache/hadoop/hbase/client/BufferedMutatorImpl.java +++ b/hbase-client/src/main/java/org/apache/hadoop/hbase/client/BufferedMutatorImpl.java @@ -73,7 +73,7 @@ public class BufferedMutatorImpl implements BufferedMutator { * The {@link ConcurrentLinkedQueue#size()} is NOT a constant-time operation. */ private final AtomicInteger undealtMutationCount = new AtomicInteger(0); - private volatile long writeBufferSize; + private final long writeBufferSize; private final int maxKeyValueSize; private final ExecutorService pool; private final AtomicInteger rpcTimeout; diff --git a/hbase-client/src/main/java/org/apache/hadoop/hbase/client/HBaseAdmin.java b/hbase-client/src/main/java/org/apache/hadoop/hbase/client/HBaseAdmin.java index 2ea7c74f173..ef054b6a466 100644 --- a/hbase-client/src/main/java/org/apache/hadoop/hbase/client/HBaseAdmin.java +++ b/hbase-client/src/main/java/org/apache/hadoop/hbase/client/HBaseAdmin.java @@ -227,7 +227,7 @@ public class HBaseAdmin implements Admin { private ClusterConnection connection; - private volatile Configuration conf; + private final Configuration conf; private final long pause; private final int numRetries; private final int syncWaitTimeout; diff --git a/hbase-server/src/main/java/org/apache/hadoop/hbase/ZKNamespaceManager.java b/hbase-server/src/main/java/org/apache/hadoop/hbase/ZKNamespaceManager.java index de21ce082d5..9e228ad40c8 100644 --- a/hbase-server/src/main/java/org/apache/hadoop/hbase/ZKNamespaceManager.java +++ b/hbase-server/src/main/java/org/apache/hadoop/hbase/ZKNamespaceManager.java @@ -51,7 +51,7 @@ import java.util.concurrent.ConcurrentSkipListMap; public class ZKNamespaceManager extends ZKListener { private static final Log LOG = LogFactory.getLog(ZKNamespaceManager.class); private final String nsZNode; - private volatile NavigableMap cache; + private final NavigableMap cache; public ZKNamespaceManager(ZKWatcher zkw) throws IOException { super(zkw);