Re properties...

Sure, there is a long description at http://camel.apache.org/properties.html

There are a number of mechanisms for getting the properties injected, depending 
on how you package and deploy your application.  Here is one discussion:
http://stackoverflow.com/questions/19457818/how-do-i-load-a-camel-property-into-a-bean

Also, I have some code that loads properties that are used in a route I define 
in Java DSL. Like this:

public class Routes extends RouteBuilder {
        // URI to send requests to.
        @PropertyInject("backendUri")
        private String backendUri;

    private void validateNeededProperties() throws Exception {
        if (backendUri == null)
                throw new BadConfigurationException("backendUri is not set");
    }

    @Override
        public void configure() throws Exception {
        validateNeededProperties();
    ...
       from(INVOKE_BACKEND_URI).routeId(INVOKE_BACKEND_ROUTE_ID)
        .to(backendUri)

-Steve

> -----Original Message-----
> From: Erol [mailto:e...@erol.si]
> Sent: Friday, February 24, 2017 9:01 AM
> To: users@camel.apache.org
> Subject: RE: Passing parameters from routes to components
> 
> Yes, can you please tell me more or do you maybe have an example?
> 
> 
> 
> --
> View this message in context: http://camel.465427.n5.nabble.com/Passing-
> parameters-from-routes-to-components-tp5794341p5794429.html
> Sent from the Camel - Users mailing list archive at Nabble.com.

Reply via email to