MBeans and MBeanServer in different JVM

Hi,Is it possible that MBeans reside in different JVM and MBeanServer reside on different JVM? If so, then how to get instance of MBean into MBeanServer, as it is needed to register that MBean into server.or how its to be done.Thanks in advance.Please Help.
[285 byte] By [JahnviVyasa] at [2007-11-26 14:41:24]
# 1

Hi,

In addition to above stated problem, I have more information to give. The actual scenario is as follows:

I have more than one servers on one layer. They have their respective MBeans. On next layer I want to put MBeanServer which will be my agent layer. On 3rd layer I want to put management cosole from where I will monitoring or managing gathered info. It may be web browser or stand alone UI (right now this doesnt have much significance.)

As MBeans will be in different JVM and MBeanServer in different JVM, can it be possible to get instance of MBeans into MBeanServer? I was thinking of doing it by RMI and stubs. But I dont know how to do it. Or is there any other method available?

Please, your suggestions will be very much helpful to me.

Thank You..

JahnviVyasa at 2007-7-8 8:22:48 > top of Java-index,Core,Monitoring & Management...
# 2

Hi Jahnvi,

As I have already answered in this thread a few weeks ago:

http://forum.java.sun.com/thread.jspa?threadID=790563&messageID=4508174#4508174

what you describe is a use case for MBeanServer federation - aka Cascading.

You can set up a master agent/sub agent hierarchy where:

Each "subagent" JVMs has local MBeans registered in its MBeanServer, and starts

a JMXConnectorServer.

The "master" JVM (the JVM that the end client sees) uses JMXConnectors to talk to

access the MBeans registered in the subagents, and creates proxies for these MBeans

in its local MBeanServer.

The console then simply needs to connect to the "master" JVM, where it can see

all proxied MBeans.

The Java DMK has an API that allows you to set-up and control such a hiearchy.

A standard feature for federating MBeanServer is also in discussion for JDK 7.

See more info on my previous post here:

http://forum.java.sun.com/thread.jspa?threadID=790563&messageID=4508174#4508174

Hope this helps,

-- daniel

JMX, SNMP, Java, etc...

http://blogs.sun.com/jmxetc

dfuchsa at 2007-7-8 8:22:48 > top of Java-index,Core,Monitoring & Management...
# 3
Once again Thanks Daniel.Your suggestions were really very helpful.Even we also searched for it alot and found out some open source's API which provides the facility for master and sub-agent architecuture as you suggested.
JahnviVyasa at 2007-7-8 8:22:48 > top of Java-index,Core,Monitoring & Management...