I used FTP component of camel but it could not download the files that I want.
<camel:endpoint id="ftpNotificationDownload" uri="sftp:/11.1.1.1://app/as?username=aa&password=1111&fastExistsCheck=true&localWorkDirectory=C:\\asd&download=true&throwExceptionOnConnectFailed=true&delay=4000&useFixedDelay=true"/>
I want all the files and folders to be downloaded under my local folder so I did not put filename option.
When I give the host name as 11.1.1.1
, it works but when I set directory after host name like 11.1.1.1:/app/directory
, it does not work.
I have checked SFTP server and it is up.
There should not be a colon (
:
) after the host name in theuri
. And probably not even one of the two slashes. On the other hand, you are missing one slash after thesftp:
.See Apache Camels URIs syntax.
Try
Note that this is true for any URI, not just Camel.