Skip to main content Help Control Panel

YACS CMS : Open source !

Community «   Discussion forum «   Bug tracker «   Limits onUser Uploads «  

Comment: Limits onUser Uploads

<< Previous Next >>

Comment inspired from Bernard

" UncleJam: Actually, there are two ways to limit uploads.

The first one is to define a limit in the user profile, to count uploaded bytes, and to stop accepting files above the limit. We could name this "the boundary approach". Another way would be to set an allowed number of bytes in the user profile, to decrease it on each upload, and to stop at zero. This would be "the bucket approach".

Why bother, if both provides the same feature? In my opinion, "the bucket approach" could be easier to understand and to manage. What do you think? "


I would take the boundary approach. If you decide to up the user limit, there are no recalculations to the user account required.

With the bucket approach, you would have to loop through every user account and add to the bucket by the new upload allowance. If you fail to do this, then only new users will get the new allowance.

Nick.

This comment has inspired:

by NickR on Dec. 28 2006