brooklyn-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From aleds...@apache.org
Subject [1/4] brooklyn-server git commit: BROOKLYN-282 Avoid showing secret effector parameters
Date Wed, 08 Jun 2016 12:51:31 GMT
Repository: brooklyn-server
Updated Branches:
  refs/heads/master 98a909ce3 -> 01b0af830


BROOKLYN-282 Avoid showing secret effector parameters

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

Branch: refs/heads/master
Commit: c22d0f903153e3cae6537b6c4cb289b36f236fbd
Parents: 19e63db
Author: Yavor Yanchev <yavor@yanchev.com>
Authored: Mon Jun 6 15:33:24 2016 +0300
Committer: Valentin Aitken <bostko@gmail.com>
Committed: Mon Jun 6 21:11:16 2016 +0300

----------------------------------------------------------------------
 .../org/apache/brooklyn/core/mgmt/internal/EffectorUtils.java   | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/brooklyn-server/blob/c22d0f90/core/src/main/java/org/apache/brooklyn/core/mgmt/internal/EffectorUtils.java
----------------------------------------------------------------------
diff --git a/core/src/main/java/org/apache/brooklyn/core/mgmt/internal/EffectorUtils.java
b/core/src/main/java/org/apache/brooklyn/core/mgmt/internal/EffectorUtils.java
index 7263f3b..d5cde94 100644
--- a/core/src/main/java/org/apache/brooklyn/core/mgmt/internal/EffectorUtils.java
+++ b/core/src/main/java/org/apache/brooklyn/core/mgmt/internal/EffectorUtils.java
@@ -33,6 +33,7 @@ import org.apache.brooklyn.api.effector.Effector;
 import org.apache.brooklyn.api.effector.ParameterType;
 import org.apache.brooklyn.api.entity.Entity;
 import org.apache.brooklyn.api.mgmt.Task;
+import org.apache.brooklyn.core.config.Sanitizer;
 import org.apache.brooklyn.core.effector.BasicParameterType;
 import org.apache.brooklyn.core.entity.EntityInternal;
 import org.apache.brooklyn.core.mgmt.BrooklynTaskTags;
@@ -310,7 +311,7 @@ public class EffectorUtils {
         String name = eff.getName();
 
         if (log.isDebugEnabled()) log.debug("Invoking-async effector {} on {}", new Object[]
{ name, entity });
-        if (log.isTraceEnabled()) log.trace("Invoking-async effector {} on {} with args {}",
new Object[] { name, entity, parameters });
+        if (log.isTraceEnabled()) log.trace("Invoking-async effector {} on {} with args {}",
new Object[] { name, entity, Sanitizer.sanitize(parameters) });
         EntityManagementSupport mgmtSupport = ((EntityInternal)entity).getManagementSupport();
         if (!mgmtSupport.isDeployed()) {
             mgmtSupport.attemptLegacyAutodeployment(name);
@@ -386,7 +387,7 @@ public class EffectorUtils {
         return MutableMap.builder()
                 .put("description", "Invoking effector "+effector.getName()
                     +" on "+entity.getDisplayName()
-                    +(parameters!=null ? " with parameters "+parameters.getAllConfig() :
""))
+                    +(parameters!=null ? " with parameters "+ Sanitizer.sanitize(parameters.getAllConfig())
: ""))
                 .put("displayName", effector.getName())
                 .put("tags", tags)
                 .build();


Mime
View raw message