summaryrefslogtreecommitdiffstats
path: root/appc-core
diff options
context:
space:
mode:
authorZihmin Hoover <zh4590@att.com>2019-11-22 14:53:04 -0500
committerZihmin Hoover <zh4590@att.com>2019-11-22 14:58:19 -0500
commit0f9c0df9e651bbcbdb3e4b8133f57abe2482cbec (patch)
tree65f8d509a21a607439368143cf30e4b6bd1e3ec4 /appc-core
parent7b1313a9d6621f8c16dee4a21136f7d825a42c1d (diff)
Add context sensitive logging to ConfigurationFactory.java
Add context sensitive logging to ConfigurationFactory.java Change-Id: I950687870f2c9d9835ec6b04ccb73ef57c884152 Issue-ID: APPC-1782 Signed-off-by: Zihmin Hoover <zh4590@att.com>
Diffstat (limited to 'appc-core')
-rw-r--r--appc-core/appc-common-bundle/src/main/java/org/onap/appc/configuration/ConfigurationFactory.java6
1 files changed, 5 insertions, 1 deletions
diff --git a/appc-core/appc-common-bundle/src/main/java/org/onap/appc/configuration/ConfigurationFactory.java b/appc-core/appc-common-bundle/src/main/java/org/onap/appc/configuration/ConfigurationFactory.java
index 9ea5083fe..d66a3fe82 100644
--- a/appc-core/appc-common-bundle/src/main/java/org/onap/appc/configuration/ConfigurationFactory.java
+++ b/appc-core/appc-common-bundle/src/main/java/org/onap/appc/configuration/ConfigurationFactory.java
@@ -36,6 +36,7 @@ import java.util.Properties;
import java.util.concurrent.locks.ReentrantReadWriteLock;
import java.util.concurrent.locks.ReentrantReadWriteLock.ReadLock;
import java.util.concurrent.locks.ReentrantReadWriteLock.WriteLock;
+import org.apache.commons.lang3.StringUtils;
import org.onap.appc.i18n.Msg;
import com.att.eelf.configuration.EELFLogger;
import com.att.eelf.configuration.EELFManager;
@@ -312,7 +313,10 @@ public final class ConfigurationFactory {
}
}
for (String key : config.getProperties().stringPropertyNames()) {
- logger.info(Msg.PROPERTY_VALUE, key, config.getProperty(key));
+ if ((!StringUtils.containsIgnoreCase(key, "pass"))&&(!StringUtils.containsIgnoreCase(key, "secret")))
+ logger.info(Msg.PROPERTY_VALUE, key, config.getProperty(key));
+ else
+ logger.info(Msg.PROPERTY_VALUE, key, config.getProperty(key));
}
} else {
logger.info(Msg.NO_DEFAULTS_FOUND, DEFAULT_PROPERTIES);