浏览代码

YARN-8326. Removed exit code file check for launched container.
Contributed by Shane Kumpf

Eric Yang 7 年之前
父节点
当前提交
8a32bc39eb

+ 0 - 19
hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-nodemanager/src/main/java/org/apache/hadoop/yarn/server/nodemanager/containermanager/launcher/ContainerLaunch.java

@@ -808,25 +808,6 @@ public class ContainerLaunch implements Callable<Integer> {
       }
     }
 
-    final int sleepMsec = 100;
-    int msecLeft = 2000;
-    if (pidFilePath != null) {
-      File file = new File(getExitCodeFile(pidFilePath.toString()));
-      while (!file.exists() && msecLeft >= 0) {
-        try {
-          Thread.sleep(sleepMsec);
-        } catch (InterruptedException e) {
-        }
-        msecLeft -= sleepMsec;
-      }
-      if (msecLeft < 0) {
-        if (LOG.isDebugEnabled()) {
-          LOG.debug("Timeout while waiting for the exit code file:  "
-              + file.getAbsolutePath());
-        }
-      }
-    }
-
     // Reap the container
     boolean result = exec.reapContainer(
         new ContainerReapContext.Builder()