Am 18.10.2011 09:35, schrieb Claus Ibsen:
On Tue, Oct 18, 2011 at 9:08 AM, Christian Schneider
<ch...@die-schneider.net>  wrote:
It would be great to be able to use both but I think that will not work.
The MBeanAssembler only reads the annotations if the object is not already
an MBean or MXBean. So
if there is an interface then the annotations do not work anymore.

The MBean assembler can detect if there is annotations and leverage
those. If not it can fallback and use the interface.
So its of course possible to have both.
I tested it. At least right now it does not work.

Sio we have to decide for one way to do this. Of course the annoations have
some advantages like a little less code and they allow to have documentation
for the attributes and operations but I think the advantage is small. So I
would rather simply create MXBean interfaces for all our MBeans and remove
all the JMX annotation support code from camel.

-1

End users of Camel can easily add custom operations / attributes of
their components to Camel by using the annotations.
This has been the way people have been doing this since Camel 1.x was
created (using Spring Annotations).
Still we can think about changing that for 3.0. I am not saying we must change it.

Christian

--
Christian Schneider
http://www.liquid-reality.de

Open Source Architect
Talend Application Integration Division http://www.talend.com

Reply via email to