From 3fcc7a55b6ee8f93ff01061aec0aefc81d98eaab Mon Sep 17 00:00:00 2001 From: Jim Brennan Date: Tue, 16 Feb 2021 16:45:35 +0000 Subject: [PATCH] [YARN-10626] Log resource allocation in NM log at container start time. Contributed by Eric Badger --- .../nodemanager/containermanager/ContainerManagerImpl.java | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) 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/ContainerManagerImpl.java b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-nodemanager/src/main/java/org/apache/hadoop/yarn/server/nodemanager/containermanager/ContainerManagerImpl.java index 2cb334bf7fb..5eb36ba558e 100644 --- a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-nodemanager/src/main/java/org/apache/hadoop/yarn/server/nodemanager/containermanager/ContainerManagerImpl.java +++ b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-nodemanager/src/main/java/org/apache/hadoop/yarn/server/nodemanager/containermanager/ContainerManagerImpl.java @@ -1082,8 +1082,10 @@ public class ContainerManagerImpl extends CompositeService implements ContainerId containerId = containerTokenIdentifier.getContainerID(); String containerIdStr = containerId.toString(); String user = containerTokenIdentifier.getApplicationSubmitter(); + Resource containerResource = containerTokenIdentifier.getResource(); - LOG.info("Start request for " + containerIdStr + " by user " + remoteUser); + LOG.info("Start request for " + containerIdStr + " by user " + remoteUser + + " with resource " + containerResource); ContainerLaunchContext launchContext = request.getContainerLaunchContext();