-
-
Notifications
You must be signed in to change notification settings - Fork 49
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
feat: support max_upload_dir_size
config
#335
feat: support max_upload_dir_size
config
#335
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.
Thanks! Had some comments:
This reverts commit 2328473.
Let's get this over the finish line soon if possible :) |
Ping :) |
@Narayanbhat166 can you have a look and make the requested changes? |
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #335 +/- ##
==========================================
- Coverage 83.27% 80.51% -2.76%
==========================================
Files 11 11
Lines 1214 1273 +59
==========================================
+ Hits 1011 1025 +14
- Misses 203 248 +45 ☔ View full report in Codecov by Sentry. |
@orhun I was just wondering what kind of perf impact this has. Isn't this similar to the |
Yeah, probably the performance will be degrade in a noticeable way with this feature enabled. I think we need to add benchmarks using hyperfine to get an idea about that. I did something similar for Zig in https://github.com/orhun/zig-http-benchmarks |
Description
This Pull Request adds a feature to limit the uploads if the
./uploads
dir is full. The size of./uploads
dir can be set by the config keymax_upload_dir_size
under the server config.Motivation and Context
This is required to restrict the number / size of uploads that can be made to the server when hosted publicly.
This fixes #282
How Has This Been Tested?
Changelog Entry
Types of Changes
Checklist: