For info
Clement and I plan to commit a JMX handler for iPOJO in the sandbox !
The handler eases the MBean development !
Another alternative is using Spoon JMX
http://spoon.gforge.inria.fr/SpoonJMX/Main
However it relies on the Java 5.0 annotations !
santillan wrote:
Yep,
Adding mbeans is fairly easy. I am not very much aware of UPnP -yet :-)- but
I understand that you do not know a priori which is the interface. If so,
the simplest approach is to use the StandardMBean class:
Class interface=//get your management interface class
StandardMBean myMBean=new StandardMBean(impl, interface);
ObjectName oname=ObjectName.getInstance("<This string should contain a valid
objectname, in the form 'domain:key1=value1[, key2=value2...]'>");
ManagementFactory.getPlatformMBeanServer.registerMBean(myBean, objectName);
Moreover, MOSGi uses the whiteboard pattern to register/unregister MBeans
You have just to register a OSGi service implementing a *MBean interface
with a registration property "jmx.objectname" containing the objectName
value.
So you don't have to deal with ServiceListeners
Stephane, can you confirm ?
Didier
And when exiting,
ManagementFactory.getPlatformMBeanServer.unRegisterMBean(objectName);
--
Manuel Santillán <[EMAIL PROTECTED]>
http://www.dit.upm.es/santillan
Departamento de Ingeniería de Sistemas Telemáticos
Escuela Técnica Superior de Ingenieros de Telecomunicación
Universidad Politécnica de Madrid
Avda. Complutense, s/n
28040 Madrid SPAIN
Tel. +34 913367366 ext.3034
-----Mensaje original-----
De: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
Enviado el: viernes, 15 de septiembre de 2006 10:12
Para: [email protected]
Asunto: Re: JMX and UPnP
Yes that's it.
You can have two implementing ways :
- UPnPdev <-> MBean <-> JMXConsole
In this case each UPnP device declares an MBean which represent
himself. So the JMXConsole can be considered as a controlPoint
- UPnPdev <-> ControlPoint <-> MBean <-> JMXconsole
In this case the control point declares a MBean that enable the
JMXConsole to manage it.
I have done the second one in a simple example.
/stephane
On Fri, Sep 15, 2006 at 09:40:15AM +0200, Francesco Furfari wrote:
The question I don't understand is if you want to do some UPnP control
point out of JMX ?
/stephane
I'm not sure to understand your question. Are you asking if I want to
create a new GUI (Tab) for your console acting as a Generic Control
Point, that is similar to GUI of the bundle we have developed for
testing UPnP?
or the question is about bridging two local UPnP networks ?
francesco
--
--------------------------------------------------------------
Didier DONSEZ
INRIA/SARDES project, B117
655, avenue de l'Europe, Montbonnot
38334 St Ismier Cedex, France
Tel : +33 4 76 61 52 59 Fax : +33 4 76 61 52 52
GPS : lat 45°13'4.1"N, lon 05°48'24.3"E, alt 220m
Laboratoire LSR, Institut IMAG, Equipe ADELE
Universite Joseph Fourier
Bat. C, 220 rue de la Chimie, Domaine Universitaire
BP 53, 38041 Grenoble Cedex 9, France
Tel : +33 4 76 63 55 49 Fax : +33 4 76 63 55 50
GPS : lat 45°11'38.3"N, lon 05°46'14.7"E, alt 223m
mailto:[EMAIL PROTECTED]
URL: http://www-adele.imag.fr/users/Didier.Donsez
Map: http://www-adele.imag.fr/users/Didier.Donsez/map/map.html
--------------------------------------------------------------