-
Notifications
You must be signed in to change notification settings - Fork 1k
object/cifs: support cifs/smb object #6052
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
base: main
Are you sure you want to change the base?
Conversation
Signed-off-by: Xuhui zhang <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR adds support for CIFS (SMB/Samba) storage to the object module, along with tests for its functionality.
- Added a new test function (TestCifs) in object_storage_test.go to verify CIFS integration.
- Updated the unit test workflow to include CIFS environment variables.
Reviewed Changes
Copilot reviewed 4 out of 6 changed files in this pull request and generated no comments.
File | Description |
---|---|
pkg/object/object_storage_test.go | Added TestCifs to run CIFS storage tests. |
.github/workflows/unittests.yml | Added CIFS-related environment variables for tests. |
Files not reviewed (2)
- .github/scripts/prepare_db.sh: Language not supported
- go.mod: Language not supported
Comments suppressed due to low confidence (2)
pkg/object/object_storage_test.go:1082
- Consider using t.Skip with a descriptive message (e.g., t.Skip("Skipping CIFS test due to missing CIFS_ADDR")) instead of printing a message followed by t.SkipNow for improved clarity and standard testing practice.
fmt.Println("skip CIFS test")
.github/workflows/unittests.yml:52
- The CIFS_ADDR value in the workflow does not match the address format specified in the PR description (e.g., cifs://127.0.0.1:445/Data). Verify that the configuration is consistent with the intended CIFS testing environment.
CIFS_ADDR: localhost:4445/Data
add testFileSystem test juicefs/pkg/object/filesystem_test.go Line 85 in 1e66b4a
|
There are still two interfaces to be implemented. juicefs/pkg/object/object_storage.go Line 36 in 0de69d1
juicefs/pkg/object/object_storage.go Line 40 in 0de69d1
|
Signed-off-by: Xuhui zhang <[email protected]>
Signed-off-by: Xuhui zhang <[email protected]>
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #6052 +/- ##
==========================================
- Coverage 50.70% 45.34% -5.36%
==========================================
Files 165 165
Lines 49119 49193 +74
==========================================
- Hits 24908 22309 -2599
- Misses 21390 24184 +2794
+ Partials 2821 2700 -121 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
smb does not fully support chmod, chown, change atime, so the file system interface has not been implemented |
Signed-off-by: Xuhui zhang <[email protected]>
Signed-off-by: Xuhui zhang <[email protected]>
Signed-off-by: Xuhui zhang <[email protected]>
Signed-off-by: Xuhui zhang <[email protected]>
Signed-off-by: Xuhui zhang <[email protected]>
smb will be mostly used by sync, but permission and mtime are not supported by the sdk, we should fork it and fix that. defer this for 1.4 |
This PR introduces support for testing CIFS(AKA smb/samba)
fix: #5526
Test:
objbench
Note:
Dependency Updates:
github.com/hirochachacha/go-smb2
for CIFS support