camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Claus Ibsen <claus.ib...@gmail.com>
Subject Re: Using custom processor with JMX and JConsole
Date Fri, 05 Mar 2010 05:19:06 GMT
On Thu, Mar 4, 2010 at 9:31 PM, camel-fan <flying_black_sheep@yahoo.com> wrote:
>
> Thanks for the tip... but I had looked at the FAQ at the bottom and all it
> said was to implement Service, i.e. org.apache.camel.Service . I actually
> did this on my processor.
>
> Any other ideas? :)

Ah you did. You can enable DEBUG logging on
org.apache.camel.management and it should log which mbeans is being
registered.
Then check if there is something about your processor.

Also try using the latest release which is Camel 2.2.0.


>
>
> Claus Ibsen-2 wrote:
>>
>> Hi
>>
>> At the very bottom of the JMX wiki page is a section about processors
>> and a link to a FAQ :)
>>
>>
>> On Wed, Mar 3, 2010 at 9:27 PM, camel-fan <flying_black_sheep@yahoo.com>
>> wrote:
>>>
>>> Hi all,
>>>
>>> I am trying to enable a simple processor to be JMX enabled and visible in
>>> JConsole.
>>>
>>> I have read http://camel.apache.org/camel-jmx.html and defined my
>>> processor
>>> as follows (simplified it a bit):
>>>
>>> @ManagedResource(description = "Managed Processor" )
>>> public class MyProcessor implements Processor,
>>> ManagementAware<MyProcessor>,
>>> Service {
>>>
>>>    @ManagedAttribute
>>>    public String getFoo() {
>>>        return "bar";
>>>    }
>>>    @Override
>>>    public Object getManagedObject(MyProcessor arg0) {
>>>        return this;
>>>    }
>>>    @Override
>>>    public void process(Exchange exchange) throws Exception {}
>>>    @Override
>>>     public void start() throws Exception {}
>>>     @Override
>>>     public void stop() throws Exception {}
>>> }
>>>
>>> The problem is that I can't see my processor in JConsole, I can connect
>>> to
>>> camel context and see all the running
>>> components/endpoints/processors/services etc... but I don't see my own
>>> processor listed.
>>>
>>> The processor is registered as a bean in my spring xml config simply as:
>>> <bean id="myprocessor" class="MyProcessor"></bean>
>>>
>>> The processor is working in my routes.
>>>
>>> Am I missing something?
>>>
>>> I am using: JDK 1.6, Camel 2.1, Spring 2.5.6
>>>
>>> I really appreciate any help you can provide!
>>>
>>>
>>>
>>> --
>>> View this message in context:
>>> http://old.nabble.com/Using-custom-processor-with-JMX-and-JConsole-tp27772716p27772716.html
>>> Sent from the Camel - Users mailing list archive at Nabble.com.
>>>
>>>
>>
>>
>>
>> --
>> Claus Ibsen
>> Apache Camel Committer
>>
>> Author of Camel in Action: http://www.manning.com/ibsen/
>> Open Source Integration: http://fusesource.com
>> Blog: http://davsclaus.blogspot.com/
>> Twitter: http://twitter.com/davsclaus
>>
>>
>
> --
> View this message in context: http://old.nabble.com/Using-custom-processor-with-JMX-and-JConsole-tp27772716p27786155.html
> Sent from the Camel - Users mailing list archive at Nabble.com.
>
>



-- 
Claus Ibsen
Apache Camel Committer

Author of Camel in Action: http://www.manning.com/ibsen/
Open Source Integration: http://fusesource.com
Blog: http://davsclaus.blogspot.com/
Twitter: http://twitter.com/davsclaus

Mime
View raw message