public class UserGroupMappingPlacementRule extends PlacementRule
| Modifier and Type | Field and Description | 
|---|---|
| static String | CURRENT_USER_MAPPING | 
| static String | PRIMARY_GROUP_MAPPING | 
| static String | SECONDARY_GROUP_MAPPING | 
| Constructor and Description | 
|---|
| UserGroupMappingPlacementRule() | 
| Modifier and Type | Method and Description | 
|---|---|
| ApplicationPlacementContext | getPlacementForApp(org.apache.hadoop.yarn.api.records.ApplicationSubmissionContext asc,
                  String user)Return the scheduler queue name the application should be placed in
 wrapped in an  ApplicationPlacementContextobject. | 
| List<QueueMapping> | getQueueMappings() | 
| boolean | initialize(ResourceScheduler scheduler)Initialize the rule with the scheduler. | 
| void | setQueueManager(CapacitySchedulerQueueManager queueManager) | 
getName, setConfigpublic static final String CURRENT_USER_MAPPING
public static final String PRIMARY_GROUP_MAPPING
public static final String SECONDARY_GROUP_MAPPING
public ApplicationPlacementContext getPlacementForApp(org.apache.hadoop.yarn.api.records.ApplicationSubmissionContext asc, String user) throws org.apache.hadoop.yarn.exceptions.YarnException
PlacementRuleApplicationPlacementContext object.
 A non null return value places the application in a queue,
 a null value means the queue is not yet determined. The
 next PlacementRule in the list maintained in the
 PlacementManager will be executed.getPlacementForApp in class PlacementRuleasc - The context of the application created on submissionuser - The name of the user submitting the applicationApplicationPlacementContext or
 null if no queue was resolvedorg.apache.hadoop.yarn.exceptions.YarnException - for any error while executing the rulepublic boolean initialize(ResourceScheduler scheduler) throws IOException
PlacementRuleinitialize in class PlacementRulescheduler - the scheduler using the ruletrue or false The outcome of the
 initialisation, rule dependent response which might not be persisted in
 the rule.IOException - for any errorspublic List<QueueMapping> getQueueMappings()
@InterfaceAudience.Private public void setQueueManager(CapacitySchedulerQueueManager queueManager)
Copyright © 2008–2023 Apache Software Foundation. All rights reserved.