You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomee.apache.org by exabrial12 <ex...@gmail.com> on 2018/09/24 02:17:25 UTC

Proper way to add JMX bean to monitor a server resource?

TomEE Devs: I want to work on a patch that can monitor the thread pool sizes
ManagedExecutorService and ManagedScheduledExecutorService that a user might
create in their tomee.xml. There's a couple of different methods in the
code, I was curious if someone could point me to the "best" or "current" way
with an example? Any other advice? Thanks,

-Jonathan



--
Sent from: http://tomee-openejb.979440.n4.nabble.com/TomEE-Dev-f982480.html

Re: Proper way to add JMX bean to monitor a server resource?

Posted by Romain Manni-Bucau <rm...@gmail.com>.
Hi Jonathan,

What is important is to use LocalMBeanServer to allow to disable that. Then
using a dynamicmbean - through our wrapper if you prefer the api - is nice
because you can put description easily versus a standard mbean where it is
less natural. For the name building, using the objectnamebuilder is nice
and ensure to put j2eetype in the attribute to let tools sort it properly.

Le lun. 24 sept. 2018 04:17, exabrial12 <ex...@gmail.com> a écrit :

> TomEE Devs: I want to work on a patch that can monitor the thread pool
> sizes
> ManagedExecutorService and ManagedScheduledExecutorService that a user
> might
> create in their tomee.xml. There's a couple of different methods in the
> code, I was curious if someone could point me to the "best" or "current"
> way
> with an example? Any other advice? Thanks,
>
> -Jonathan
>
>
>
> --
> Sent from:
> http://tomee-openejb.979440.n4.nabble.com/TomEE-Dev-f982480.html
>