浏览代码

Remove super user privilege requirement for NameNode.getServiceStatus. Contributed by Chao Sun.

Chao Sun 7 年之前
父节点
当前提交
a2a8c48699

+ 0 - 1
hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/namenode/NameNode.java

@@ -1757,7 +1757,6 @@ public class NameNode extends ReconfigurableBase implements
 
 
   synchronized HAServiceStatus getServiceStatus()
   synchronized HAServiceStatus getServiceStatus()
       throws ServiceFailedException, AccessControlException {
       throws ServiceFailedException, AccessControlException {
-    namesystem.checkSuperuserPrivilege();
     if (!haEnabled) {
     if (!haEnabled) {
       throw new ServiceFailedException("HA for namenode is not enabled");
       throw new ServiceFailedException("HA for namenode is not enabled");
     }
     }