activemq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From clebertsuco...@apache.org
Subject [1/5] activemq-artemis git commit: ManagementContext.queryNames returns ObjectNames
Date Fri, 29 Jul 2016 19:43:24 GMT
Repository: activemq-artemis
Updated Branches:
  refs/heads/master 0ec8e5790 -> 9073e4cd7


ManagementContext.queryNames returns ObjectNames


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

Branch: refs/heads/master
Commit: 29deb12ddb6a8793a8a18640ce753a4504471f99
Parents: adef9e4
Author: Ville Skyttä <ville.skytta@iki.fi>
Authored: Fri Jul 29 11:48:43 2016 +0300
Committer: Clebert Suconic <clebertsuconic@apache.org>
Committed: Fri Jul 29 15:38:08 2016 -0400

----------------------------------------------------------------------
 .../org/apache/activemq/network/DuplexNetworkMBeanTest.java  | 8 +++-----
 .../usecases/DurableSubscriberWithNetworkRestartTest.java    | 7 +++----
 .../activemq/artemis/jms/tests/NonDurableSubscriberTest.java | 1 -
 3 files changed, 6 insertions(+), 10 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/29deb12d/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/network/DuplexNetworkMBeanTest.java
----------------------------------------------------------------------
diff --git a/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/network/DuplexNetworkMBeanTest.java
b/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/network/DuplexNetworkMBeanTest.java
index cba6ff9..526f0e5 100644
--- a/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/network/DuplexNetworkMBeanTest.java
+++ b/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/network/DuplexNetworkMBeanTest.java
@@ -22,7 +22,6 @@ import static org.junit.Assume.assumeNotNull;
 import java.net.MalformedURLException;
 import java.util.Set;
 
-import javax.management.ObjectInstance;
 import javax.management.ObjectName;
 
 import org.apache.activemq.broker.BrokerService;
@@ -162,11 +161,10 @@ public class DuplexNetworkMBeanTest {
    private void logAllMbeans(BrokerService broker) throws MalformedURLException {
       try {
          // trace all existing MBeans
-         Set<?> all = broker.getManagementContext().queryNames(null, null);
+         Set<ObjectName> all = broker.getManagementContext().queryNames(null, null);
          LOG.info("Total MBean count=" + all.size());
-         for (Object o : all) {
-            ObjectInstance bean = (ObjectInstance) o;
-            LOG.info(bean.getObjectName().toString());
+         for (ObjectName on : all) {
+            LOG.info(on.toString());
          }
       }
       catch (Exception ignored) {

http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/29deb12d/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/usecases/DurableSubscriberWithNetworkRestartTest.java
----------------------------------------------------------------------
diff --git a/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/usecases/DurableSubscriberWithNetworkRestartTest.java
b/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/usecases/DurableSubscriberWithNetworkRestartTest.java
index 5d86328..20cc57a 100644
--- a/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/usecases/DurableSubscriberWithNetworkRestartTest.java
+++ b/tests/activemq5-unit-tests/src/test/java/org/apache/activemq/usecases/DurableSubscriberWithNetworkRestartTest.java
@@ -161,11 +161,10 @@ public class DurableSubscriberWithNetworkRestartTest extends JmsMultipleBrokersT
    private void logAllMbeans(BrokerService broker) throws MalformedURLException {
       try {
          // trace all existing MBeans
-         Set<?> all = broker.getManagementContext().queryNames(null, null);
+         Set<ObjectName> all = broker.getManagementContext().queryNames(null, null);
          LOG.info("Total MBean count=" + all.size());
-         for (Object o : all) {
-            //ObjectInstance bean = (ObjectInstance)o;
-            LOG.info(o);
+         for (ObjectName on : all) {
+            LOG.info(on);
          }
       }
       catch (Exception ignored) {

http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/29deb12d/tests/jms-tests/src/test/java/org/apache/activemq/artemis/jms/tests/NonDurableSubscriberTest.java
----------------------------------------------------------------------
diff --git a/tests/jms-tests/src/test/java/org/apache/activemq/artemis/jms/tests/NonDurableSubscriberTest.java
b/tests/jms-tests/src/test/java/org/apache/activemq/artemis/jms/tests/NonDurableSubscriberTest.java
index 62d35d2..b3595fd 100644
--- a/tests/jms-tests/src/test/java/org/apache/activemq/artemis/jms/tests/NonDurableSubscriberTest.java
+++ b/tests/jms-tests/src/test/java/org/apache/activemq/artemis/jms/tests/NonDurableSubscriberTest.java
@@ -20,7 +20,6 @@ import javax.jms.InvalidSelectorException;
 import javax.jms.Session;
 import javax.jms.TopicConnection;
 import javax.jms.TopicSession;
-import javax.naming.InitialContext;
 
 import org.apache.activemq.artemis.jms.tests.util.ProxyAssertSupport;
 import org.junit.Test;


Mime
View raw message