diff --git a/hadoop-yarn-project/CHANGES.txt b/hadoop-yarn-project/CHANGES.txt index 1718c1451ee..c809fd0a09c 100644 --- a/hadoop-yarn-project/CHANGES.txt +++ b/hadoop-yarn-project/CHANGES.txt @@ -865,6 +865,9 @@ Release 2.6.0 - 2014-11-15 YARN-2843. Fixed NodeLabelsManager to trim inputs for hosts and labels so as to make them work correctly. (Wangda Tan via vinodkv) + YARN-2794. Fixed log messages about distributing system-credentials. (Jian He via + zjshen) + Release 2.5.2 - 2014-11-10 INCOMPATIBLE CHANGES diff --git a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-nodemanager/src/main/java/org/apache/hadoop/yarn/server/nodemanager/NodeManager.java b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-nodemanager/src/main/java/org/apache/hadoop/yarn/server/nodemanager/NodeManager.java index 4f90bf53e6f..53cbb115a80 100644 --- a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-nodemanager/src/main/java/org/apache/hadoop/yarn/server/nodemanager/NodeManager.java +++ b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-nodemanager/src/main/java/org/apache/hadoop/yarn/server/nodemanager/NodeManager.java @@ -317,7 +317,7 @@ public class NodeManager extends CompositeService protected final ConcurrentMap applications = new ConcurrentHashMap(); - private Map systemCredentials = + private volatile Map systemCredentials = new HashMap(); protected final ConcurrentMap containers = diff --git a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-nodemanager/src/main/java/org/apache/hadoop/yarn/server/nodemanager/NodeStatusUpdaterImpl.java b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-nodemanager/src/main/java/org/apache/hadoop/yarn/server/nodemanager/NodeStatusUpdaterImpl.java index fcdd2c152ce..f561dbb4760 100644 --- a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-nodemanager/src/main/java/org/apache/hadoop/yarn/server/nodemanager/NodeStatusUpdaterImpl.java +++ b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-nodemanager/src/main/java/org/apache/hadoop/yarn/server/nodemanager/NodeStatusUpdaterImpl.java @@ -552,7 +552,10 @@ public class NodeStatusUpdaterImpl extends AbstractService implements map.put(entry.getKey(), credentials); } if (LOG.isDebugEnabled()) { - LOG.debug("Retrieved credentials form RM: " + map); + for (Map.Entry entry : map.entrySet()) { + LOG.debug("Retrieved credentials form RM for " + entry.getKey() + ": " + + entry.getValue().getAllTokens()); + } } return map; } diff --git a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-nodemanager/src/main/java/org/apache/hadoop/yarn/server/nodemanager/containermanager/localizer/ResourceLocalizationService.java b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-nodemanager/src/main/java/org/apache/hadoop/yarn/server/nodemanager/containermanager/localizer/ResourceLocalizationService.java index cb56d67a884..f4b6221a7bf 100644 --- a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-nodemanager/src/main/java/org/apache/hadoop/yarn/server/nodemanager/containermanager/localizer/ResourceLocalizationService.java +++ b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-nodemanager/src/main/java/org/apache/hadoop/yarn/server/nodemanager/containermanager/localizer/ResourceLocalizationService.java @@ -1122,9 +1122,9 @@ public class ResourceLocalizationService extends CompositeService if (systemCredentials == null) { return null; } - for (Token token : systemCredentials.getAllTokens()) { - LOG.info("Adding new framework-token for " + appId - + " for localization: " + token); + if (LOG.isDebugEnabled()) { + LOG.debug("Adding new framework-token for " + appId + + " for localization: " + systemCredentials.getAllTokens()); } return systemCredentials; } diff --git a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-nodemanager/src/main/java/org/apache/hadoop/yarn/server/nodemanager/containermanager/logaggregation/AppLogAggregatorImpl.java b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-nodemanager/src/main/java/org/apache/hadoop/yarn/server/nodemanager/containermanager/logaggregation/AppLogAggregatorImpl.java index 3174c5cfeeb..20887b66483 100644 --- a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-nodemanager/src/main/java/org/apache/hadoop/yarn/server/nodemanager/containermanager/logaggregation/AppLogAggregatorImpl.java +++ b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-nodemanager/src/main/java/org/apache/hadoop/yarn/server/nodemanager/containermanager/logaggregation/AppLogAggregatorImpl.java @@ -202,9 +202,10 @@ public class AppLogAggregatorImpl implements AppLogAggregator { Credentials systemCredentials = context.getSystemCredentialsForApps().get(appId); if (systemCredentials != null) { - for (Token token : systemCredentials.getAllTokens()) { - LOG.info("Adding new framework-token for " + appId - + " for log-aggregation: " + token + " user=" + userUgi); + if (LOG.isDebugEnabled()) { + LOG.debug("Adding new framework-token for " + appId + + " for log-aggregation: " + systemCredentials.getAllTokens() + + "; userUgi=" + userUgi); } // this will replace old token userUgi.addCredentials(systemCredentials);