New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Hawtio unable to detect Camel routes when added via a JAR. #3391
Comments
Hi @HARSHITHARSH, thanks for the reporting. I tested the same setup at my end, but couldn't reproduce the issue. Hawtio works just fine with 2 app routes & 1 route from an external jar. I used the following route in a jar: package com.example.hello;
import org.apache.camel.builder.RouteBuilder;
import org.springframework.stereotype.Component;
@Component
public class Hello extends RouteBuilder {
@Override
public void configure() throws Exception {
// Write your routes here, for example:
from("timer:java?period={{time:1000}}")
.setBody()
.simple("Hello Camel from ${routeId}")
.log("${body}");
}
} then using the example project springboot imported the above project @SpringBootApplication(scanBasePackages = {"io.hawt.example.spring.boot", "com.example"})
public class SampleSpringBootService { So, maybe it's related to the way you build the jar and import it into the main app. Can you provide us with a reproducer? |
Can we try with spring dsl routes in both application and jar. |
@HARSHITHARSH What does "spring dsl routes" mean? Does it mean Spring XML DSL routes? |
Yes sir. |
@HARSHITHARSH Tried Spring XML DSL but nothing has changed. It works. I suspect it's related to the way you've made the JAR. Can you show us the output of the following command?
|
I am integrating hawtio with our spring boot app (3.2.2) with Camel 4.4.0, and we are importing a JAR in the app that also has camel routes in it, although all the routes are starting properly, in hawtio console I see a blank screen.
Removing the JAR the hawtio screen shows the routes.
To sum up:
For Example
The text was updated successfully, but these errors were encountered: