Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Copying to SFTP is very slow compared to native/SSHJ #166

Merged
merged 2 commits into from
Oct 12, 2015
Merged

Conversation

hierynomus
Copy link
Contributor

When copying files from local to SFTP, Overthere is twice slower than either native ssh or using SSHJ directly.

This PR fixes #164 (and is the correct version of #165)

hierynomus added a commit that referenced this pull request Oct 12, 2015
Copying to SFTP is very slow compared to native/SSHJ
@hierynomus hierynomus merged commit 2209d3c into master Oct 12, 2015
@hierynomus hierynomus deleted the slow-sftp branch October 12, 2015 11:38
@buildhive
Copy link

XebiaLabs » overthere #42 SUCCESS
This pull request looks good
(what's this?)

try {
// If the source is a directory and the name and the target name do not match, SFTP copies the
// directory into the destination, whereas we want to copy the contents into the destination.
if (source.isDirectory() && this.exists() && !source.getName().equals(this.getName())) {

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we need to take into account issues related to the case of the name here? E.g. an SSH implementation running on Windows?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actually SSHJ also does not take that into account. This check is merely there to counteract the check in SSHJ that it creates a subdir :)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@demobox
Copy link
Contributor

demobox commented Oct 12, 2015

Nice! Thanks, @hierynomus!

@demobox
Copy link
Contributor

demobox commented Oct 12, 2015

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

SFTP is slow when compared to native ssh.
4 participants