File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

mbeans-descriptor.xml and custom MBean

 
Christophe Hvd
Greenhorn
Posts: 2
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi all,
I followed the Tomcat 6 documentation about custom MBean. It says
You may also add MBean descriptions for custom components in a mbeans-descriptor.xml file, located in the same package as the class files it describes.
.
Problem : I do exactly what is recommended and my custom Mbean descriptions are still not mine. Tomcat generates default values for the description fileds, etc.
then i followed this good tutorial about the Tomcat config for custom MBean : http://oss.wxnet.org/mbeans.html
Not working too..

Is there anybody who has already performed this "miracle"??

Regards,
Chris
 
Tim Holloway
Saloon Keeper
Pie
Posts: 17616
39
Android Eclipse IDE Linux
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Welcome to the JavaRanch, Christophe!

I did this, but it was about 5 years ago, so I've pretty much forgotten what I did. I was able to do it using just the tomcat.apache.org documentation set, though and while it was tricky - you have to get everything JUST right - it was doable.

The docs you quoted are based on Tomcat 5.0. Tomcat 5.5 and Tomcat6 both introduced major changes in Tomcat's architecture. Plus, Java's JMX toolset has been improved since Java 5 was the standard.

So I recommend checking the Tomcat 6 docs and see what they say. You may discover that the whole process has been made simpler and more straightforward since Tomcat 5.0, if you're lucky. The bane of the Internet is that old, outdated docs tend to often show up at the top of the search results list. It's a reason why I wish more people would put dates on that kind of thing. The JSF stuff can be really bad that way, since JSF was pretty raw originally.
 
Christophe Hvd
Greenhorn
Posts: 2
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Tim,
thank you for your answer.
As i said, I studied both the Tomcat 5 & 6 documentation. Nothing is really explained about mbeans. Just a short sentence which says to put the mbeans-descriptors.xml in the same .jar as the mbean it describes.

But it doesn't work at all. I've tried many configuration and I search in many Tomcat's documentation page but I found nothing.

So my question still stand..
 
Shantanu Puranik
Ranch Hand
Posts: 67
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I'm facing the same situation.
If anybody has running example or other resource for tomcat 6.x, please share.
 
Shantanu Puranik
Ranch Hand
Posts: 67
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Finally, got some resource that works.
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic