shell features:install camel-ftp camel.component.ftp.host=ftp.example.com camel.component.ftp.port=21 camel.component.ftp.username=myusername camel.component.ftp.password=mypassword import org.apache.camel.CamelContext; import org.apache.camel.builder.RouteBuilder; import org.apache.camel.impl.DefaultCamelContext; public class FTPBindingExample { public static void main(String[] args) throws Exception { CamelContext context = new DefaultCamelContext(); context.addRoutes(new RouteBuilder() { public void configure() { from("ftp://remoteServer/files?username=myusername&password=mypassword") .to("file://localFolder"); } }); context.start(); Thread.sleep(5000); context.stop(); } }


上一篇:
下一篇:
切换中文