commons-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Christian Ciach (JIRA)" <>
Subject [jira] [Commented] (VFS-533) [SFTP] Support connect-timeouts for SFTP-connections
Date Thu, 24 Jul 2014 15:19:38 GMT


Christian Ciach commented on VFS-533:

Also, in, I hightly recommend changing the second call {{session.setTimeout(timeout)}}
(after the connection is made) to {{session.setServerAliveInterval(timeout)}} in . The second
method sets the timeout, too, but also sends keep alives to the server to keep the connection
alive. We need this in our environment for long-running jobs.

> [SFTP] Support connect-timeouts for SFTP-connections
> ----------------------------------------------------
>                 Key: VFS-533
>                 URL:
>             Project: Commons VFS
>          Issue Type: Improvement
>    Affects Versions: 2.0, 2.1
>            Reporter: Christian Ciach
>            Priority: Minor
>         Attachments: sftpConnectTimeout.patch
> In contrast to other types of FTP filesystems, there is currently no way to have different
connection- and socket-timeouts. This is because the Jsch-Session only accepts one timeout
property which is used for both purposes. Because of this, a SftpFileSystemConfigBuilder also
only provides one method called setTimeout(). The SftpClientFactory then applies this value
to the Jsch Session before the connection is made. 
> Looking at the implementation of a Jsch Session, it becomes clear the the timeout value
is used as a connection timeout if it is set before the call to the connect-method. After
the connection is established, one can call setTimeout() again to override the socket timeout.
> Currently VFS has no interface to support this behaviour, so I made a patch to support

This message was sent by Atlassian JIRA

View raw message