activemq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From tab...@apache.org
Subject svn commit: r1133564 - /activemq/trunk/activemq-core/src/main/java/org/apache/activemq/broker/jmx/ManagedRegionBroker.java
Date Wed, 08 Jun 2011 21:37:18 GMT
Author: tabish
Date: Wed Jun  8 21:37:18 2011
New Revision: 1133564

URL: http://svn.apache.org/viewvc?rev=1133564&view=rev
Log:
https://issues.apache.org/jira/browse/AMQ-3337

Create a better ObjectName for dynamic destination producers.

Modified:
    activemq/trunk/activemq-core/src/main/java/org/apache/activemq/broker/jmx/ManagedRegionBroker.java

Modified: activemq/trunk/activemq-core/src/main/java/org/apache/activemq/broker/jmx/ManagedRegionBroker.java
URL: http://svn.apache.org/viewvc/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/broker/jmx/ManagedRegionBroker.java?rev=1133564&r1=1133563&r2=1133564&view=diff
==============================================================================
--- activemq/trunk/activemq-core/src/main/java/org/apache/activemq/broker/jmx/ManagedRegionBroker.java
(original)
+++ activemq/trunk/activemq-core/src/main/java/org/apache/activemq/broker/jmx/ManagedRegionBroker.java
Wed Jun  8 21:37:18 2011
@@ -707,8 +707,8 @@ public class ManagedRegionBroker extends
         String destinationName = "destinationName=";
 
         if (producerInfo.getDestination() == null) {
-            destinationType += "NOTSET";
-            destinationName += "NOTSET";
+            destinationType += "dynamic";
+            destinationName = null;
         } else {
             destinationType += producerInfo.getDestination().getDestinationTypeAsString();
             destinationName += JMXSupport.encodeObjectNamePart(producerInfo.getDestination().getPhysicalName());
@@ -719,7 +719,8 @@ public class ManagedRegionBroker extends
 
         ObjectName objectName = new ObjectName(brokerObjectName.getDomain() + ":" + "BrokerName="
+ map.get("BrokerName") + ","
                                                + "Type=Producer" + ","
-                                               + destinationType + "," + destinationName
+ ","
+                                               + destinationType + ","
+                                               + (destinationName != null ? destinationName
+ "," : "")
                                                + clientId + "," + producerId);
         return objectName;
     }



Mime
View raw message