You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-nodemanager/src/main/java/org/apache/hadoop/yarn/server/nodemanager/NodeStatusUpdaterImpl.java
+7-4Lines changed: 7 additions & 4 deletions
Original file line number
Diff line number
Diff line change
@@ -777,17 +777,20 @@ public void removeVeryOldStoppedContainersFromCache() {
777
777
while (i.hasNext()) {
778
778
Entry<ContainerId, Long> mapEntry = i.next();
779
779
ContainerIdcid = mapEntry.getKey();
780
-
if (mapEntry.getValue() < currentTime) {
781
-
if (!context.getContainers().containsKey(cid)) {
780
+
if (mapEntry.getValue() >= currentTime) {
781
+
break;
782
+
}
783
+
if (!context.getContainers().containsKey(cid)) {
784
+
ApplicationIdappId =
785
+
cid.getApplicationAttemptId().getApplicationId();
786
+
if (isApplicationStopped(appId)) {
782
787
i.remove();
783
788
try {
784
789
context.getNMStateStore().removeContainer(cid);
785
790
} catch (IOExceptione) {
786
791
LOG.error("Unable to remove container " + cid + " in store", e);
Copy file name to clipboardExpand all lines: hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-nodemanager/src/test/java/org/apache/hadoop/yarn/server/nodemanager/TestNodeStatusUpdater.java
+11-13Lines changed: 11 additions & 13 deletions
Original file line number
Diff line number
Diff line change
@@ -931,9 +931,8 @@ public void deleteBaseDir() throws IOException {
0 commit comments