how to specify custom buffer size for sftp connections?

128 views
Skip to first unread message

Syamala Tadigadapa

unread,
Jan 23, 2018, 5:06:49 AM1/23/18
to sshj-users
I do not find a way. Please help. It appears only 16k is the default buffer size where as  we can enjoy bigger buffer sizes will help do faster downloads.

Krishnan Mahadevan

unread,
Jan 23, 2018, 10:54:14 PM1/23/18
to sshj-...@googlegroups.com

Can you please share with us what you have tried so far ? Also please include the version details that you are using.

 

Thanks & Regards

Krishnan Mahadevan

 

"All the desirable things in life are either illegal, expensive, fattening or in love with someone else!"

My Scribblings @ http://wakened-cognition.blogspot.com/

My Technical Scribbings @ http://rationaleemotions.wordpress.com/

--
You received this message because you are subscribed to the Google Groups "sshj-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to sshj-users+...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Bill Stephens

unread,
Jan 24, 2018, 2:44:41 PM1/24/18
to sshj-users
Syamala,

There is an existing bug concerning buffer size. The max setting is 2^15-1 (32767). 

val remoteFile = ftpClient.open(path, util.EnumSet.of(OpenMode.WRITE, OpenMode.CREAT))
val bufferedOutputStream = new BufferedOutputStream(remoteFile.RemoteFileOutputStream, 32767)


Bill
Reply all
Reply to author
Forward
0 new messages