1
votes

I have a application running Spring Boot Camel which consume message from a ActiveMQ and write to a file:

@Override
  public void configure() throws Exception {
    from("activemq:queue:MyQueue").to("file:/tmp/somemessages/");
  }

Very simple and works fine if run mvn spring-boot:run.

But now i need generate a bundle jar to install in my RedHat Fuse OSGi container. Everything was installed and started without error, see:

enter image description here So, my camel-app is Active but after produce some messages in my ActiveMQ Queue nothing works as i expect, so the file was not generated.

How can i see if something is wrong ? Application Console Log or something like this ?

2

2 Answers

2
votes

This is not a good practice. Spring Boot is intended for running Standalone. In an OSGi based runtime such as Red Hat Fuse or Apache Karaf/ServiceMix you should deploy OSGi apps, which with Camel is camel-blueprint (you can also use Java routes with blueprint). So take a look at examples how to do that, and there should be examples shipped with Red Hat Fuse you can look at.

1
votes

How can i see if something is wrong ? Application Console Log or something like this ?

The simple answer is you can run diagnostic command on your bundle by running following command inside your shell console:

bundle:diag {your-bundle-id}

You may replace {your-bundle-id} by preferred bundle id that is 231 in the picture. There is also a complete list of Apache Karaf commands that may be useful for further requirements.