diff --git a/hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt b/hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt index 9fa06d4966..dfdc21fcdb 100644 --- a/hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt +++ b/hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt @@ -905,6 +905,9 @@ Release 2.6.0 - UNRELEASED HDFS-7105. Allow falling back to a non-SASL connection on DataTransferProtocol in several edge cases. (cnauroth) + HDFS-7107. Avoid Findbugs warning for synchronization on + AbstractNNFailoverProxyProvider#fallbackToSimpleAuth. (cnauroth) + Release 2.5.1 - 2014-09-05 INCOMPATIBLE CHANGES diff --git a/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/namenode/ha/AbstractNNFailoverProxyProvider.java b/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/namenode/ha/AbstractNNFailoverProxyProvider.java index 08e82be59d..a0aa10bf68 100644 --- a/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/namenode/ha/AbstractNNFailoverProxyProvider.java +++ b/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/namenode/ha/AbstractNNFailoverProxyProvider.java @@ -38,12 +38,14 @@ public abstract class AbstractNNFailoverProxyProvider implements public abstract boolean useLogicalURI(); /** - * Set for tracking if a secure client falls back to simple auth. + * Set for tracking if a secure client falls back to simple auth. This method + * is synchronized only to stifle a Findbugs warning. * * @param fallbackToSimpleAuth - set to true or false during this method to * indicate if a secure client falls back to simple auth */ - public void setFallbackToSimpleAuth(AtomicBoolean fallbackToSimpleAuth) { + public synchronized void setFallbackToSimpleAuth( + AtomicBoolean fallbackToSimpleAuth) { this.fallbackToSimpleAuth = fallbackToSimpleAuth; } }