Re: testing routes when using spring boot

2017-03-20 Thread Minh Tran
Try enabling debug logging on org.springframework.boot and see whether it is skipping the CamelAutoConfiguration class and why. > On 21 Mar 2017, at 12:01 pm, 129073.d.0002 wrote: > > I have this dependency in my pom > > > org.apache.camel >

Re: testing routes when using spring boot

2017-03-20 Thread 129073.d.0002
I have this dependency in my pom org.apache.camel camel-spring-boot-starter 2.18.3 but when I tried to list all spring components, there is no CamelContext -component !? I use @SpringBootA

Re: testing routes when using spring boot

2017-03-20 Thread Minh Tran
Have you got the right camel version? From memory, this class is fairly new so that could explain the missing class problem. As to the missing CamelContext bean, sounds like it isn’t being created automatically and that could be because Spring Boot isn’t doing it’s magic with the CamelAutoConfi

Re: testing routes when using spring boot

2017-03-20 Thread 129073.d.0002
I have camel-test-spring in my pom but class not found. And I tried @Autowire CamelContext but component does not exist. So I keep on debugging my setup. Thanks for your answer, now I know that there is something else wrong with my project. -- View this message in context: http://camel.465427

Re: testing routes when using spring boot

2017-03-20 Thread Minh Tran
Hi You can find it in the camel-test-spring.jar. So add that dependency in your pom. The way to get the camel context would be just to inject it in just like any other spring bean. For example: @Autowired private CamelContext context; > On 21 Mar 2017, at 11:15 am, 129073.d.0002 wrote: > >

Re: Testing routes: Get route definition by id gets null

2012-06-25 Thread Omar Atia
Sent from my iPad On Jun 25, 2012, at 12:24 PM, "Claus Ibsen" wrote: > Hi > > In your route using Java DSL, you need to declare the id of the route > in the DSL using .routeId("foo") > > eg > > from("file:foo").routeId("foo") > .to("blah") > > Then you can refer to the route id "foo" in t

Re: Testing routes: Get route definition by id gets null

2012-06-25 Thread Claus Ibsen
On Mon, Jun 25, 2012 at 12:14 PM, Hilde wrote: > Hello Claus! > > You are right, thanks a lot! > > When I look into the Camel API I can see that the method > getRouteDefinition(String routeId) in class CamelContext is deprecated. Is > there already a new way existing to bypass that way? > No but

Re: Testing routes: Get route definition by id gets null

2012-06-25 Thread Hilde
Hello Claus! You are right, thanks a lot! When I look into the Camel API I can see that the method getRouteDefinition(String routeId) in class CamelContext is deprecated. Is there already a new way existing to bypass that way? Hilde -- View this message in context: http://camel.465427.n5.nab

Re: Testing routes: Get route definition by id gets null

2012-06-25 Thread Claus Ibsen
Hi In your route using Java DSL, you need to declare the id of the route in the DSL using .routeId("foo") eg from("file:foo").routeId("foo") .to("blah") Then you can refer to the route id "foo" in the advice with. On Mon, Jun 25, 2012 at 9:21 AM, Hilde wrote: > Hello folks! > > When I tes

Re: Testing Routes

2009-10-20 Thread Claus Ibsen
On Tue, Oct 20, 2009 at 9:23 PM, Carlos Cook wrote: > > Thanks. I know there are a number of tricks that I can add to my production > route to help with testing. When is this book due to release. I'm > interesting in reading this chapter 5. :) > Its going MEAP in short time. Keep an eye on the ma

Re: Testing Routes

2009-10-20 Thread Carlos Cook
Thanks. I know there are a number of tricks that I can add to my production route to help with testing. When is this book due to release. I'm interesting in reading this chapter 5. :) Claus Ibsen-2 wrote: > > On Tue, Oct 20, 2009 at 7:42 PM, Claus Ibsen > wrote: >> On Tue, Oct 20, 2009 at 5:5

Re: Testing Routes

2009-10-20 Thread Claus Ibsen
On Tue, Oct 20, 2009 at 7:42 PM, Claus Ibsen wrote: > On Tue, Oct 20, 2009 at 5:52 PM, Carlos Cook wrote: >> >> We have a complicated system setup to plan our routes. I want to write unit >> tests to test these routes. Is there a way to test the routes without having >> to re-write a bunch of cod

Re: Testing Routes

2009-10-20 Thread Claus Ibsen
On Tue, Oct 20, 2009 at 5:52 PM, Carlos Cook wrote: > > We have a complicated system setup to plan our routes. I want to write unit > tests to test these routes. Is there a way to test the routes without having > to re-write a bunch of code to tell my routes to go to mock endpoints? The > only exa