Hi, If i use sftp inside from uri, am getting exceptions like this
*For invalid username *- org.apache.camel.component.file.GenericFileOperationFailedException: Cannot connect to sftp://abcd@localhost:22 at org.apache.camel.component.file.remote.SftpOperations.connect(SftpOperations.java:143) at org.apache.camel.component.file.remote.RemoteFileConsumer.connectIfNecessary(RemoteFileConsumer.java:154) at org.apache.camel.component.file.remote.RemoteFileConsumer.prePollCheck(RemoteFileConsumer.java:57) at org.apache.camel.component.file.GenericFileConsumer.poll(GenericFileConsumer.java:106) at org.apache.camel.impl.ScheduledPollConsumer.doRun(ScheduledPollConsumer.java:187) at org.apache.camel.impl.ScheduledPollConsumer.run(ScheduledPollConsumer.java:114) at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471) at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:304) at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:178) at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:293) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) at java.lang.Thread.run(Thread.java:744) Caused by: com.jcraft.jsch.JSchException: SSH_MSG_DISCONNECT: 2 Too many authentication failures for abcd at com.jcraft.jsch.Session.read(Session.java:938) at com.jcraft.jsch.UserAuthPassword.start(UserAuthPassword.java:91) at com.jcraft.jsch.Session.connect(Session.java:442) at org.apache.camel.component.file.remote.SftpOperations.connect(SftpOperations.java:115) *For invalid hostname* - org.apache.camel.component.file.GenericFileOperationFailedException: Cannot connect to sftp://root@abcd:22 at org.apache.camel.component.file.remote.SftpOperations.connect(SftpOperations.java:143) at org.apache.camel.component.file.remote.RemoteFileConsumer.connectIfNecessary(RemoteFileConsumer.java:154) at org.apache.camel.component.file.remote.RemoteFileConsumer.prePollCheck(RemoteFileConsumer.java:57) at org.apache.camel.component.file.GenericFileConsumer.poll(GenericFileConsumer.java:106) at org.apache.camel.impl.ScheduledPollConsumer.doRun(ScheduledPollConsumer.java:187) at org.apache.camel.impl.ScheduledPollConsumer.run(ScheduledPollConsumer.java:114) at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471) at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:304) at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:178) at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:293) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) at java.lang.Thread.run(Thread.java:744) Caused by: com.jcraft.jsch.JSchException: java.net.UnknownHostException: abcd at com.jcraft.jsch.Util.createSocket(Util.java:389) at com.jcraft.jsch.Session.connect(Session.java:194) at org.apache.camel.component.file.remote.SftpOperations.connect(SftpOperations.java:115) But am not getting these exceptions while using consumer.receive(""sftp://root@abcd:22//home/sample/?password=pwsd1&maximumReconnectAttempts=0&stepwise=false&fileName=sample.txt&throwExceptionOnConnectFailed=true&move=${file:name}.done"); inside my processor. -- View this message in context: http://camel.465427.n5.nabble.com/Exception-not-thrown-while-doing-sftp-inside-consumer-receive-tp5749793.html Sent from the Camel - Users mailing list archive at Nabble.com.