hadoop-common-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From kih...@apache.org
Subject hadoop git commit: HDFS-10417. Improve error message from checkBlockLocalPathAccess. Contributed by Tianyin Xu.
Date Thu, 19 May 2016 20:53:16 GMT
Repository: hadoop
Updated Branches:
  refs/heads/trunk feb90ffcc -> 204de430b


HDFS-10417. Improve error message from checkBlockLocalPathAccess. Contributed by Tianyin Xu.


Project: http://git-wip-us.apache.org/repos/asf/hadoop/repo
Commit: http://git-wip-us.apache.org/repos/asf/hadoop/commit/204de430
Tree: http://git-wip-us.apache.org/repos/asf/hadoop/tree/204de430
Diff: http://git-wip-us.apache.org/repos/asf/hadoop/diff/204de430

Branch: refs/heads/trunk
Commit: 204de430bf6a931e5688789c7a783c9c568a98c2
Parents: feb90ff
Author: Kihwal Lee <kihwal@apache.org>
Authored: Thu May 19 15:52:32 2016 -0500
Committer: Kihwal Lee <kihwal@apache.org>
Committed: Thu May 19 15:52:32 2016 -0500

----------------------------------------------------------------------
 .../java/org/apache/hadoop/hdfs/server/datanode/DataNode.java  | 3 ++-
 .../hadoop/hdfs/shortcircuit/TestShortCircuitLocalRead.java    | 6 ++++--
 2 files changed, 6 insertions(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/hadoop/blob/204de430/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/datanode/DataNode.java
----------------------------------------------------------------------
diff --git a/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/datanode/DataNode.java
b/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/datanode/DataNode.java
index 288fc3e..410472e 100644
--- a/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/datanode/DataNode.java
+++ b/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/datanode/DataNode.java
@@ -1717,7 +1717,8 @@ public class DataNode extends ReconfigurableBase
       throw new AccessControlException(
           "Can't continue with getBlockLocalPathInfo() "
               + "authorization. The user " + currentUser
-              + " is not allowed to call getBlockLocalPathInfo");
+              + " is not configured in "
+              + DFSConfigKeys.DFS_BLOCK_LOCAL_PATH_ACCESS_USER_KEY);
     }
   }
 

http://git-wip-us.apache.org/repos/asf/hadoop/blob/204de430/hadoop-hdfs-project/hadoop-hdfs/src/test/java/org/apache/hadoop/hdfs/shortcircuit/TestShortCircuitLocalRead.java
----------------------------------------------------------------------
diff --git a/hadoop-hdfs-project/hadoop-hdfs/src/test/java/org/apache/hadoop/hdfs/shortcircuit/TestShortCircuitLocalRead.java
b/hadoop-hdfs-project/hadoop-hdfs/src/test/java/org/apache/hadoop/hdfs/shortcircuit/TestShortCircuitLocalRead.java
index 299865b..067b8ce 100644
--- a/hadoop-hdfs-project/hadoop-hdfs/src/test/java/org/apache/hadoop/hdfs/shortcircuit/TestShortCircuitLocalRead.java
+++ b/hadoop-hdfs-project/hadoop-hdfs/src/test/java/org/apache/hadoop/hdfs/shortcircuit/TestShortCircuitLocalRead.java
@@ -375,10 +375,12 @@ public class TestShortCircuitLocalRead {
       try {
         proxy.getBlockLocalPathInfo(blk, token);
         Assert.fail("The call should have failed as this user "
-            + " is not allowed to call getBlockLocalPathInfo");
+            + " is not configured in "
+            + DFSConfigKeys.DFS_BLOCK_LOCAL_PATH_ACCESS_USER_KEY);
       } catch (IOException ex) {
         Assert.assertTrue(ex.getMessage().contains(
-            "not allowed to call getBlockLocalPathInfo"));
+            "not configured in "
+            + DFSConfigKeys.DFS_BLOCK_LOCAL_PATH_ACCESS_USER_KEY));
       }
     } finally {
       fs.close();


---------------------------------------------------------------------
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