YARN-7755. Clean up deprecation messages for allocation increments in FS config. Contributed by Wilfred Spiegelenburg.
This commit is contained in:
parent
6e27b20b4d
commit
22ee6f77e5
|
@ -45,19 +45,29 @@ public class FairSchedulerConfiguration extends Configuration {
|
||||||
public static final Log LOG = LogFactory.getLog(
|
public static final Log LOG = LogFactory.getLog(
|
||||||
FairSchedulerConfiguration.class.getName());
|
FairSchedulerConfiguration.class.getName());
|
||||||
|
|
||||||
/** Increment request grant-able by the RM scheduler.
|
/**
|
||||||
* These properties are looked up in the yarn-site.xml.
|
* Resource Increment request grant-able by the FairScheduler.
|
||||||
* Kept for backward-compatibility - the new preferred way to configure the
|
* This property is looked up in the yarn-site.xml.
|
||||||
* increment is the yarn.resource-types.{RESOURCE_NAME}.increment-allocation
|
* @deprecated The preferred way to configure the increment is by using the
|
||||||
* property, specifically: yarn.resource-types.memory-mb.increment-allocation
|
* yarn.resource-types.{RESOURCE_NAME}.increment-allocation property,
|
||||||
* for memory and yarn.resource-types.vcores.increment-allocation for CPU */
|
* for memory: yarn.resource-types.memory-mb.increment-allocation
|
||||||
|
*/
|
||||||
@Deprecated
|
@Deprecated
|
||||||
public static final String RM_SCHEDULER_INCREMENT_ALLOCATION_MB =
|
public static final String RM_SCHEDULER_INCREMENT_ALLOCATION_MB =
|
||||||
YarnConfiguration.YARN_PREFIX + "scheduler.increment-allocation-mb";
|
YarnConfiguration.YARN_PREFIX + "scheduler.increment-allocation-mb";
|
||||||
|
@Deprecated
|
||||||
public static final int DEFAULT_RM_SCHEDULER_INCREMENT_ALLOCATION_MB = 1024;
|
public static final int DEFAULT_RM_SCHEDULER_INCREMENT_ALLOCATION_MB = 1024;
|
||||||
|
/**
|
||||||
|
* Resource Increment request grant-able by the FairScheduler.
|
||||||
|
* This property is looked up in the yarn-site.xml.
|
||||||
|
* @deprecated The preferred way to configure the increment is by using the
|
||||||
|
* yarn.resource-types.{RESOURCE_NAME}.increment-allocation property,
|
||||||
|
* for CPU: yarn.resource-types.vcores.increment-allocation
|
||||||
|
*/
|
||||||
@Deprecated
|
@Deprecated
|
||||||
public static final String RM_SCHEDULER_INCREMENT_ALLOCATION_VCORES =
|
public static final String RM_SCHEDULER_INCREMENT_ALLOCATION_VCORES =
|
||||||
YarnConfiguration.YARN_PREFIX + "scheduler.increment-allocation-vcores";
|
YarnConfiguration.YARN_PREFIX + "scheduler.increment-allocation-vcores";
|
||||||
|
@Deprecated
|
||||||
public static final int DEFAULT_RM_SCHEDULER_INCREMENT_ALLOCATION_VCORES = 1;
|
public static final int DEFAULT_RM_SCHEDULER_INCREMENT_ALLOCATION_VCORES = 1;
|
||||||
|
|
||||||
/** Threshold for container size for making a container reservation as a
|
/** Threshold for container size for making a container reservation as a
|
||||||
|
|
|
@ -1054,7 +1054,7 @@ public class TestFairScheduler extends FairSchedulerTestBase {
|
||||||
|
|
||||||
// Asked for less than increment allocation.
|
// Asked for less than increment allocation.
|
||||||
assertEquals(
|
assertEquals(
|
||||||
FairSchedulerConfiguration.DEFAULT_RM_SCHEDULER_INCREMENT_ALLOCATION_MB,
|
YarnConfiguration.DEFAULT_RM_SCHEDULER_MINIMUM_ALLOCATION_MB,
|
||||||
scheduler.getQueueManager().getQueue("queue1").
|
scheduler.getQueueManager().getQueue("queue1").
|
||||||
getResourceUsage().getMemorySize());
|
getResourceUsage().getMemorySize());
|
||||||
|
|
||||||
|
@ -2113,7 +2113,7 @@ public class TestFairScheduler extends FairSchedulerTestBase {
|
||||||
scheduler.start();
|
scheduler.start();
|
||||||
scheduler.reinitialize(conf, resourceManager.getRMContext());
|
scheduler.reinitialize(conf, resourceManager.getRMContext());
|
||||||
int minReqSize =
|
int minReqSize =
|
||||||
FairSchedulerConfiguration.DEFAULT_RM_SCHEDULER_INCREMENT_ALLOCATION_MB;
|
YarnConfiguration.DEFAULT_RM_SCHEDULER_MINIMUM_ALLOCATION_MB;
|
||||||
|
|
||||||
// First ask, queue1 requests 1 large (minReqSize * 2).
|
// First ask, queue1 requests 1 large (minReqSize * 2).
|
||||||
ApplicationAttemptId id11 = createAppAttemptId(1, 1);
|
ApplicationAttemptId id11 = createAppAttemptId(1, 1);
|
||||||
|
|
Loading…
Reference in New Issue