Re: [PATCH] SQL assertions prototype

From: Josh Berkus <josh(at)agliodbs(dot)com>
To: Heikki Linnakangas <hlinnakangas(at)vmware(dot)com>, Peter Eisentraut <peter_e(at)gmx(dot)net>
Cc: pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: [PATCH] SQL assertions prototype
Date: 2013-12-17 21:26:09
Message-ID: 52B0C171.2000705@agliodbs.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On 11/15/2013 05:41 AM, Heikki Linnakangas wrote:
> A fundamental problem with this is that it needs to handle isolation
> reliable, so that the assertion cannot be violated when two concurrent
> backends do things. Consider the example from the manual, which checks
> that a table has at least one row. Now, if the table has two rows to
> begin with, and in one backend you delete one row, and concurrently in
> another backend you delete the other row, and then commit both
> transactions, the assertion is violated.
>
> In other words, the assertions need to be checked in serializable mode.
> Now that we have a real serializable mode, I think that's actually
> feasible.

Going back over this patch, I haven't seen any further discussion of the
point Heikki raises above, which seems like a bit of a showstopper.

Heikki, did you have specific ideas on how to solve this? Right now my
mind boggles.

--
Josh Berkus
PostgreSQL Experts Inc.
http://pgexperts.com

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Alvaro Herrera 2013-12-17 21:27:26 Re: 9.3 reference constraint regression
Previous Message Pavel Stehule 2013-12-17 21:05:43 processing time zone