You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@camel.apache.org by "Claus Ibsen (JIRA)" <ji...@apache.org> on 2016/04/09 10:38:25 UTC

[jira] [Commented] (CAMEL-9650) equivalent in Spring JavaConfig

    [ https://issues.apache.org/jira/browse/CAMEL-9650?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15233442#comment-15233442 ] 

Claus Ibsen commented on CAMEL-9650:
------------------------------------

You can add @ComponentScan to your configuration class and spring will do its scanning. And then add @Component on your route builder classes.

> <contextScan/> equivalent in Spring JavaConfig
> ----------------------------------------------
>
>                 Key: CAMEL-9650
>                 URL: https://issues.apache.org/jira/browse/CAMEL-9650
>             Project: Camel
>          Issue Type: New Feature
>          Components: camel-spring
>    Affects Versions: 2.16.1
>         Environment: Spring 4.2 (without Spring Boot).
>            Reporter: Marcin Zajaczkowski
>            Assignee: Claus Ibsen
>            Priority: Minor
>             Fix For: 2.18.0
>
>
> There could be an equivalent to <contextScan/> from XML configuration in JavaConfig to automatically find routes created as Spring beans using `RouteBuilder` (in non Spring Boot applications).
> Currently they need to be added manually with `camelContext.addRoute(...)`.
> More details:
> https://mail-archives.apache.org/mod_mbox/camel-users/201602.mbox/%3C56C90F42.5000600%40wp.pl%3E



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)