This issue was moved to a discussion.
You can continue the conversation there. Go to discussion →
Improve file storage structure to improve delete performance in large file sets #12248
Closed
3 tasks done
Labels
Preflight Checklist
Describe the Bug
I have a "collection A" with "multiple files field" in it. Some times, I am deleting items from "collection A", so the files are no longer needed.
Regularly, I am deleting the files are no longer necessary.
After having around 1.8m files (all stored locally), deleting a file takes up to 10 secs (both API and App).
Mean while creating new items or uploading files works smoothly (I don't know if there are any performance drop as well, I am running directus on a good machine).
While normal running, CPU level is is perfectly fine, however, while I am deleting the files CPU hits 100% and this immediately affects all other operations which takes long.
I am deleting files 1by1, so I don't know how "Delete Multiple Files" would work.
I am running v9.7.0, on a dedicated mac mini m1 machine.
To Reproduce
Create a collection with multiple files in it.
Add many items with around 1-2 million files.
Try to delete a file.
Errors Shown
No errors.
What version of Directus are you using?
v9.7.0
What version of Node.js are you using?
v16.14.0
What database are you using?
mysql 8
What browser are you using?
chome or through API
What operating system are you using?
macOS
How are you deploying Directus?
running locally
The text was updated successfully, but these errors were encountered: