You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@activemq.apache.org by emc2family <em...@gmail.com> on 2008/12/10 05:24:32 UTC
how to get managementcontext from a broker
Hi,
i was looking for a way to determine the queue depth of a destination via an
mbeanserver object. the broker service class has a managementcontext method
that will allow me to get the mbeanserver object. however, it seems like
the broker service class is only meant for creating & configuring brokers.
is there a way for me to get the managementcontext from an existing broker?
thanks a bunch.
--
View this message in context: http://www.nabble.com/how-to-get-managementcontext-from-a-broker-tp20928934p20928934.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.
Re: how to get managementcontext from a broker
Posted by Dejan Bosanac <de...@ttmsolutions.com>.
Hi,
you should use MBeanServerInvocationHandler to get a proxy of a mbean.
Take a look at the BrokerFacadeSupport that does the similar job for the
web console
http://www.koders.com/java/fidE02AF845C99D1EE4A2A301BABEB98605E7E8F1FB.aspx
Cheers
emc2family wrote:
> Hi,
>
> i was looking for a way to determine the queue depth of a destination via an
> mbeanserver object. the broker service class has a managementcontext method
> that will allow me to get the mbeanserver object. however, it seems like
> the broker service class is only meant for creating & configuring brokers.
> is there a way for me to get the managementcontext from an existing broker?
> thanks a bunch.
>
--
Dejan Bosanac
http://www.ttmsolutions.com - get a free ActiveMQ user guide
ActiveMQ in Action - http://www.manning.com/snyder/
Scripting in Java - http://www.scriptinginjava.net