Uploaded image for project: 'Camel'
  1. Camel
  2. CAMEL-10255

Camel Main - Make it easy to configure property placeholder

Agile BoardAttach filesAttach ScreenshotVotersStop watchingWatchersCreate sub-taskLinkCloneUpdate Comment AuthorReplace String in CommentUpdate Comment VisibilityDelete Comments
    XMLWordPrintableJSON

Details

    • New Feature
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • None
    • 2.18.0
    • camel-core
    • None
    • Novice

    Description

      So you can use

      Where you can specify one or more locations separated by comma:

      main.setPropertyPlaceholderLocations("myapp.properties");

      See SO
      http://stackoverflow.com/questions/39033103/how-to-access-property-file-in-apache-camel-with-java-dsl

      Today its a bit harder to do, where you either need to use the MainListener or to setup the PropertiesComponent from a RouteBuilder configure method, or to use the bind which likely is the easiest.

      PropertiesComponent prop = new PropertiesComponent();
      prop.setXXX

      main.bind("properties, prop);

      Attachments

        Activity

          This comment will be Viewable by All Users Viewable by All Users
          Cancel

          People

            davsclaus Claus Ibsen
            davsclaus Claus Ibsen
            Votes:
            0 Vote for this issue
            Watchers:
            2 Stop watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Slack

                Issue deployment