activemq-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jiang <zju_...@163.com>
Subject Re: How to create BrokerView object
Date Wed, 16 May 2007 02:11:11 GMT

Chirino:
    Could you give some codes about how to create BrokerView object or how
to create destinations on ActiveMQ remotely.(Use the invoke  method I can
create topic seen from jconsole. But I can't get topic use JNDI.lookup
method, Could you also give some advice on this topic ???)
Thanks a lot.


Hiram Chirino wrote:
> 
> That's not how JMX is used.  You have to continue to use the
> MBeanServerConnection.
> try using the invoke operation to call the methods on the interface:
> 
> see:
> http://java.sun.com/j2ee/1.4/docs/api/javax/management/MBeanServerConnection.html#invoke(javax.management.ObjectName,%20java.lang.String,%20java.lang.Object[],%20java.lang.String[])
> 
> 
> On 5/10/07, Jiang <zju_jjc@163.com> wrote:
>>
>> I start ActiveMQ on 10.4.1.64 (expose jmxrmi at 1099) . I want to add
>> queue/topic  to the server from my pc (10.4.1.60) .  Code is below :
>> jmxUrl = new
>> JMXServiceURL("service:jmx:rmi:///jndi/rmi://10.4.1.64:1099/jmxrmi");
>> JMXConnector jmxc = JMXConnectorFactory.connect(jmxUrl);
>> MBeanServerConnection mbsc = jmxc.getMBeanServerConnection();
>> ObjectName mBeanName = new
>> ObjectName("org.apache.activemq:BrokerName=localhost,Type=Broker");
>> MBeanInfo mBeanInfo = mbsc.getMBeanInfo(mBeanName);
>>
>> the mBeanInfo is get successfully. And in debug console , I can see the
>> className of mBeanInfo is BrokerView.
>> How can I create one BrokerView object that presents the object just run
>> in
>> the ActiveMQ  Server. Then I can use
>> addQueue or addTopic of the BrokerView object to add queue/topic to the
>> ActiveMQ server remotely.???
>> Thanks .
>> --
>> View this message in context:
>> http://www.nabble.com/How-to-create-BrokerView-object-tf3721428s2354.html#a10412673
>> Sent from the ActiveMQ - Dev mailing list archive at Nabble.com.
>>
>>
> 
> 
> -- 
> Regards,
> Hiram
> 
> Blog: http://hiramchirino.com
> 
> 

-- 
View this message in context: http://www.nabble.com/How-to-create-BrokerView-object-tf3721428s2354.html#a10634518
Sent from the ActiveMQ - Dev mailing list archive at Nabble.com.


Mime
View raw message