-
-
Notifications
You must be signed in to change notification settings - Fork 4.2k
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 method to storage backends to get directory content with metadata #20232
Conversation
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.
Can't say if the change semantics are sound, but the code looks fine
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.
🐘
Conflicts... please rebase |
1055e22
to
2efec34
Compare
0256b7b
to
3c97369
Compare
Lots of failures :) |
827b3fe
to
f497ff6
Compare
7ea5676
to
f31daf8
Compare
Currently you need to use `opendir` and then call `getMetadata` for every file, which adds overhead because most storage backends already get the metadata when doing the `opendir`. While storagebackends can (and do) use caching to relief this problem, this adds cache invalidation dificulties and only a limited number of items are generally cached (to prevent memory usage exploding when scanning large storages) With this new methods storage backends can use the child metadata they got from listing the folder to return metadata without having to keep seperate caches. Signed-off-by: Robin Appelman <robin@icewind.nl>
f31daf8
to
9735b5d
Compare
ci seems happy now |
Breaks Talk integration tests (as it is askign on the root node whether it is shared, and that triggers:
Full log + stack:
|
To see it run |
I'm having some issues running the tests but I guess #20599 might fix it |
Currently you need to use
opendir
and then callgetMetadata
forevery file, which adds overhead because most storage backends already
get the metadata when doing the
opendir
.While storagebackends can (and do) use caching to relief this problem,
this adds cache invalidation dificulties and only a limited number of
items are generally cached (to prevent memory usage exploding when
scanning large storages)
With this new methods storage backends can use the child metadata they
got from listing the folder to return metadata without having to keep
seperate caches.
Signed-off-by: Robin Appelman robin@icewind.nl