I'm using Apache Camel in my project. The routes definition looks like this:
class RouteBuilder() {
public void configure() {
// populate the message queue with some messages
from("direct:input").
choice().
when(body().isEqual("A")).
beanRef('aProcessorBean').
otherwise().
beanRef('bProcessorBean').
end().
to("direct:output");
}
};
This is very primitive example, which use only FromDefinition
, ChoiceDefinition
, ProcessorDefinition
from org.apache.camel.model package.
In real world route could be more complicated. I would like to know how I can measure time spent in each route. Basically I think I need to monitor all XXXDefinition
classes from
org.apache.camel.model package. How to setup JProfiler to do so?