title: How to use Apache Camel to load just a single file?
body: <p>Apache Camel has a very nice support for various protocols like FTP and "file" and I would like to use it just to just load a single file and maybe convert it a bit.</p>
  
  <p>I understood how to do this using a RouteBuilder and CamelContext.start() like in the examples but I don't want a background daemon in an endless loop nor do I need complex routing.</p>
  
  <p>How can I do something like:</p>
  
  <pre><code>String body = new DefaultCamelContext().justRunOnce(
     from("ftp://ftp.example.com/data/foo.txt")
       .validate(body().regex("My Data.*"))
       .getBody());
  </code></pre>
  
  <p>I did read some answers on how to stop a Route using "controlbus?action=stop" or "timer?repeat=1" or similar but those still start Camel as a new thread and then use some hack to stop it. I'm not looking for a complicated solution that somehow manages it but rather would like to know if Camel is capable to be used in a lean 10-liner, like in my example above.</p>