ambari-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From smoha...@apache.org
Subject ambari git commit: AMBARI-21157. Logging cleanup around reading config properties file
Date Sun, 23 Jul 2017 01:10:16 GMT
Repository: ambari
Updated Branches:
  refs/heads/branch-2.5 61df6972d -> e57032d26


AMBARI-21157. Logging cleanup around reading config properties file


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

Branch: refs/heads/branch-2.5
Commit: e57032d26633b0a451b123d3109672b638dc40a9
Parents: 61df697
Author: Sumit Mohanty <smohanty@hortonworks.com>
Authored: Sat Jul 22 18:09:54 2017 -0700
Committer: Sumit Mohanty <smohanty@hortonworks.com>
Committed: Sat Jul 22 18:09:54 2017 -0700

----------------------------------------------------------------------
 .../org/apache/ambari/server/configuration/Configuration.java  | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ambari/blob/e57032d2/ambari-server/src/main/java/org/apache/ambari/server/configuration/Configuration.java
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/java/org/apache/ambari/server/configuration/Configuration.java
b/ambari-server/src/main/java/org/apache/ambari/server/configuration/Configuration.java
index fa5ed71..7567755 100644
--- a/ambari-server/src/main/java/org/apache/ambari/server/configuration/Configuration.java
+++ b/ambari-server/src/main/java/org/apache/ambari/server/configuration/Configuration.java
@@ -3946,7 +3946,11 @@ public class Configuration {
       if (result != null) {
         password = new String(result);
       } else {
-        LOG.error("Cannot read password for alias = " + aliasStr);
+        if (CredentialProvider.isAliasString(aliasStr)) {
+          LOG.error("Cannot read password for alias = " + aliasStr);
+        } else {
+          LOG.warn("Raw password provided, not an alias. It cannot be read from credential
store.");
+        }
       }
     }
     return password;


Mime
View raw message