tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Steve Cohen <sco...@javactivity.org>
Subject Re: Need help with Tomcat MBean support
Date Fri, 05 Sep 2008 12:56:16 GMT
Thanks again.  These articles are very clear and simple.

They do raise a couple questions, though. 

In the first article, no mention is made of an mbeans-descriptor.xml 
file.  It's all done programatically in the first article - which might 
be fine for my needs.  The Tomcat documentation does make it sound as 
though you can drop the xml file into your MBean package directory and 
something provided by Tomcat picks it up and makes the MBean accessible, 
but it now seems that this is not the case. 

The second article shows code to read these XML files (   
CommonsModelMBeanDemonstrator.applyCommonsModeler() ) which leads me to 
ask whether Tomcat comes with commons-modeler support built-in or 
whether this must be added manually as in this sample.

Anyway, it appears that there are two approaches here
1 - do everything programatically, in which case the .xml file isn't needed
2 - use the commons-modeler xml-file approach (question remains what 
support, if any, Tomcat provides for this). 

Do I have this right?



H. Hall wrote:
> Steve Cohen wrote:
>> Let me ask my question a little more directly:
>>
>> Does the presence of a descriptor cause instantiation of an instance 
>> of an MBean
>> or do I have to write code to create a server-side instance of my 
>> MBean and if so, where should this code reside
>> or is there some configuration artifact that causes this 
>> instantiation to happen?
>>
>>
>
> Why don't you take a look at these two articles:
> http://today.java.net/pub/a/today/2005/11/15/using-jmx-to-manage-web-applications.html?page=1

>
>
> http://marxsoftware.blogspot.com/2008/07/jmx-model-mbeans-with-apache-commons.html 
>
>
> If you use the NetBeans IDE you might be interested in the JMX plugin 
> for NB. Here is a link to a tutorial "Getting Started with JMX 
> Monitoring in NetBeans IDE 6.0"
>
> http://www.netbeans.org/kb/60/java/jmx-getstart.html
>
> cheers,
> HH
>
>


---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Mime
View raw message