2 Replies Latest reply on Aug 15, 2017 3:31 AM by Isuru dewundara

    How to programmatically get message count of a Topic on messaging-activemq

    Isuru dewundara Newbie

      I'm in a process of upgrading Jboss for 4.2.3 GA to wildfly 10

      in 4.2.3 GA i were able get the message count using a TopicMBean. is there a specific MBean in wildfly 10 that will give me the message count and what will be the format of the Object name for topic

       

      my previous code as follow

       

      String objName= "jboss.messaging.destination:service=Topic,name=Student"

      TopicMBean newMBeanProxy = MBeanServerInvocationHandler.newProxyInstance(Connection.getInstance().connect(), new ObjectName(

                objName), TopicMBean.class, false);

      newMBeanProxy .getAllMessageCount();