Jakarta Commons FTP Client Deadlock problems

I have been experimenting with Java FTP components in my effort to create a JFileChooser component that will work over FTP. Common concensus seems to be that the best FTP component is the Jakarta Commons FTPClient class. It seems to have all of the necessary functionality, however seems to have multithreading issues. The component continually deadlocks, and I have narrowed it down to the FTPClient class. I found a post at http://www.kaffe.org/pipermail/kaffe/2005-August/103033.html that also talks about deadlocking in the FTPClient. One suggested solution is to disable the separate reader thread by calling setReaderThread(false). This helps me get a little further to the point where it usually works, but nonetheless deadlocking still occurs.

I will keep on searching for another FTP component but in the mean time I have successfully adapted JFileChooser to use SFTP (Secure FTP) using the SSH Tools libraries.

References

One thought on “Jakarta Commons FTP Client Deadlock problems”

  1. Steve,
    Were you successful in this?
    “I have been experimenting with Java FTP components in my effort to create a JFileChooser component that will work over FTP. ”

    I want to display the files in a remote folder using
    ftp. (commons.net)
    From all the googling I have done, it seems I must
    subclass FileSystemView and pass it to
    the JFileChooser.
    However, FileSystemView returns File from several of
    its methods.
    Must I again subclass File? This would be tedious and
    further, how can I create a File on the remote
    machine? (not possible in ftp, only directory)

    public File createFileObject(File dir, String
    filename)
    public File createFileObject(String path)
    protected File createFileSystemRoot(File f)

    If you know whether there is any existing code that
    solves the problem, it would help much!
    thanks,
    Anil Philip

Comments are closed.

comments powered by Disqus