Draft
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Which issue does this PR close?
Closes #7369.
Rationale for this change
OpenDAL does not have first-class SMB support today. This change adds an SMB service backed by
smb-rssoOperator::from_uriand the service registry can open SMB shares viasmb://host/share/root.This draft is intentionally split from the dependency fix path. OpenDAL is not carrying a local fork of
smb-rs; the upstream async-read fix is proposed separately in afiffon/smb-rs#167.What changes are included in this PR?
core/services/smbservice crateservices-smbinto the workspace feature list and registry exportscreate_dir,stat,read,write,delete, andlistsmb://host/share/rootand add matching.env.exampleentriesUncPathboundaryDELETE_PENDING/ not-found races during list and delete as skips instead of hard failuresThis draft does not enable
copyorrenameyet.Are there any user-facing changes?
Yes. Users get a new
services-smbfeature and can configure SMB tests via:OPENDAL_SMB_ENDPOINTOPENDAL_SMB_SHAREOPENDAL_SMB_ROOTOPENDAL_SMB_USEROPENDAL_SMB_PASSWORDValidation run on this branch:
cargo test -p opendal-service-smbcargo check -p opendal --features services-smbcargo clippy -p opendal-service-smb --all-targets -- -D warningscargo clippy -p opendal --all-targets --features services-smb -- -D warningsOPENDAL_TEST=smb OPENDAL_SMB_ENDPOINT=127.0.0.1:1445 OPENDAL_SMB_SHARE=MyShare OPENDAL_SMB_ROOT=/ OPENDAL_SMB_USER=alice OPENDAL_SMB_PASSWORD=alipass cargo test -p opendal --features tests,services-smb behaviorOne dependency caveat remains: with crates.io
smb = 0.11.1, large reads can still logAsync command is not allowed in this contextbefore OpenDAL retries them successfully. That fix is under review upstream in afiffon/smb-rs#167.AI Usage Statement
Built with Codex / GPT-5.