From 0a45bd034e1ce08c556227bb2c815c15be17cf10 Mon Sep 17 00:00:00 2001 From: adamantal Date: Wed, 9 Dec 2020 12:44:13 +0100 Subject: [PATCH] YARN-10520. Deprecated the residual nested class for the LCEResourceHandler (#2527). Contributed by Wanqiang Ji --- .../yarn/server/nodemanager/TestLinuxContainerExecutor.java | 1 + .../server/nodemanager/util/TestCgroupsLCEResourcesHandler.java | 2 ++ 2 files changed, 3 insertions(+) diff --git a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-nodemanager/src/test/java/org/apache/hadoop/yarn/server/nodemanager/TestLinuxContainerExecutor.java b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-nodemanager/src/test/java/org/apache/hadoop/yarn/server/nodemanager/TestLinuxContainerExecutor.java index ae1d0144814..8918588bf37 100644 --- a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-nodemanager/src/test/java/org/apache/hadoop/yarn/server/nodemanager/TestLinuxContainerExecutor.java +++ b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-nodemanager/src/test/java/org/apache/hadoop/yarn/server/nodemanager/TestLinuxContainerExecutor.java @@ -725,6 +725,7 @@ public class TestLinuxContainerExecutor { verify(lce, times(1)).getLocalResources(container); } + @Deprecated private static class TestResourceHandler implements LCEResourcesHandler { static Set postExecContainers = new HashSet(); diff --git a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-nodemanager/src/test/java/org/apache/hadoop/yarn/server/nodemanager/util/TestCgroupsLCEResourcesHandler.java b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-nodemanager/src/test/java/org/apache/hadoop/yarn/server/nodemanager/util/TestCgroupsLCEResourcesHandler.java index 7d8704f8b42..c08075c4c31 100644 --- a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-nodemanager/src/test/java/org/apache/hadoop/yarn/server/nodemanager/util/TestCgroupsLCEResourcesHandler.java +++ b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-nodemanager/src/test/java/org/apache/hadoop/yarn/server/nodemanager/util/TestCgroupsLCEResourcesHandler.java @@ -126,12 +126,14 @@ public class TestCgroupsLCEResourcesHandler { FileUtils.deleteQuietly(cgroupDir); } + @Deprecated static class MockLinuxContainerExecutor extends LinuxContainerExecutor { @Override public void mountCgroups(List x, String y) { } } + @Deprecated static class CustomCgroupsLCEResourceHandler extends CgroupsLCEResourcesHandler {