10 Replies Latest reply on Sep 30, 2009 1:50 AM by Claus Ibsen

    Using camel file component within a jar to read a file

    Alex Proschitsky Newbie



      I have a camel route configuration where an xml data file is read from a filesystem and then it's contents are placed into jms topic. The configuration works when started from Eclipse, however when the entire project is packaged as a jar file with dependencies, Camel does not seem to locate the data file.


      Here is an example of a route I am using :




      The data file xml_data_file is located within src/main/resources/data, and is included in the jar's classpath.


      Is the syntax correct ?


      Are there any extra steps required to  configure camel so it can locate the file from whithin the jar?


      Thank you.