hadoop-common-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bra...@apache.org
Subject [hadoop] branch branch-3.3.0 updated: YARN-10247. Application priority queue ACLs are not respected. Contributed by Sunil G
Date Mon, 04 May 2020 04:22:17 GMT
This is an automated email from the ASF dual-hosted git repository.

brahma pushed a commit to branch branch-3.3.0
in repository https://gitbox.apache.org/repos/asf/hadoop.git


The following commit(s) were added to refs/heads/branch-3.3.0 by this push:
     new 7e632d5  YARN-10247. Application priority queue ACLs are not respected. Contributed
by Sunil G
7e632d5 is described below

commit 7e632d54709609ea5deeadb5b73b44119c600aa4
Author: Szilard Nemeth <snemeth@apache.org>
AuthorDate: Wed Apr 29 15:53:30 2020 +0200

    YARN-10247. Application priority queue ACLs are not respected. Contributed by Sunil G
    
    (cherry picked from commit 410c605aec308a2ccd903f60aade3aaeefcaa610)
    (cherry picked from commit 8ffe1f313c9719ea550ac524fee84320c4aff63c)
---
 .../resourcemanager/scheduler/capacity/CapacityScheduler.java       | 6 +++---
 .../scheduler/capacity/TestApplicationPriorityACLs.java             | 1 +
 2 files changed, 4 insertions(+), 3 deletions(-)

diff --git a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-resourcemanager/src/main/java/org/apache/hadoop/yarn/server/resourcemanager/scheduler/capacity/CapacityScheduler.java
b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-resourcemanager/src/main/java/org/apache/hadoop/yarn/server/resourcemanager/scheduler/capacity/CapacityScheduler.java
index 861dc43..cca4fe1 100644
--- a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-resourcemanager/src/main/java/org/apache/hadoop/yarn/server/resourcemanager/scheduler/capacity/CapacityScheduler.java
+++ b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-resourcemanager/src/main/java/org/apache/hadoop/yarn/server/resourcemanager/scheduler/capacity/CapacityScheduler.java
@@ -2686,10 +2686,10 @@ public class CapacityScheduler extends
       }
 
       // Lets check for ACLs here.
-      if (!appPriorityACLManager.checkAccess(user, queuePath, appPriority)) {
+      if (!appPriorityACLManager.checkAccess(user, normalizeQueueName(queuePath), appPriority))
{
         throw new YarnException(new AccessControlException(
-            "User " + user + " does not have permission to submit/update "
-                + applicationId + " for " + appPriority));
+                "User " + user + " does not have permission to submit/update "
+                        + applicationId + " for " + appPriority));
       }
 
       LOG.info("Priority '" + appPriority.getPriority()
diff --git a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-resourcemanager/src/test/java/org/apache/hadoop/yarn/server/resourcemanager/scheduler/capacity/TestApplicationPriorityACLs.java
b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-resourcemanager/src/test/java/org/apache/hadoop/yarn/server/resourcemanager/scheduler/capacity/TestApplicationPriorityACLs.java
index b41ba83..cf9a010 100644
--- a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-resourcemanager/src/test/java/org/apache/hadoop/yarn/server/resourcemanager/scheduler/capacity/TestApplicationPriorityACLs.java
+++ b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-resourcemanager/src/test/java/org/apache/hadoop/yarn/server/resourcemanager/scheduler/capacity/TestApplicationPriorityACLs.java
@@ -143,6 +143,7 @@ public class TestApplicationPriorityACLs extends ACLsTestBase {
         .newInstance(appSubmissionContext);
     try {
       submitterClient.submitApplication(submitRequest);
+      Assert.fail();
     } catch (YarnException ex) {
       Assert.assertTrue(ex.getCause() instanceof RemoteException);
     }


---------------------------------------------------------------------
To unsubscribe, e-mail: common-commits-unsubscribe@hadoop.apache.org
For additional commands, e-mail: common-commits-help@hadoop.apache.org


Mime
View raw message