cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dk...@apache.org
Subject [1/6] cxf git commit: Allow Boolean objects as properties for the instrumentation manager properties
Date Wed, 15 Apr 2015 18:23:19 GMT
Repository: cxf
Updated Branches:
  refs/heads/2.7.x-fixes 59721a543 -> 41967da2f


Allow Boolean objects as properties for the instrumentation manager properties


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

Branch: refs/heads/2.7.x-fixes
Commit: 2c701fc3d457275127c9e9b78e530248411b9318
Parents: 59721a5
Author: Daniel Kulp <dkulp@apache.org>
Authored: Tue Apr 7 15:02:01 2015 -0400
Committer: Daniel Kulp <dkulp@apache.org>
Committed: Wed Apr 15 14:15:21 2015 -0400

----------------------------------------------------------------------
 .../apache/cxf/management/jmx/InstrumentationManagerImpl.java | 7 +++++--
 1 file changed, 5 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cxf/blob/2c701fc3/rt/management/src/main/java/org/apache/cxf/management/jmx/InstrumentationManagerImpl.java
----------------------------------------------------------------------
diff --git a/rt/management/src/main/java/org/apache/cxf/management/jmx/InstrumentationManagerImpl.java
b/rt/management/src/main/java/org/apache/cxf/management/jmx/InstrumentationManagerImpl.java
index 42d7d15..1777a01 100644
--- a/rt/management/src/main/java/org/apache/cxf/management/jmx/InstrumentationManagerImpl.java
+++ b/rt/management/src/main/java/org/apache/cxf/management/jmx/InstrumentationManagerImpl.java
@@ -409,8 +409,11 @@ public class InstrumentationManagerImpl extends JMXConnectorPolicyType
     }
 
     private static boolean getBusProperty(Bus b, String key, boolean dflt) {
-        String v = (String)b.getProperty(key);
-        return v != null ? Boolean.valueOf(v) : dflt;
+        Object v = b.getProperty(key);
+        if (v instanceof Boolean) {
+            return (Boolean)v;
+        }
+        return v != null ? Boolean.valueOf(v.toString()) : dflt;       
     }
 }
 


Mime
View raw message