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?

有帮助吗?

解决方案

Open the session settings and go to the "Filter settings" tab. Delete all default exclusive filters and add the top-level packages of your project as inclusive filters. Also add org.apache.camel.model. as an inclusive filter.

许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top