I’m currently working with Apache Camel and hawt.io for monitoring and debugging my Camel routes. This works wonderfully, even if some important information is somewhat hidden in the documentation. For example, it took me a bit to turn on debugging.
However, if I set a breakpoint where the message processing stops at that point in the route, I can’t see any “body” or “headers” of my Camel exchange at that point. I’ve tried all sorts of settings:
Here is some information:
Apache Camel: 3.22.1
Spring boot: 2.7.18
Jolokai Core: 1.7.2
hawt.io: 2.16.0
Camel DSL: XML
Here are the properties of my spring boot application.properties:
management.endpoints.web.exposure.include=hawtio,jolokia management.endpoints.web.base-path=/ camel.springboot.backlog-tracing=true spring.jmx.enabled=true
We are not using camelContext in our route files. Instead we are defining routes in RouteTemplate and configuring/invoking those routes via route-builder.xml file.
we tried with , but it is not working.
Content of route file:
<routeTemplates xmlns="http://camel.apache.org/schema/spring">
<routeTemplate id="myTemplate">
<templateParameter name="name"/>
<templateParameter name="greeting"/>
<templateParameter name="myPeriod" defaultValue="3s"/>
<route>
<from uri="timer:{{name}}?period={{myPeriod}}"/>
<setBody><simple>{{greeting}} ${body}</simple></setBody>
<log message="${body}"/>
</route>
</routeTemplate>
</routeTemplates>
Content of route-builde.xml:
<?xml version="1.0" encoding="UTF-8"?>
<templatedRoutes id="myTemplateRoute"
backlogTrace="true" debug="true" trace="true">
<templatedRoute routeId="myTemplate"
routeTemplateRef="myRouteTemplatee">templatedRoute
</templatedRoute>
</templatedRoutes>
Could you please provide workaround for this route files to enable debugging.
user24592580 is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.