Uploaded image for project: 'Camel'
  1. Camel
  2. CAMEL-11387

SFTP is delivered into incorrect location, without exception (file in subfolder + temp file is created + Camel running on Window & SFTP server running on LINUX)

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Minor
    • Resolution: Fixed
    • 2.19.0
    • 2.19.4, 2.20.1, 2.21.0
    • camel-sftp
    • None
    • camel is running on Window, and SFTP server is LINUX

    • Unknown

    Description

      The bug only happens when:
      i) file in subfolder
      ii) temp file is created
      iii) Camel running on Window & SFTP server running on LINUX

      Route Configuration:

       from("file://sourceFolder?recursive=true&delay=60000").
       to("sftp://username@linuxServer?tempFileName=${file:onlyname}.part");
      

      NOTES: added separator=UNIX or AUTO, I got the same issue.

      Window Local File: sourceFolder/myfolder1/myfolder2/test.txt
      FTPS Remote File Delivered: $linuxServer/myfolder1myfolder2test.txt

      NOTES:

      • There is no exception throw in 2.19.0, even though the file delivered into incorrect location.
      • In 2.17.3, exception throw at org.apache.camel.component.file.remote.SftpOperations.renameFile(SftpOperations.java:431)[camel-ftp-2.17.3.jar:2.17.3]
      • Without tempFileName, it works perfectly. Issue is around the rename area.

      Attachments

        Activity

          People

            onders Onder Sezgin
            cherryn Cherry Ngai
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Time Tracking

                Estimated:
                Original Estimate - 168h
                168h
                Remaining:
                Remaining Estimate - 168h
                168h
                Logged:
                Time Spent - Not Specified
                Not Specified