-
1. Re: Getting attribute change notifications
dimitris Feb 8, 2005 9:26 AM (in response to yaronz)Please, provide a better description (at a higher level) of what you are trying to do... :)
-
2. Re: Getting attribute change notifications
yaronz Feb 8, 2005 11:42 AM (in response to yaronz)Dimitris,
What I'm trying to do should be pretty straigt forward:
I'm trying to get notification for attribute changes for an existing MBean. The idea is to be able to react to changes in MBean attribute values without having to use pooling.
An example would be:
The MBean - BasicThreadPoolMBean
The attribute - MaximumPoolSize
I would like to know if someone changes the maximum pool size, in order to report that to my monitoring tool as a significant event.
Yaron. -
3. Re: Getting attribute change notifications
dimitris Feb 8, 2005 3:32 PM (in response to yaronz)The easiest way to do it, is write an MBean that extends ListenerServiceMBeanSupport:
http://www.jboss.org/wiki/Wiki.jsp?page=ListenerServiceMBeanSupport
And configure it's subscription list to receive the notifications you are interested in:
http://www.jboss.org/wiki/Wiki.jsp?page=SubscriptionList -
4. Re: Getting attribute change notifications
yaronz Feb 9, 2005 6:33 AM (in response to yaronz)Dimitris,
Thanks, from what I read this is the answer. I will give it a try and report if there are any problems.
Yaron.