The Artima Developer Community
Sponsored Link

Java Buzz Forum
Listing ActiveMQ queues with JMX and Groovy

0 replies on 1 page.

Welcome Guest
  Sign In

Go back to the topic listing  Back to Topic List Click to reply to this topic  Reply to this Topic Click to search messages in this forum  Search Forum Click for a threaded view of the topic  Threaded View   
Previous Topic   Next Topic
Flat View: This topic has 0 replies on 1 page
Andrej Koelewijn

Posts: 594
Nickname: andrejk
Registered: Nov, 2002

Andrej Koelewijn is a Java and Oracle consultant
Listing ActiveMQ queues with JMX and Groovy Posted: Mar 18, 2011 5:48 AM
Reply to this message Reply

This post originated from an RSS feed registered with Java Buzz by Andrej Koelewijn.
Original Post: Listing ActiveMQ queues with JMX and Groovy
Feed Title: Andrej Koelewijn
Feed URL: http://feeds.feedburner.com/AndrejKoelewijn
Feed Description: On Oracle, Java and OpenSource
Latest Java Buzz Posts
Latest Java Buzz Posts by Andrej Koelewijn
Latest Posts From Andrej Koelewijn

Advertisement
The following groovy script displays a list of queues in ActiveMQ with some statistics per queue. import javax.management.* import javax.management.remote.* import javax.lang.management.* def serverUrl = 'service:jmx:rmi:///jndi/rmi://localhost:1099/jmxrmi' def env = [(JMXConnector.CREDENTIALS): ["smx","smx"] as String[]] def jmxUrl = new JMXServiceURL(serverUrl) def connect = JMXConnectorFactory.connect(jmxUrl,env) def server = connect.MBeanServerConnection def query = new ObjectName('org.apache.activemq:Type=Queue,*') def queues = server.queryNames(query,null) [...]

Read: Listing ActiveMQ queues with JMX and Groovy

Topic: Architecture Rules 102 Previous Topic   Next Topic Topic: Spring: OpenSessionInViewInterceptor & OpenSessionInViewFilter Examples

Sponsored Links



Google
  Web Artima.com   

Copyright © 1996-2019 Artima, Inc. All Rights Reserved. - Privacy Policy - Terms of Use