On Jan 21, 2009, at 6:46 AM, Matt Brookings wrote:
My question is this; would anyone ever require a quota below a megabyte, or, would any application
ever really need to know about specific usage counts below a megabyte?

When calculating usage, I'm thinking about making the smallest measure of unit a megabyte storing the result in a 64bit unsigned integer. The 64bit value is almost a requirement, but making the smallest unit of measure a megabyte, should future-proof for quite a bit longer.

Two thoughts on quotas.

You're going to have to deal in sub-megabyte numbers, since the size of most messages are measured in KB. Maybe you could track the quota in kbytes, rounding up/down as necessary?

All programs that deal with the quota (maildirsize file) will have to use 128-bit numbers (long long?) or whatever new method you come up with. This includes not just vpopmail, but your IMAP server and potentially maildrop and qmail (if you have any .qmail files that are handled by qmail and not vdelivermail). Maybe they can use a dynamically linked library?

-Tom


!DSPAM:4978006832684277763451!

Reply via email to