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

Add path parameter to get_quota interface #25

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

Vigilans
Copy link
Contributor

@Vigilans Vigilans commented Oct 23, 2022

This PR adds path parameter to DavFileSystem trait's get_quota interface.

There are many cases when we use a folder like /media to export as webdav file root, but subfolders in /media are mounted with other filesystems:

/media -> rootfs
/media/dirA -> external ext4 system
/media/dirB -> external NTFS system

Currently, get_quota only collects quota information of root folder (the /media), even the client is querying quota information of path /media/dirA or /media/dirB.

When using clients like RaiDrive in Windows, it will report disk usage just like normal physical disks, and we expect it to show the correct disk usage of drive /media/dirA or /media/dirB (maybe some TBs large), but not the /media from rootfs `(maybe just tens of GBs).

This PR adds a path parameter to get_quota interface, so its implementations could make use of the path information to return the correct quota information of corresponding disk.

This PR depends on #11 to return quota information for all directory path, instead of return only for root (/) path, and is implemented by miquels/webdav-server-rs#19.

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.

1 participant