You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@camel.apache.org by fruxo <fr...@gmail.com> on 2013/03/27 23:29:25 UTC

Camel Context modularisation

Hi all,
I am new to Camel and, after a few days of investigations, it does not seem
to me that it is currently possible to achieve the same level of
Camel-context modularisation obtainable with Spring-contexts, am I right?

The use-case I am thinking of might be simply expressed as the need to:
1. have the Camel-context defined in one file
2. have the different routes defined one in an individual file
3. the single Camel-context defined at (1) imports the contexts defined at
(2) possibly via some simple name that supports wild-cards i.e.

The main value is that the artefacts would look much cleaner than having
everything in one single place, not to mention that it would also be
possible to dynamically add new routes to the Camel-context by loading at
runtime other XMLs (the ones defined as per (2)).

So, in conclusion:
- is this currently possible? How?
- if not, is there any suitable extension point in the Camel API that would
allow me to reach my goal?

Thanks in advance,
Francesco
 



--
View this message in context: http://camel.465427.n5.nabble.com/Camel-Context-modularisation-tp5729984.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Re: Camel Context modularisation

Posted by fruxo <fr...@gmail.com>.
Thanks, that is exactly what I needed!
F



--
View this message in context: http://camel.465427.n5.nabble.com/Camel-Context-modularisation-tp5729984p5730077.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Re: Camel Context modularisation

Posted by Claus Ibsen <cl...@gmail.com>.
Hi

Welcome to the community.

See this FAQ
http://camel.apache.org/how-do-i-import-routes-from-other-xml-files.html


On Wed, Mar 27, 2013 at 11:29 PM, fruxo <fr...@gmail.com> wrote:
> Hi all,
> I am new to Camel and, after a few days of investigations, it does not seem
> to me that it is currently possible to achieve the same level of
> Camel-context modularisation obtainable with Spring-contexts, am I right?
>
> The use-case I am thinking of might be simply expressed as the need to:
> 1. have the Camel-context defined in one file
> 2. have the different routes defined one in an individual file
> 3. the single Camel-context defined at (1) imports the contexts defined at
> (2) possibly via some simple name that supports wild-cards i.e.
>
> The main value is that the artefacts would look much cleaner than having
> everything in one single place, not to mention that it would also be
> possible to dynamically add new routes to the Camel-context by loading at
> runtime other XMLs (the ones defined as per (2)).
>
> So, in conclusion:
> - is this currently possible? How?
> - if not, is there any suitable extension point in the Camel API that would
> allow me to reach my goal?
>
> Thanks in advance,
> Francesco
>
>
>
>
> --
> View this message in context: http://camel.465427.n5.nabble.com/Camel-Context-modularisation-tp5729984.html
> Sent from the Camel - Users mailing list archive at Nabble.com.



-- 
Claus Ibsen
-----------------
Red Hat, Inc.
FuseSource is now part of Red Hat
Email: cibsen@redhat.com
Web: http://fusesource.com
Twitter: davsclaus
Blog: http://davsclaus.com
Author of Camel in Action: http://www.manning.com/ibsen

Re: Camel Context modularisation

Posted by Willem jiang <wi...@gmail.com>.
Hi  
RouteContext can do the job that you want to do.
Here is an Example[1] for how to use it.

[1]http://camel.apache.org/how-do-i-import-routes-from-other-xml-files.html  

--  
Willem Jiang

Red Hat, Inc.
FuseSource is now part of Red Hat
Web: http://www.fusesource.com | http://www.redhat.com
Blog: http://willemjiang.blogspot.com (http://willemjiang.blogspot.com/) (English)
          http://jnn.iteye.com (http://jnn.javaeye.com/) (Chinese)
Twitter: willemjiang  
Weibo: 姜宁willem





On Thursday, March 28, 2013 at 6:29 AM, fruxo wrote:

> Hi all,
> I am new to Camel and, after a few days of investigations, it does not seem
> to me that it is currently possible to achieve the same level of
> Camel-context modularisation obtainable with Spring-contexts, am I right?
>  
> The use-case I am thinking of might be simply expressed as the need to:
> 1. have the Camel-context defined in one file
> 2. have the different routes defined one in an individual file
> 3. the single Camel-context defined at (1) imports the contexts defined at
> (2) possibly via some simple name that supports wild-cards i.e.
>  
> The main value is that the artefacts would look much cleaner than having
> everything in one single place, not to mention that it would also be
> possible to dynamically add new routes to the Camel-context by loading at
> runtime other XMLs (the ones defined as per (2)).
>  
> So, in conclusion:
> - is this currently possible? How?
> - if not, is there any suitable extension point in the Camel API that would
> allow me to reach my goal?
>  
> Thanks in advance,
> Francesco
>  
>  
>  
>  
> --
> View this message in context: http://camel.465427.n5.nabble.com/Camel-Context-modularisation-tp5729984.html
> Sent from the Camel - Users mailing list archive at Nabble.com (http://Nabble.com).