Hi,

If I try to transfer a file to a directory that does not exist using Camel
SCP I see a warning like this in the log:

[scp] WARN scp: /home/user/scp/1234: No such file or directory

It looks like the code says that Camel will just log a warning when such an
error occurs. There is no exception in the code, so it looks like the file
was transferred when it was not.

https://github.com/apache/camel/blob/52a739feb9da8acd29067304c7c8356bbc5ef4dd/components/camel-jsch/src/main/java/org/apache/camel/component/scp/ScpOperations.java#L347

Shouldn't this be an error and an exception? Or is there another way of
doing the error handling here?

I tried this with SCP also and indeed SCP does not create the directory so
I think that is correct.  But I think the Camel User should see that the
transfer failed.

Note: I also posted this as a question on StackOverflow.
http://stackoverflow.com/questions/41651190/camel-scp-warnings-not-handled-correctly

Reply via email to