You do not need to explicit call registerShutdownHook, from camel 2.17 is is on by default so you can make it shorten by using SpringApplication.run(YourMain.class, args). You can find a very simple example here: https://github.com/lburgazzoli/lb-camel/tree/master/camel-samples/camel-samples-spring-boot
About SpringApplicationBuilder.web(boolean) it is a SpringBoot specific option and usually you do not need to set it to run console application unless you have some web specific dependencies in your classpath that could trigger automatic spring support for web environments (i.e. if you have spring-boot-starter-web i your dependencies list) --- Luca Burgazzoli On Tue, Apr 19, 2016 at 4:09 PM, Hubertus.Willuhn <hubertus.will...@dinsoftware.de> wrote: > Hi, > > thanks for the fast response. Sorry was my fault since i missed that other > jira. > Didn't read the changelog that far :) > > The solution provided in CAMEL-9720 seems to work (just tested it).... > > But this definitely should be in the official documentation about Camel and > Spring Boot Applications! > > e.g. here > http://camel.apache.org/running-camel-standalone-and-have-it-keep-running.html > <http://camel.apache.org/running-camel-standalone-and-have-it-keep-running.html> > > P.S: Correct me if i am wrong but the correct solution implies that i have > to do this in my main(): > > new > SpringApplicationBuilder().sources(SampleCamelApplication.class).run(args).registerShutdownHook(); > > AND have to add this property to my config: > camel.springboot.main-run-controller = true? > > P.P.S: So if i am correct and you do not want to create a WebApplication > (since what i want was a "normal" console app) you have to set WebEnviroment > to false on the SpringApplicationBuilder() (by calling web(false)) !!! Thats > another important fakt... > > Best regards, > > Hubertus > > > > -- > View this message in context: > http://camel.465427.n5.nabble.com/Spring-Boot-and-Camel-2-17-HangupSupport-Removed-tp5781339p5781343.html > Sent from the Camel - Users mailing list archive at Nabble.com.