camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Steven Marcus <>
Subject Re: Camel-boot autowiring issue
Date Wed, 07 Jan 2015 07:21:31 GMT

Thanks for the sample project. I adapted it to experiment with
@EndpointInject and @Produces -- they appear to be broken with spring-boot?

The shouldInjectCamelContext() test fails with null for resultEndpoint --
and template is null too.
(Using recently updated camel-spring-boot SNAPSHOT.)

@SpringApplicationConfiguration(classes = {CamelConfigurationTest.class,
public class CamelConfigurationTest extends Assert {

    CamelContext camelContext;

    String name;
    private CamelConfigurationProperties configurationProperties;
    private Environment env;

    @EndpointInject(uri = "mock:result")
    private MockEndpoint resultEndpoint;

    @Produce(uri = "direct:RoomSyncRouteTest")
    private ProducerTemplate template;

    public void shouldInjectCamelContext() {
        assertNotNull("camelContext", camelContext);
        assertNotNull("configurationProperties", configurationProperties);
        assertNotNull("env", env);
        assertNotNull("name", name);
        assertNotNull("resultEndpoint", resultEndpoint);
        assertNotNull("template", template);

    public void shouldLoadRoute() {
        assertEquals(1, camelContext.getRoutes().size());

Camel + spring boot looks like a great combo...


View this message in context:
Sent from the Camel - Users mailing list archive at

View raw message