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

    • Type: Bug
    • Status: Resolved
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 2.19.0
    • Fix Version/s: 2.19.4, 2.20.1, 2.21.0
    • Component/s: camel-sftp
    • Labels:
      None
    • Environment:

      camel is running on Window, and SFTP server is LINUX

    • Estimated Complexity:
      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

            • Assignee:
              onders Onder Sezgin
              Reporter:
              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