HDFS-10963. Reduce log level when network topology cannot find enough datanodes. Contributed by Xiao chen

This commit is contained in:
Brahma Reddy Battula 2016-10-06 17:47:31 +05:30
parent 272a21747e
commit b90fc70d67
2 changed files with 4 additions and 3 deletions

View File

@ -813,7 +813,7 @@ public class NetworkTopology {
}
}
if (numOfDatanodes == 0) {
LOG.warn("Failed to find datanode (scope=\"{}\" excludedScope=\"{}\").",
LOG.debug("Failed to find datanode (scope=\"{}\" excludedScope=\"{}\").",
String.valueOf(scope), String.valueOf(excludedScope));
return null;
}

View File

@ -49,8 +49,9 @@ import com.google.common.annotations.VisibleForTesting;
public class BlockPlacementPolicyDefault extends BlockPlacementPolicy {
private static final String enableDebugLogging =
"For more information, please enable DEBUG log level on "
+ BlockPlacementPolicy.class.getName();
"For more information, please enable DEBUG log level on "
+ BlockPlacementPolicy.class.getName() + " and "
+ NetworkTopology.class.getName();
private static final ThreadLocal<StringBuilder> debugLoggingBuilder
= new ThreadLocal<StringBuilder>() {