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

feat(services/sftp): support copy and read_seek #2267

Merged
merged 4 commits into from
May 17, 2023
Merged

feat(services/sftp): support copy and read_seek #2267

merged 4 commits into from
May 17, 2023

Conversation

silver-ymz
Copy link
Member

Update:

  • add copyable setting in SftpBuilder to make user provide info about remote server extension
  • bump openssh-sftp-client version to 0.13.5 to fix the bug of AsyncSeek
  • add read_can_seek in Capability

Signed-off-by: silver-ymz <yinmingzhuo@gmail.com>
Signed-off-by: silver-ymz <yinmingzhuo@gmail.com>
Signed-off-by: silver-ymz <yinmingzhuo@gmail.com>
@silver-ymz silver-ymz changed the title Feat/sftp copy seek feat(services/sftp): support copy and read_seek May 17, 2023
@suyanhanx
Copy link
Member

Return an error when call copy if user did not enable copy?

@Xuanwo
Copy link
Member

Xuanwo commented May 17, 2023

Return an error when call copy if user did not enable copy?

We will handle this in general in the future, for example, check capability before calling.

Signed-off-by: silver-ymz <yinmingzhuo@gmail.com>
@silver-ymz
Copy link
Member Author

silver-ymz commented May 17, 2023

Return an error when call copy if user did not enable copy?

https://github.com/apache/incubator-opendal/blob/9cce4d31418567ed2fc8e7178f11a48ac9cbdede/core/src/services/sftp/backend.rs#L391

https://github.com/apache/incubator-opendal/blob/9cce4d31418567ed2fc8e7178f11a48ac9cbdede/core/src/services/sftp/error.rs#L34

Current implementation is to return an error of Unsupported if the remote server doesn't support.

Copy link
Member

@Xuanwo Xuanwo left a comment

Choose a reason for hiding this comment

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

Thanks!

@Xuanwo Xuanwo merged commit 43df0cc into apache:main May 17, 2023
@silver-ymz silver-ymz deleted the feat/sftp-copy-seek branch May 17, 2023 15:53
@silver-ymz
Copy link
Member Author

And may I ask is there anything else need to do about sftp? I think all available features have done.

@Xuanwo
Copy link
Member

Xuanwo commented May 17, 2023

And may I ask is there anything else need to do about sftp?

I guess we don't need to do more until we have user's feature request.

@Xuanwo Xuanwo mentioned this pull request May 23, 2023
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.

3 participants