I want to expose certain atributes of a Message Driven Bean as a Standard MBean so in the constructor of the MDB i put this code:

List listaServidores = MBeanServerFactory.findMBeanServer(null);
MBeanServer servidor = (MBeanServer)listaServidores.iterator().next();
try {
        ObjectName name = new ObjectName("test:nombre=IntegracionMDB");
        servidor.registerMBean(this,name);
} catch (Exception e){
        e.printStackTrace();
}

Obviously the MDB class implements a MBean interface, showing only one method getInfo() which prints some info on the console.
The problem is that when jboss instantiates the MDB it gives me "javax.management.NotCompliantException: class does not expose a management interface" seems that i can't register a MBean on the server from the mbean itself? �What do you think?


greets

Alberto Rodriguez Galdo  ([EMAIL PROTECTED])
Centro de Innovaci�n y Servicios de Galicia (CIS Galicia)
Dpto. de Telem�tica
Telf.-981102100,  ext.1018



-------------------------------------------------------
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
_______________________________________________
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user

Reply via email to