goiri commented on a change in pull request #3632:
URL: https://github.com/apache/hadoop/pull/3632#discussion_r755351473



##########
File path: 
hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-nodemanager/src/main/java/org/apache/hadoop/yarn/server/nodemanager/containermanager/container/ContainerImpl.java
##########
@@ -1264,6 +1263,15 @@ public ContainerState transition(ContainerImpl container,
         return ContainerState.LOCALIZATION_FAILED;
       }
     }
+
+    static boolean isContainerRecoveredAsKilled(ContainerImpl container)
+    {
+      // container was killed but never launched
+      return container.recoveredAsKilled && (

Review comment:
       As we have a full function, it is probably to have a split sequence:
   ```
   if (!container.recoveredAsKilled) {
       return false;
   }
   RecoveredContainerStatus containerStatus = container.recoveredStatus;
   return containerStatus == RecoveredContainerStatus.REQUESTED || 
containerStatus  == RecoveredContainerStatus.QUEUED;
   ```

##########
File path: 
hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-nodemanager/src/main/java/org/apache/hadoop/yarn/server/nodemanager/containermanager/container/ContainerImpl.java
##########
@@ -1264,6 +1263,15 @@ public ContainerState transition(ContainerImpl container,
         return ContainerState.LOCALIZATION_FAILED;
       }
     }
+
+    static boolean isContainerRecoveredAsKilled(ContainerImpl container)
+    {

Review comment:
       the { should go in the previous line




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to