Reputation: 3
I want to copy all the files and subfolders from my local machine to sftp server, While I was able to transfer files inside the folder I couldn't transfer nested folder. The configure method of my custom route builder is as follows
@Override
public void configure() throws Exception {
from("file:data/inbox/?noop=true").
to("sftp://192.168.**.**:22/Documents?noop=true&username=******&password=******&preferredAuthentications=publickey,password");
}
Upvotes: 0
Views: 416
Reputation: 55540
Read the documentation about the file component at: http://camel.apache.org/file2 and you can see there is a recurisve
option. Set this option to true
to transfer files from sub directories and their structures.
Upvotes: 1