From 48e02f79983b32b64d1ae10e8ddf162c06f700d6 Mon Sep 17 00:00:00 2001 From: Szilard Nemeth Date: Thu, 17 Feb 2022 19:17:31 +0100 Subject: [PATCH] YARN-10580. Fix some issues in TestRMWebServicesCapacitySchedDynamicConfig. Contributed by Tamas Domok --- ...tRMWebServicesCapacitySchedDynamicConfig.java | 16 ++++------------ 1 file changed, 4 insertions(+), 12 deletions(-) diff --git a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-resourcemanager/src/test/java/org/apache/hadoop/yarn/server/resourcemanager/webapp/TestRMWebServicesCapacitySchedDynamicConfig.java b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-resourcemanager/src/test/java/org/apache/hadoop/yarn/server/resourcemanager/webapp/TestRMWebServicesCapacitySchedDynamicConfig.java index df4f18e106..0e2ecd0bfa 100644 --- a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-resourcemanager/src/test/java/org/apache/hadoop/yarn/server/resourcemanager/webapp/TestRMWebServicesCapacitySchedDynamicConfig.java +++ b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-resourcemanager/src/test/java/org/apache/hadoop/yarn/server/resourcemanager/webapp/TestRMWebServicesCapacitySchedDynamicConfig.java @@ -102,8 +102,6 @@ public void testSchedulerResponsePercentageMode() throws Exception { Configuration config = CSConfigGenerator .createPercentageConfig(); - config.set(YarnConfiguration.SCHEDULER_CONFIGURATION_STORE_CLASS, - YarnConfiguration.MEMORY_CONFIGURATION_STORE); initResourceManager(config); @@ -121,8 +119,6 @@ public void testSchedulerResponsePercentageModeLegacyAutoCreation() throws Exception { Configuration config = CSConfigGenerator .createPercentageConfigLegacyAutoCreation(); - config.set(YarnConfiguration.SCHEDULER_CONFIGURATION_STORE_CLASS, - YarnConfiguration.MEMORY_CONFIGURATION_STORE); initResourceManager(config); @@ -141,8 +137,6 @@ public void testSchedulerResponseAbsoluteModeLegacyAutoCreation() throws Exception { Configuration config = CSConfigGenerator .createAbsoluteConfigLegacyAutoCreation(); - config.set(YarnConfiguration.SCHEDULER_CONFIGURATION_STORE_CLASS, - YarnConfiguration.MEMORY_CONFIGURATION_STORE); initResourceManager(config); initAutoQueueHandler(8192 * GB); @@ -157,8 +151,6 @@ public void testSchedulerResponseAbsoluteMode() throws Exception { Configuration config = CSConfigGenerator .createAbsoluteConfig(); - config.set(YarnConfiguration.SCHEDULER_CONFIGURATION_STORE_CLASS, - YarnConfiguration.MEMORY_CONFIGURATION_STORE); initResourceManager(config); @@ -176,8 +168,6 @@ public void testSchedulerResponseWeightMode() throws Exception { Configuration config = CSConfigGenerator .createWeightConfig(); - config.set(YarnConfiguration.SCHEDULER_CONFIGURATION_STORE_CLASS, - YarnConfiguration.MEMORY_CONFIGURATION_STORE); initResourceManager(config); @@ -197,8 +187,6 @@ public void testSchedulerResponseWeightModeWithAutoCreatedQueues() throws Exception { Configuration config = CSConfigGenerator .createWeightConfigWithAutoQueueCreationEnabled(); - config.set(YarnConfiguration.SCHEDULER_CONFIGURATION_STORE_CLASS, - YarnConfiguration.MEMORY_CONFIGURATION_STORE); config.setInt(CapacitySchedulerConfiguration .getQueuePrefix("root.autoParent1") + AutoCreatedQueueTemplate.AUTO_QUEUE_TEMPLATE_PREFIX + @@ -332,6 +320,10 @@ public static Configuration createConfiguration( for (Map.Entry entry : configs.entrySet()) { config.set(entry.getKey(), entry.getValue()); } + + config.set(YarnConfiguration.SCHEDULER_CONFIGURATION_STORE_CLASS, + YarnConfiguration.MEMORY_CONFIGURATION_STORE); + return config; } }