Quota is currently enforced on commit. I've considered checking during insert/update/copy and throwing an abort but within a transaction they may be deleting data as well.

However, even as a delete may take place before a massive insert/update, a vacuum cannot be run within a transaction block and therefore the commit would fail at the same point as an insert/update within the transaction itself.

So, essentially, there is no difference at which point to check other than to reduce the calculation overhead by placing the check at the commit point.

What's the consensus on when to check?

Alvaro Herrera wrote:
On Thu, Jul 08, 2004 at 03:27:34PM -0600, Jonah H. Harris wrote:


Out of necessity, I've implemented user quotas in 7.4.3. What would the process be for having this reviewed and combined? I have a patch for 7.4.3 ready, but wanted to know if you suggest that I patch the latest cvs instead. Below if some information on the implementation.


At exactly what time is the quota enforced?  Does the enforcement
somehow serialize that operation?


-- Jonah H. Harris, UNIX Administrator | phone: 505.224.4814 Albuquerque TVI | fax: 505.224.3014 525 Buena Vista SE | [EMAIL PROTECTED] Albuquerque, New Mexico 87106 | http://w3.tvi.edu/~jharris/

"All great truths begin as blasphemies."
                --  George Bernard Shaw


---------------------------(end of broadcast)--------------------------- TIP 1: subscribe and unsubscribe commands go to [EMAIL PROTECTED]

Reply via email to