heyplusyou commented on issue #1816:
URL: https://github.com/apache/camel-quarkus/issues/1816#issuecomment-696580167


   @lburgazzoli defined with @ApplicationScoped
   
   see below
   
   ```
   @ApplicationScoped
   public class TestRouteBuilder extends RouteBuilder {
   
       @Inject
       TestConfig testConfig;
   
       @Override
       public void configure() {
           onException(Exception.class)
                   .handled(true)
                   .log("${headers.CamelFileName} could not be processed")
                   .log("Error:")
                   .log("${exception.message}")
                   .log("${exception.stacktrace}")
                   .to("file:" + testConfig.broilking_directory_error);
   
           from("file:" + testConfig.broilking_directory_in + 
"?include=.*\\.csv&noop=false")
                   
.autoStartup(ProfileManager.getActiveProfile().equals(RouteProfiles.TEST.getUIName()))
                   .log("Processing: ${headers.CamelFileName}")
                   .process(new RoconCSVProcessor(broilKingConfig))
                   .log("${headers.CamelFileName} successfully processed")
                   .to("file:" + testConfig.broilking_directory_out);
       }
   }
   ```


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Reply via email to