activemq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From clebertsuco...@apache.org
Subject activemq-artemis git commit: ARTEMIS-840 removing password log that was forgotten
Date Mon, 07 Nov 2016 20:27:47 GMT
Repository: activemq-artemis
Updated Branches:
  refs/heads/master e83eb3829 -> df4c3c858


ARTEMIS-840 removing password log that was forgotten


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

Branch: refs/heads/master
Commit: df4c3c858400fa3e5612e5874a4c34b64393e68d
Parents: e83eb38
Author: Clebert Suconic <clebertsuconic@apache.org>
Authored: Mon Nov 7 15:22:29 2016 -0500
Committer: Clebert Suconic <clebertsuconic@apache.org>
Committed: Mon Nov 7 15:27:17 2016 -0500

----------------------------------------------------------------------
 .../activemq/artemis/api/core/TransportConfiguration.java   | 9 +++++++--
 .../artemis/core/client/impl/ClientSessionFactoryImpl.java  | 7 ++-----
 2 files changed, 9 insertions(+), 7 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/df4c3c85/artemis-core-client/src/main/java/org/apache/activemq/artemis/api/core/TransportConfiguration.java
----------------------------------------------------------------------
diff --git a/artemis-core-client/src/main/java/org/apache/activemq/artemis/api/core/TransportConfiguration.java
b/artemis-core-client/src/main/java/org/apache/activemq/artemis/api/core/TransportConfiguration.java
index 3b0359f..71679b5 100644
--- a/artemis-core-client/src/main/java/org/apache/activemq/artemis/api/core/TransportConfiguration.java
+++ b/artemis-core-client/src/main/java/org/apache/activemq/artemis/api/core/TransportConfiguration.java
@@ -23,7 +23,6 @@ import java.util.Map;
 
 import org.apache.activemq.artemis.core.client.ActiveMQClientMessageBundle;
 import org.apache.activemq.artemis.core.remoting.impl.TransportConfigurationUtil;
-import org.apache.activemq.artemis.core.remoting.impl.netty.TransportConstants;
 import org.apache.activemq.artemis.utils.JsonLoader;
 import org.apache.activemq.artemis.utils.UUIDGenerator;
 
@@ -247,6 +246,12 @@ public class TransportConfiguration implements Serializable {
       str.append("(name=" + name + ", ");
       str.append("factory=" + replaceWildcardChars(factoryClassName));
       str.append(") ");
+      str.append(toStringParameters(params, extraProps));
+      return str.toString();
+   }
+
+   public static String toStringParameters(Map<String, Object> params, Map<String,
Object> extraProps) {
+      StringBuilder str = new StringBuilder();
       if (params != null) {
          if (!params.isEmpty()) {
             str.append("?");
@@ -262,7 +267,7 @@ public class TransportConfiguration implements Serializable {
 
             // HORNETQ-1281 - don't log passwords
             String val;
-            if (key.equals(TransportConstants.KEYSTORE_PASSWORD_PROP_NAME) || key.equals(TransportConstants.TRUSTSTORE_PASSWORD_PROP_NAME))
{
+            if (key.toLowerCase().contains("password")) {
                val = "****";
             } else {
                val = entry.getValue() == null ? "null" : entry.getValue().toString();

http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/df4c3c85/artemis-core-client/src/main/java/org/apache/activemq/artemis/core/client/impl/ClientSessionFactoryImpl.java
----------------------------------------------------------------------
diff --git a/artemis-core-client/src/main/java/org/apache/activemq/artemis/core/client/impl/ClientSessionFactoryImpl.java
b/artemis-core-client/src/main/java/org/apache/activemq/artemis/core/client/impl/ClientSessionFactoryImpl.java
index d2d9886..addbbbd 100644
--- a/artemis-core-client/src/main/java/org/apache/activemq/artemis/core/client/impl/ClientSessionFactoryImpl.java
+++ b/artemis-core-client/src/main/java/org/apache/activemq/artemis/core/client/impl/ClientSessionFactoryImpl.java
@@ -1067,11 +1067,8 @@ public class ClientSessionFactoryImpl implements ClientSessionFactoryInternal,
C
 
       try {
          if (logger.isDebugEnabled()) {
-            logger.debug("Trying to connect with connector = " + connectorFactory +
-                            ", parameters = " +
-                            connectorConfig.getParams() +
-                            " connector = " +
-                            connector);
+            logger.debug("Trying to connect with connectorFactory = " + connectorFactory
+
+                           ", connectorConfig=" + connectorConfig);
          }
 
          Connector liveConnector = createConnector(connectorFactory, connectorConfig);


Mime
View raw message