YARN-10597. CSMappingPlacementRule should not create new instance of Groups. Contributed by Gergely Pollak
This commit is contained in:
parent
ff6ec20d84
commit
6fd0c661b6
|
@ -132,11 +132,7 @@ public class CSMappingPlacementRule extends PlacementRule {
|
||||||
overrideWithQueueMappings = conf.getOverrideWithQueueMappings();
|
overrideWithQueueMappings = conf.getOverrideWithQueueMappings();
|
||||||
|
|
||||||
if (groups == null) {
|
if (groups == null) {
|
||||||
//We cannot use Groups#getUserToGroupsMappingService here, because when
|
groups = Groups.getUserToGroupsMappingService(conf);
|
||||||
//tests change the HADOOP_SECURITY_GROUP_MAPPING, Groups won't refresh its
|
|
||||||
//cached instance of groups, so we might get a Group instance which
|
|
||||||
//ignores the HADOOP_SECURITY_GROUP_MAPPING settings.
|
|
||||||
groups = new Groups(conf);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
MappingRuleValidationContext validationContext = buildValidationContext();
|
MappingRuleValidationContext validationContext = buildValidationContext();
|
||||||
|
|
Loading…
Reference in New Issue