[ https://issues.apache.org/jira/browse/VFS-307?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13190000#comment-13190000 ]
Ibrahim Hasbini commented on VFS-307: ------------------------------------- Hello Mario, I've been debugging an issue where folder creation was failing and found the method "FTPFile[] listFilesInDirectory(String relPath)" in FTPClientWrapper and this issue. It seems some FTP servers do not return an error code when the LIST command gets a path that contains space, but simply return an empty list of files and a success code. This causes solution 2 mentioned above to never fallback to "change directory + list", this later causes VFS to think that a folder does not exist while in reality it does (eventually causing an exception when we try to create that existing folder). Is it ok to always fallback to "change directory + list" when a path contains spaces? Thanks. > VFS issues a lot of FTP commands when listing a directory > --------------------------------------------------------- > > Key: VFS-307 > URL: https://issues.apache.org/jira/browse/VFS-307 > Project: Commons VFS > Issue Type: Improvement > Reporter: Mario Ivankovits > Fix For: Nightly Builds > > > Hello Mario, > > We at JetBrains are implementing support for (S)FTP sync in our IDEs using > Commons VFS. When looking at the performance, we noticed that FTP provider is > somewhat not perfect: see my discussion with Ralph. > > So the question is: why FtpClientWrapper changes the current directory to > issue 'LIST' command and restoring it back afterwards instead of issuing > single 'LIST <relpath>'? > > Subversion says it was you who introduced this behavior far back in 2008. > Hope you remember those times and reason why you did this. > > Thanks a lot in advance, > > Kirill Safonov > JetBrains, Inc > http://www.jetbrains.com > "Develop with pleasure!" > -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa For more information on JIRA, see: http://www.atlassian.com/software/jira