camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From rogelio_sevilla1 <>
Subject Injecting data to routes loaded from xml file
Date Wed, 27 Jul 2011 18:13:17 GMT
Hello everyone:

I'm using camel as an osgi bundle on fuse esb. I currently have a bundle
with a simple POJO that instantiates some camel routes that reside on
another bundle. This works fine.

However, my routes are written on java DSL and I would like to transform
them to Spring DSL. Currently my camel routes look like this:

public class MyRoute extends RouteBuilder implements myInterface {

private String myvar1;
private String myvar2;

public String getMyvar1(){
return myvar1;

//the rest of the getters and setters ...

public void configure() {
//route stuff

On my application, i need to send some data on the route before starting it.
Using java DSL,  i've done it using the previous code. However, i've read
this page on the camel site:

And i don't see any way to achieve the same thing using the spring DSL. So i
was wondering: 

Is it possible to declare some kind of instance members on a spring dsl
camel route, load the xml file on my java code,send my values and finally
starting the route??

Any advice would be appreciated.

Thanks a lot in advance.

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

View raw message