[ 
https://issues.apache.org/jira/browse/PIVOT-864?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13421298#comment-13421298
 ] 

Sandro Martini commented on PIVOT-864:
--------------------------------------

For using FTP (as a Client), in Java, you have two way: the integrated FTP 
support (in URLs, via protocol handlers), or a more robust approach (with retry 
when lost connection, etc) using an external library.

Many time ago I used the latest Apache Commons-Net, take a look here:
http://commons.apache.org/net/api-3.1/org/apache/commons/net/ftp/FTPClient.html
And a small sample for example here: 
http://www.java2s.com/Code/Java/Network-Protocol/UsetheFTPClient.htm

Of course the problem here is to see how to handle this in a transparent way 
for the FileBrowser/Sheet, if possible.
Otherwise extend it. But I think it would be better to not introduce in core 
Pivot a dependency on commons-net, so a provider option could be the best, but 
of course we could need to adjust the api to make it work.

A first approach could be using integrated features of Java, and see if 
depending on your neeeds if this is enough.
An article on this: 
http://java.sun.com/developer/onlineTraining/protocolhandlers/

An interesting article on extending all this: 
http://server.pramati.com/blog/2010/07/21/extending-java-urls-to-support-your-own-protocol/
There should be some library even to handle SSH (and maybe even listing on 
remote folders over ssh) ...

                
> Add a pluggable file system architecture to FileBrowser so remote browsing 
> can be done
> --------------------------------------------------------------------------------------
>
>                 Key: PIVOT-864
>                 URL: https://issues.apache.org/jira/browse/PIVOT-864
>             Project: Pivot
>          Issue Type: New Feature
>          Components: wtk
>    Affects Versions: 2.0.2
>         Environment: Windows, Linux, OSX
>            Reporter: Roger Whitcomb
>            Assignee: Roger Whitcomb
>              Labels: filebrowser
>             Fix For: 2.1
>
>   Original Estimate: 336h
>  Remaining Estimate: 336h
>
> Our application requires the ability to be able to browse (for instance) a 
> Linux machine from the Windows desktop.  For this I would like to add 
> (somehow) a pluggable file system architecture so that I could (for instance) 
> implement an FTP protocol underneath the FileBrowser so that I can browse 
> through directories and files on something other than the local machine.  We 
> would also need to be able to type in a host name or TCP/IP address to start 
> browsing the remote machine.

--
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

        

Reply via email to