You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@activemq.apache.org by shaf <sh...@gmail.com> on 2008/06/25 21:52:11 UTC

AMQ5.1.0 - Programmatically getting a list of queues

Gents,

I am really having a hard time trying to get a list of queues
programmatically (Java). I have seen the DestinationSource (
connection.getDestinationSource() ) working on my local laptop but when
deployed onto the server environment, it returns a null for some reason and
I know there are queues available.

Based on this thread (as Joe stated) that the DestinationSource link is
broken, and I really need a way of browsing the queues, any suggestions
greatly appreciated!!!!

Is there a possibility of retrieving the destinations via the default
BrokerService (any code samples someone can share)? 

thanks,
-shaf.
 

-- 
View this message in context: http://www.nabble.com/AMQ5.1.0---Programmatically-getting-a-list-of-queues-tp18120436p18120436.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.


Re: AMQ5.1.0 - Programmatically getting a list of queues

Posted by Bruce Snyder <br...@gmail.com>.
On Wed, Jun 25, 2008 at 1:52 PM, shaf <sh...@gmail.com> wrote:
>
> Gents,
>
> I am really having a hard time trying to get a list of queues
> programmatically (Java). I have seen the DestinationSource (
> connection.getDestinationSource() ) working on my local laptop but when
> deployed onto the server environment, it returns a null for some reason and
> I know there are queues available.
>
> Based on this thread (as Joe stated) that the DestinationSource link is
> broken, and I really need a way of browsing the queues, any suggestions
> greatly appreciated!!!!
>
> Is there a possibility of retrieving the destinations via the default
> BrokerService (any code samples someone can share)?

You can get a list of queues via JMX queries. See the example Java
class I posted here:

http://markmail.org/search/?q=activemq%20AMQJmxExampleTest#query:activemq%20AMQJmxExampleTest+page:1+mid:us7q7dgdinp2sfo6+state:results

Bruce
-- 
perl -e 'print unpack("u30","D0G)U8V4\@4VYY9&5R\"F)R=6-E+G-N>61E<D\!G;6%I;\"YC;VT*"
);'

Apache ActiveMQ - http://activemq.org/
Apache Camel - http://activemq.org/camel/
Apache ServiceMix - http://servicemix.org/

Blog: http://bruceblog.org/